[PATCH 2/2] imx8mm_evk: Add Serial Download Protocol support
Michael Nazzareno Trimarchi
michael at amarulasolutions.com
Tue Sep 20 08:33:00 CEST 2022
HI
On Tue, Sep 20, 2022 at 8:31 AM ZHIZHIKIN Andrey
<andrey.zhizhikin at leica-geosystems.com> wrote:
>
> Hello Michael,
>
> > -----Original Message-----
> > From: U-Boot <u-boot-bounces at lists.denx.de> On Behalf Of Michael Nazzareno
> > Trimarchi
> > Sent: Tuesday, September 20, 2022 7:46 AM
> > To: Fabio Estevam <festevam at denx.de>
> > Cc: sbabic at denx.de; peng.fan at nxp.com; marex at denx.de; u-boot at lists.denx.de
> > Subject: Re: [PATCH 2/2] imx8mm_evk: Add Serial Download Protocol support
> >
> > Hi
> >
> > On Tue, Sep 20, 2022 at 2:21 AM Fabio Estevam <festevam at denx.de> wrote:
> > >
> > > Add Serial Download Protocol support as it is a useful method to
> > > load flash.bin to RAM and run it via 'uuu'.
> > >
> > > With this patch, it is possible to start both U-Boot SPL and U-Boot
> > > proper using the following 'uuu'command:
> > >
> > > $ uuu -brun spl flash.bin
> > >
> > > Based on a patch from Marek Vasut for the imx8mm-mx8menlo board.
> > >
> > > Also, to fit the SPL binary into the internal RAM, select CONFIG_LTO
> > > to reduce its size.
> > >
> > > Signed-off-by: Fabio Estevam <festevam at denx.de>
> > > ---
> > > arch/arm/dts/imx8mm-evk-u-boot.dtsi | 16 ++++++++++++++++
> > > configs/imx8mm_evk_defconfig | 21 +++++++++++++++++++++
> > > 2 files changed, 37 insertions(+)
> > >
> > > diff --git a/arch/arm/dts/imx8mm-evk-u-boot.dtsi b/arch/arm/dts/imx8mm-evk-u-
> > boot.dtsi
> > > index 36fbf56bc5..d82428f8fe 100644
> > > --- a/arch/arm/dts/imx8mm-evk-u-boot.dtsi
> > > +++ b/arch/arm/dts/imx8mm-evk-u-boot.dtsi
> > > @@ -20,6 +20,10 @@
> > > };
> > > };
> > >
> > > +&aips4 {
> > > + u-boot,dm-spl;
> > > +};
> > > +
> > > ®_usdhc2_vmmc {
> > > u-boot,off-on-delay-us = <20000>;
> > > };
> > > @@ -84,6 +88,18 @@
> > > u-boot,dm-spl;
> > > };
> > >
> > > +&usbmisc1 {
> > > + u-boot,dm-spl;
> > > +};
> > > +
> > > +&usbphynop1 {
> > > + u-boot,dm-spl;
> > > +};
> > > +
> > > +&usbotg1 {
> > > + u-boot,dm-spl;
> > > +};
> > > +
> > > &usdhc1 {
> > > u-boot,dm-spl;
> > > };
> > > diff --git a/configs/imx8mm_evk_defconfig b/configs/imx8mm_evk_defconfig
> > > index 7bcedcd51f..2dff26b3eb 100644
> > > --- a/configs/imx8mm_evk_defconfig
> > > +++ b/configs/imx8mm_evk_defconfig
> > > @@ -17,6 +17,7 @@ CONFIG_SPL_SERIAL=y
> > > CONFIG_SPL_DRIVERS_MISC=y
> > > CONFIG_SPL=y
> > > CONFIG_SYS_LOAD_ADDR=0x40480000
> > > +CONFIG_LTO=y
> >
> > Is the entry required? or part of the series. If so could you explain
> > in the commit message?
>
> While not being strictly part of the series, Fabio did explained the
> LTO enablement in the commit message above. This reduces the size of
> SPL, which in turn allows it to fit into IRAM.
>
Sorry too early. I was thinking that I was read this comment in marek
review for other patch but was reported even here
Michael
> -- andrey
>
> >
> > Michael
> >
> > > CONFIG_DISTRO_DEFAULTS=y
> > > CONFIG_FIT=y
> > > CONFIG_FIT_EXTERNAL_OFFSET=0x3000
> > > @@ -38,6 +39,9 @@ CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR=y
> > > CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR=0x300
> > > CONFIG_SPL_I2C=y
> > > CONFIG_SPL_POWER=y
> > > +CONFIG_SPL_USB_HOST=y
> > > +CONFIG_SPL_USB_GADGET=y
> > > +CONFIG_SPL_USB_SDP_SUPPORT=y
> > > CONFIG_SPL_WATCHDOG=y
> > > CONFIG_SYS_MAXARGS=64
> > > CONFIG_SYS_CBSIZE=2048
> > > @@ -50,6 +54,8 @@ CONFIG_CMD_FUSE=y
> > > CONFIG_CMD_GPIO=y
> > > CONFIG_CMD_I2C=y
> > > CONFIG_CMD_MMC=y
> > > +CONFIG_CMD_USB_SDP=y
> > > +CONFIG_CMD_USB_MASS_STORAGE=y
> > > CONFIG_CMD_CACHE=y
> > > CONFIG_CMD_REGULATOR=y
> > > CONFIG_CMD_EXT4_WRITE=y
> > > @@ -80,9 +86,13 @@ CONFIG_PHY_ATHEROS=y
> > > CONFIG_PHY_GIGE=y
> > > CONFIG_FEC_MXC=y
> > > CONFIG_MII=y
> > > +CONFIG_SPL_PHY=y
> > > +CONFIG_SPL_NOP_PHY=y
> > > CONFIG_PINCTRL=y
> > > CONFIG_SPL_PINCTRL=y
> > > CONFIG_PINCTRL_IMX8M=y
> > > +CONFIG_POWER_DOMAIN=y
> > > +CONFIG_IMX8M_POWER_DOMAIN=y
> > > CONFIG_DM_PMIC=y
> > > CONFIG_SPL_DM_PMIC_PCA9450=y
> > > CONFIG_DM_REGULATOR=y
> > > @@ -97,4 +107,15 @@ CONFIG_SPL_SYSRESET=y
> > > CONFIG_SYSRESET_PSCI=y
> > > CONFIG_SYSRESET_WATCHDOG=y
> > > CONFIG_DM_THERMAL=y
> > > +CONFIG_USB=y
> > > +CONFIG_USB_EHCI_HCD=y
> > > +CONFIG_MXC_USB_OTG_HACTIVE=y
> > > +# CONFIG_USB_STORAGE is not set
> > > +CONFIG_USB_GADGET=y
> > > +CONFIG_USB_GADGET_MANUFACTURER="FSL"
> > > +CONFIG_USB_GADGET_VENDOR_NUM=0x0525
> > > +CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5
> > > +CONFIG_CI_UDC=y
> > > +CONFIG_SDP_LOADADDR=0x40400000
> > > +CONFIG_USB_GADGET_DOWNLOAD=y
> > > CONFIG_IMX_WATCHDOG=y
> > > --
> > > 2.25.1
> > >
> >
> >
> > --
> > Michael Nazzareno Trimarchi
> > Co-Founder & Chief Executive Officer
> > M. +39 347 913 2170
> > michael at amarulasolutions.com
> > __________________________________
> >
> > Amarula Solutions BV
> > Joop Geesinkweg 125, 1114 AB, Amsterdam, NL
> > T. +31 (0)85 111 9172
> > info at amarulasolutions.com
> > www.amarulasolutions.com
--
Michael Nazzareno Trimarchi
Co-Founder & Chief Executive Officer
M. +39 347 913 2170
michael at amarulasolutions.com
__________________________________
Amarula Solutions BV
Joop Geesinkweg 125, 1114 AB, Amsterdam, NL
T. +31 (0)85 111 9172
info at amarulasolutions.com
www.amarulasolutions.com
More information about the U-Boot
mailing list