[PATCH v2] imx8mn_var_som: Add support for Variscite VAR-SOM-MX8M-NANO board

Ariel D'Alessandro ariel.dalessandro at collabora.com
Mon Nov 15 22:46:47 CET 2021


On 11/15/21 6:28 PM, Tom Rini wrote:
> On Mon, Nov 15, 2021 at 06:27:08PM -0300, Ariel D'Alessandro wrote:
>> Hi Tom,
>>
>> Thanks for the feedback.
>>
>> On 11/15/21 6:11 PM, Tom Rini wrote:
>>> On Mon, Nov 15, 2021 at 05:24:22PM -0300, Ariel D'Alessandro wrote:
>>>
>>>> Add support for iMX8MN VAR-SOM-MX8M-NANO board. Enables support for:
>>>>
>>>> - 1GiB DDR4 RAM
>>>> - 16 GiB eMMC
>>>> - SD card
>>>> - Gigabit ethernet
>>>> - USBOTG1 peripheral - fastboot
>>>>
>>>> Signed-off-by: Ariel D'Alessandro <ariel.dalessandro at collabora.com>
>>>> ---

[snip]

>>>> +#ifdef CONFIG_SPL_BUILD
>>>> +
>>>> +#define CONFIG_SPL_STACK		0x980000
>>>> +#define CONFIG_SPL_BSS_START_ADDR	0x950000
>>>> +#define CONFIG_SPL_BSS_MAX_SIZE		SZ_8K
>>>> +#define CONFIG_SYS_SPL_MALLOC_START	0x42200000
>>>> +#define CONFIG_SYS_SPL_MALLOC_SIZE	SZ_512K
>>>> +
>>>> +/* For RAW image gives a error info not panic */
>>>> +#define CONFIG_SPL_ABORT_ON_RAW_IMAGE
>>>> +
>>>> +#endif /* CONFIG_SPL_BUILD */
>>>
>>> We can't guard CONFIG options with CONFIG_SPL_BUILD or
>>> !CONFIG_SPL_BUILD.
>>
>> Sorry I don't understand, could you expand on the proper way to handle
>> the above configuration? AFAICS, several imx8m boards follow this same
>> pattern:
>>
>> $ git grep -l CONFIG_SPL_BUILD -- include/configs/imx8m*
>> include/configs/imx8mm-cl-iot-gate.h
>> include/configs/imx8mm_beacon.h
>> include/configs/imx8mm_evk.h
>> include/configs/imx8mm_icore_mx8mm.h
>> include/configs/imx8mm_venice.h
>> include/configs/imx8mn_beacon.h
>> include/configs/imx8mn_evk.h
>> include/configs/imx8mp_evk.h
>> include/configs/imx8mq_cm.h
>> include/configs/imx8mq_evk.h
>> include/configs/imx8mq_phanbell.h
> 
> Yes, it's sadly a common anti-pattern.  Just always define things.

I see. Will be fixed in v3.

Thanks a lot!
Ariel


More information about the U-Boot mailing list