On Thu, Feb 05, 2026 at 03:20:10PM +0800, Peng Fan wrote:
> On Wed, Feb 04, 2026 at 01:08:55PM +0100, Francesco Dolcini wrote:
> >On Tue, Feb 03, 2026 at 06:41:38PM +0800, Peng Fan (OSS) wrote:
> >> From: Peng Fan <[email protected]>
> >>
> >> Include linux/types.h and asm-generic/u-boot.h. Missing the two header
> >> files will cause building error after cleaning up usage of
> >> asm/global_data.h.
> >>
> >> Signed-off-by: Peng Fan <[email protected]>
> >> ---
> >> board/toradex/common/tdx-cfg-block.h | 2 ++
> >> board/toradex/common/tdx-common.h | 2 ++
> >> 2 files changed, 4 insertions(+)
> >>
> >> diff --git a/board/toradex/common/tdx-cfg-block.h
> >> b/board/toradex/common/tdx-cfg-block.h
> >> index
> >> b28033d8332e09d063a6a8ad1d4e334703077f00..067daec0d776070b0b53fc26d1043d6eb781a527
> >> 100644
> >> --- a/board/toradex/common/tdx-cfg-block.h
> >> +++ b/board/toradex/common/tdx-cfg-block.h
> >> @@ -6,6 +6,8 @@
> >> #ifndef _TDX_CFG_BLOCK_H
> >> #define _TDX_CFG_BLOCK_H
> >>
> >> +#include <linux/types.h>
> >> +
> >> #include "tdx-common.h"
> >>
> >> struct toradex_hw {
> >> diff --git a/board/toradex/common/tdx-common.h
> >> b/board/toradex/common/tdx-common.h
> >> index
> >> d446e9f1d5ca7d3d5a1318b389393d28854e2263..db3369a8f9ef9b409c53c45e94aa5f22933a44fa
> >> 100644
> >> --- a/board/toradex/common/tdx-common.h
> >> +++ b/board/toradex/common/tdx-common.h
> >> @@ -6,6 +6,8 @@
> >> #ifndef _TDX_COMMON_H
> >> #define _TDX_COMMON_H
> >>
> >> +#include <asm-generic/u-boot.h>
> >> +
> >
> >maybe just have the forward declaration?
> >
> > struct bd_info;
> >
> >and that's it?
>
> I would not add a common declaration here.
Why?
See also commit c3dc39a2f85b ("arm: Don't include common.h in header files")
Francesco