Re: help on udoo_neo power up on mainline uboot

Fabio Estevam
2022-01-02T01:24:47Z

Hi Tommaso,

On Sat, Jan 1, 2022 at 8:22 PM Tommaso Merciai <tomm.merciai@gmail.com> wrote:

> Hi Peter, Fabio,
> What do you think about this solution:
>
> First create new static entry in gd:
>
> +++ b/include/asm-generic/global_data.h
> @@ -459,6 +459,7 @@ struct global_data {
> */
> char *smbios_version;
> #endif
> + int board_cfg;

No need to add this new 'board_cfg' field entry.

Please use the existing 'board_type' field instead:

#ifdef CONFIG_BOARD_TYPES
/**
* @board_type: board type
*
* If a U-Boot configuration supports multiple board types, the actual
* board type may be stored in this field.
*/
unsigned long board_type;
#endif

Please make sure to add CONFIG_BOARD_TYPES=y in the defconfig.

> What do you think about this solution?
> Let me know.

I like your solution.

The only suggestion is to use the existing 'gd->board_type' and then
feel free to submit a formal patch.

Thanks!

Fabio Estevam