Message ID | 1509606996-10905-2-git-send-email-kever.yang@rock-chips.com |
---|---|
State | Accepted |
Commit | 73e6dbe855f357a8330cfd53ff3033303611c1ad |
Delegated to: | Philipp Tomsich |
Headers | show |
Series | [U-Boot,1/3] spl: set SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR to 0x4000 for rockchip | expand |
> On 2 Nov 2017, at 08:16, Kever Yang <kever.yang@rock-chips.com> wrote: > > Update rockchip U-Boot location to 0x4000/16384. > > Signed-off-by: Kever Yang <kever.yang@rock-chips.com> > --- > > doc/README.rockchip | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/doc/README.rockchip b/doc/README.rockchip > index 4b7be0b..9d5af3d 100644 > --- a/doc/README.rockchip > +++ b/doc/README.rockchip > @@ -99,13 +99,13 @@ To write an image that boots from an SD card (assumed to be /dev/sdc): > ./firefly-rk3288/tools/mkimage -n rk3288 -T rksd -d \ > firefly-rk3288/spl/u-boot-spl-dtb.bin out && \ > sudo dd if=out of=/dev/sdc seek=64 && \ > - sudo dd if=firefly-rk3288/u-boot-dtb.img of=/dev/sdc seek=256 > + sudo dd if=firefly-rk3288/u-boot-dtb.img of=/dev/sdc seek=16384 > > This puts the Rockchip header and SPL image first and then places the U-Boot > -image at block 256 (i.e. 128KB from the start of the SD card). This > +image at block 16384 (i.e. 4MB from the start of the SD card). This > corresponds with this setting in U-Boot: > > - #define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 256 > + #define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x4000 Could you use 'u-boot,spl-payload-offset’ to provide this info to U-Boot or is there a strong reason to hard-code this? > > Put this SD (or micro-SD) card into your board and reset it. You should see > something like: > -- > 1.9.1 >
On 11/03/2017 05:42 PM, Dr. Philipp Tomsich wrote: >> On 2 Nov 2017, at 08:16, Kever Yang <kever.yang@rock-chips.com> wrote: >> >> Update rockchip U-Boot location to 0x4000/16384. >> >> Signed-off-by: Kever Yang <kever.yang@rock-chips.com> >> --- >> >> doc/README.rockchip | 6 +++--- >> 1 file changed, 3 insertions(+), 3 deletions(-) >> >> diff --git a/doc/README.rockchip b/doc/README.rockchip >> index 4b7be0b..9d5af3d 100644 >> --- a/doc/README.rockchip >> +++ b/doc/README.rockchip >> @@ -99,13 +99,13 @@ To write an image that boots from an SD card (assumed to be /dev/sdc): >> ./firefly-rk3288/tools/mkimage -n rk3288 -T rksd -d \ >> firefly-rk3288/spl/u-boot-spl-dtb.bin out && \ >> sudo dd if=out of=/dev/sdc seek=64 && \ >> - sudo dd if=firefly-rk3288/u-boot-dtb.img of=/dev/sdc seek=256 >> + sudo dd if=firefly-rk3288/u-boot-dtb.img of=/dev/sdc seek=16384 >> >> This puts the Rockchip header and SPL image first and then places the U-Boot >> -image at block 256 (i.e. 128KB from the start of the SD card). This >> +image at block 16384 (i.e. 4MB from the start of the SD card). This >> corresponds with this setting in U-Boot: >> >> - #define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 256 >> + #define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x4000 > Could you use 'u-boot,spl-payload-offset’ to provide this info to U-Boot > or is there a strong reason to hard-code this? Because it's simple enough for use. To be honest, I didn't notice there is a DTS node for spl-payload-offset, the reason is like env offset. And I didn't see a good reason to move this to DTS: - Almost all the SoCs using the macro define in header file or default value in Kconfig, using dts is not popular way; - I don't think we need to add a node for each SoC dtsi, we only need one MACRO define in common header and use it directly instead of parse it from different SoC dtsi; - kernel dtsi file does not have the 'u-boot,spl-payload-offset' node, that means we have to add them in dtsi for each soc when we add one soc support, I think most people do not have idea about this, why don't we make it easier? Thanks, - Kever > >> Put this SD (or micro-SD) card into your board and reset it. You should see >> something like: >> -- >> 1.9.1 >> >
> Update rockchip U-Boot location to 0x4000/16384. > > Signed-off-by: Kever Yang <kever.yang@rock-chips.com> > --- > > doc/README.rockchip | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
> Update rockchip U-Boot location to 0x4000/16384. > > Signed-off-by: Kever Yang <kever.yang@rock-chips.com> > Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> > --- > > doc/README.rockchip | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
> Update rockchip U-Boot location to 0x4000/16384. > > Signed-off-by: Kever Yang <kever.yang@rock-chips.com> > Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> > Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> > --- > > doc/README.rockchip | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > Applied to u-boot-rockchip, thanks!
diff --git a/doc/README.rockchip b/doc/README.rockchip index 4b7be0b..9d5af3d 100644 --- a/doc/README.rockchip +++ b/doc/README.rockchip @@ -99,13 +99,13 @@ To write an image that boots from an SD card (assumed to be /dev/sdc): ./firefly-rk3288/tools/mkimage -n rk3288 -T rksd -d \ firefly-rk3288/spl/u-boot-spl-dtb.bin out && \ sudo dd if=out of=/dev/sdc seek=64 && \ - sudo dd if=firefly-rk3288/u-boot-dtb.img of=/dev/sdc seek=256 + sudo dd if=firefly-rk3288/u-boot-dtb.img of=/dev/sdc seek=16384 This puts the Rockchip header and SPL image first and then places the U-Boot -image at block 256 (i.e. 128KB from the start of the SD card). This +image at block 16384 (i.e. 4MB from the start of the SD card). This corresponds with this setting in U-Boot: - #define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 256 + #define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x4000 Put this SD (or micro-SD) card into your board and reset it. You should see something like:
Update rockchip U-Boot location to 0x4000/16384. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> --- doc/README.rockchip | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)