[PATCH] mx6sabresd: Make checkboard respect CONFIG_NXP_BOARD_REVISION
Fabio Estevam
festevam at gmail.com
Sun Jun 27 14:14:50 CEST 2021
Hi Cody,
On Sun, Jun 27, 2021 at 2:15 AM Cody Gray <cody at codygray.com> wrote:
>
> The default implementation of checkboard() calls the
> nxp_board_rev_string() function
> to retrieve a character representing the revision number of the board.
> However, this
> attempt to retrieve the revision number may fail in certain situations or be
> otherwise undesirable.
>
> There is already a configuration option to avoid retrieving the
> revision number of
> the board: CONFIG_NXP_BOARD_REVISION. In fact, if this option is enabled, the
> nxp_board_rev_string() function's definition will be omitted entirely,
> meaning that the previous implementation of checkboard() would result
> in a linker error.
>
> This changeset makes the default implementation of checkboard() respect the
> CONFIG_NXP_BOARD_REVISION configuration option, only attempting to retrieve
> the board revision number if that option is defined.
>
> Signed-off-by: Cody Gray <cody at codygray.com>
Please fix the checkpatch warnings below and submit a v2, thanks:
WARNING: Possible unwrapped commit description (prefer a maximum 75
chars per line)
#72:
attempt to retrieve the revision number may fail in certain situations or be
WARNING: Use 'if (IS_ENABLED(CONFIG...))' instead of '#if or #ifdef'
where possible
#100: FILE: board/freescale/mx6sxsabresd/mx6sxsabresd.c:323:
+#ifdef CONFIG_NXP_BOARD_REVISION
WARNING: please, no spaces at the start of a line
#103: FILE: board/freescale/mx6sxsabresd/mx6sxsabresd.c:326:
+ puts("Board: MX6SX SABRE SDB");$
More information about the U-Boot
mailing list