HI Mark, On Wed, 2 Jan 2019 at 18:50, Mark Kettenis <mark.kette...@xs4all.nl> wrote: > > > From: Simon Glass <s...@chromium.org> > > Date: Wed, 2 Jan 2019 18:15:31 -0700 > > > > Hi Kever, > > > > I have a firefly-rk3399 and would like to boot it into U-Boot (as a start) > > from an uSD card. > > > > Are there instructions somewhere on how to do this? I gather that I need > > OP-TEE but not how to build it or how to put the image together. I would > > like to have instructions in README.rockchip if possible. > > > > I'm planning to add U-Boot support for bob and maybe kevin (both > > Chromebooks) but am not sure where to start. I thought the firefly might be > > best since it is pretty common. > > Hi Simon, > > The instructions in board/u-boot/rockchip/evb_rk3399/README apply to > the firefly-rk3399 as well. I've successfully built working firmware > for my board using the TF-A (ATF) 2.0 release and U-Boot SPL in the > past that way.
Thanks for the pointer. That was the file I was looking for and I didn't think to look at the evb. > > One complication with the firefly board is that by default it boots > from eMMC, so you can't easily test new firmware by putting it on uSD > card unless you make the eMMC unbootable somehow (e.g. by overwriting > the start of the eMMC storage with zeroes). In that case you can boot > from uSD card if you write U-Boot SPL and U-Boot proper at the right > offsets: > > # dd if=idbspl.img of=/dev/sd1c seek=64 > # dd if=u-boot.itb of=/dev/sd1c seek=16384 > > (that's on OpenBSD, on Linux the device names will be different) Yes I did that with my board, so it already boots from uSD. > > Haven't tested flashing eMMC with rkdeveloptool myself, but that > should work on the firefly as well. > > Another complication as that the serial console speed defaults to > 1500000 which isn't supported by all serial-to-USB chips and frankly Yes I seem to have one that supports this, so this is fine. > too sensitive to wire noise. Also be aware that TF-A built from the > official ARM sources at > > https://github.com/ARM-software/arm-trusted-firmware.git > > defaults to 115200 (which is more reasonable IMHO). So I have the > following diff in my U-Boot tree. The device tree change comes in > handy if you want to boot from uSD card, otherwise U-Boot SPL will > attempt to load the full U-Boot from eMMC. Perhaps that bit should be > committed at some point. > > Having support for bob would be great. I have one, and would like to > make OpenBSD run on it. OK well I think I'll start with an existing board and then see what is needed. Regards, Simon > > Cheers, > > Mark > > > diff --git a/arch/arm/dts/rk3399-firefly.dts b/arch/arm/dts/rk3399-firefly.dts > index be350866a7..f90e7e88db 100644 > --- a/arch/arm/dts/rk3399-firefly.dts > +++ b/arch/arm/dts/rk3399-firefly.dts > @@ -15,7 +15,7 @@ > > chosen { > stdout-path = &uart2; > - u-boot,spl-boot-order = &sdhci, &sdmmc; > + u-boot,spl-boot-order = "same-as-spl", &sdhci, &sdmmc; > }; > > backlight: backlight { > diff --git a/configs/firefly-rk3399_defconfig > b/configs/firefly-rk3399_defconfig > index 7ac4064a8b..01b3a0771f 100644 > --- a/configs/firefly-rk3399_defconfig > +++ b/configs/firefly-rk3399_defconfig > @@ -58,7 +58,7 @@ CONFIG_REGULATOR_RK8XX=y > CONFIG_PWM_ROCKCHIP=y > CONFIG_RAM=y > CONFIG_SPL_RAM=y > -CONFIG_BAUDRATE=1500000 > +CONFIG_BAUDRATE=115200 > CONFIG_DEBUG_UART_SHIFT=2 > CONFIG_SYSRESET=y > CONFIG_USB=y _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot