[U-Boot] [PATCH 2/5] Revert "configs: am335x: usb: do not define CONFIG_DM_USB for spl"

Andrew F. Davis afd at ti.com
Mon Feb 6 15:52:08 UTC 2017


On 02/03/2017 05:42 PM, Alexandru Gagniuc wrote:
> This reverts commit 4623f974a585b59bd07fb60a326a096290aa4c53.
> This confuses the #ifdef logic in am33xx/board.c. This results in
> undefined symbols when USB gadget mode is disabled in .config.
> 

The #ifdef logic is a bit of a nightmare right now while we migrate to
Kconfig from header defines, and so I agree this commit is a bit
confused. But how do you fix the problem the commit you are reverting
intended to fix?

SPL uses the same USB code as regular U-Boot, but DM_USB is not yet
compatible with SPL, and so when CONFIG_DM_USB is enabled when SPL is
being built, well, bad things happen.

Undefined symbols will happen until the Kconfig conversion is finished
and some proper kconfig dependencies are defined. In the meantime, the
only other fix for this commit will be to convert DM_USB code to work
with SPL.

Andrew

> Signed-off-by: Alexandru Gagniuc <alex.g at adaptrum.com>
> ---
>  include/configs/am335x_evm.h | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
> index 85c0728..cd42601 100644
> --- a/include/configs/am335x_evm.h
> +++ b/include/configs/am335x_evm.h
> @@ -282,7 +282,6 @@
>  #ifdef CONFIG_SPL_BUILD
>  #undef CONFIG_DM_MMC
>  #undef CONFIG_TIMER
> -#undef CONFIG_DM_USB
>  #endif
>  
>  #if defined(CONFIG_SPL_BUILD) && defined(CONFIG_SPL_USBETH_SUPPORT)
> 


More information about the U-Boot mailing list