diff mbox

[U-Boot] mx6sabre: Do not enable UMS with SPL

Message ID 1425937479-12903-1-git-send-email-festevam@gmail.com
State Awaiting Upstream
Delegated to: Stefano Babic
Headers show

Commit Message

Fabio Estevam March 9, 2015, 9:44 p.m. UTC
From: Fabio Estevam <fabio.estevam@freescale.com>

Since commit ad8aae82b20ac6a ("mx6sabre: Enable User Mass Storage") SPL target
does not boot anymore due to the increased spl image size.

Only enable USB Mass Storage for the non-SPL target.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
 include/configs/mx6sabre_common.h | 2 ++
 1 file changed, 2 insertions(+)

Comments

Tom Rini March 9, 2015, 11:44 p.m. UTC | #1
On Mon, Mar 09, 2015 at 06:44:39PM -0300, Fabio Estevam wrote:

> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Since commit ad8aae82b20ac6a ("mx6sabre: Enable User Mass Storage") SPL target
> does not boot anymore due to the increased spl image size.
> 
> Only enable USB Mass Storage for the non-SPL target.
> 
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>

Reviewed-by: Tom Rini <trini@konsulko.com>

Please do a follow up commit that makes use of the existing size checks
to avoid this problem in the future, thanks!
Fabio Estevam March 9, 2015, 11:52 p.m. UTC | #2
Hi Tom,

On Mon, Mar 9, 2015 at 8:44 PM, Tom Rini <trini@konsulko.com> wrote:
> On Mon, Mar 09, 2015 at 06:44:39PM -0300, Fabio Estevam wrote:
>
>> From: Fabio Estevam <fabio.estevam@freescale.com>
>>
>> Since commit ad8aae82b20ac6a ("mx6sabre: Enable User Mass Storage") SPL target
>> does not boot anymore due to the increased spl image size.
>>
>> Only enable USB Mass Storage for the non-SPL target.
>>
>> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
>
> Reviewed-by: Tom Rini <trini@konsulko.com>
>
> Please do a follow up commit that makes use of the existing size checks
> to avoid this problem in the future, thanks!

Yes, it would be useful. Could you please point me to the existing
size checks function, so that I can learn about it?

Thanks,

Fabio Estevam
Tom Rini March 10, 2015, 12:02 a.m. UTC | #3
On Mon, Mar 09, 2015 at 08:52:52PM -0300, Fabio Estevam wrote:
> Hi Tom,
> 
> On Mon, Mar 9, 2015 at 8:44 PM, Tom Rini <trini@konsulko.com> wrote:
> > On Mon, Mar 09, 2015 at 06:44:39PM -0300, Fabio Estevam wrote:
> >
> >> From: Fabio Estevam <fabio.estevam@freescale.com>
> >>
> >> Since commit ad8aae82b20ac6a ("mx6sabre: Enable User Mass Storage") SPL target
> >> does not boot anymore due to the increased spl image size.
> >>
> >> Only enable USB Mass Storage for the non-SPL target.
> >>
> >> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> >
> > Reviewed-by: Tom Rini <trini@konsulko.com>
> >
> > Please do a follow up commit that makes use of the existing size checks
> > to avoid this problem in the future, thanks!
> 
> Yes, it would be useful. Could you please point me to the existing
> size checks function, so that I can learn about it?

CONFIG_SPL_MAX_SIZE and CONFIG_SPL_MAX_BSS_SIZE or
CONFIG_SPL_MAX_FOOTPRINT are what you want for i.MX6 and documented in
README. I'm not quite sure of all the details on i.MX6 right now so I
can't say for sure which group it falls into.  On TI ARMv7 parts for
example we get access to DDR by the time we need BSS, so BSS is in DDR
and our limit there is semi artificial but CONFIG_SPL_MAX_SIZE (since
the binary is loaded into SRAM of a limited area) is not.  On some TI
Davinci platforms we use CONFIG_SPL_MAX_FOOTPRINT since both BSS and the
binary must be in a limited RAM area.
Fabio Estevam March 10, 2015, 12:09 a.m. UTC | #4
On Mon, Mar 9, 2015 at 9:02 PM, Tom Rini <trini@konsulko.com> wrote:

> CONFIG_SPL_MAX_SIZE and CONFIG_SPL_MAX_BSS_SIZE or
> CONFIG_SPL_MAX_FOOTPRINT are what you want for i.MX6 and documented in
> README. I'm not quite sure of all the details on i.MX6 right now so I
> can't say for sure which group it falls into.  On TI ARMv7 parts for
> example we get access to DDR by the time we need BSS, so BSS is in DDR
> and our limit there is semi artificial but CONFIG_SPL_MAX_SIZE (since
> the binary is loaded into SRAM of a limited area) is not.  On some TI
> Davinci platforms we use CONFIG_SPL_MAX_FOOTPRINT since both BSS and the
> binary must be in a limited RAM area.

Thanks, Tom. I will take a look at these options.

Regards,

Fabio Estevam
Stefano Babic March 13, 2015, 12:47 p.m. UTC | #5
On 09/03/2015 22:44, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Since commit ad8aae82b20ac6a ("mx6sabre: Enable User Mass Storage") SPL target
> does not boot anymore due to the increased spl image size.
> 
> Only enable USB Mass Storage for the non-SPL target.
> 
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---

Applied to u-boot-imx, thanks !

Best regards,
Stefano Babic
diff mbox

Patch

diff --git a/include/configs/mx6sabre_common.h b/include/configs/mx6sabre_common.h
index f0e37f0..9417729 100644
--- a/include/configs/mx6sabre_common.h
+++ b/include/configs/mx6sabre_common.h
@@ -278,6 +278,7 @@ 
 #define CONFIG_IMX_HDMI
 #define CONFIG_IMX_VIDEO_SKIP
 
+#ifndef CONFIG_SPL
 #define CONFIG_CI_UDC
 #define CONFIG_USBD_HS
 #define CONFIG_USB_GADGET_DUALSPEED
@@ -291,5 +292,6 @@ 
 #define CONFIG_G_DNL_VENDOR_NUM		0x0525
 #define CONFIG_G_DNL_PRODUCT_NUM	0xa4a5
 #define CONFIG_G_DNL_MANUFACTURER	"FSL"
+#endif
 
 #endif                         /* __MX6QSABRE_COMMON_CONFIG_H */