LFU-154 imx6ul: bee: fix build break
authorPeng Fan <peng.fan@nxp.com>
Thu, 27 May 2021 10:42:24 +0000 (18:42 +0800)
committerPeng Fan <peng.fan@nxp.com>
Thu, 27 May 2021 10:49:53 +0000 (18:49 +0800)
Fix below build break by including the global_data.h header file.
"
  CC      arch/arm/mach-imx/mx6/bee.o
arch/arm/mach-imx/mx6/bee.c:18:1: warning: data definition has no type or storage class
   18 | DECLARE_GLOBAL_DATA_PTR;
      | ^~~~~~~~~~~~~~~~~~~~~~~
arch/arm/mach-imx/mx6/bee.c:18:1: warning: type defaults to ‘int’ in declaration of ‘DECLARE_GLOBAL_DATA_PTR’ [-Wimplicit-int]
arch/arm/mach-imx/mx6/bee.c: In function ‘region_valid’:
arch/arm/mach-imx/mx6/bee.c:261:29: error: ‘gd’ undeclared (first use in this function)
  261 |  if ((start + size - 1) >= (gd->start_addr_sp - SZ_128K)) {
      |                             ^~
arch/arm/mach-imx/mx6/bee.c:261:29: note: each undeclared identifier is reported only once for each function it appears in
scripts/Makefile.build:265: recipe for target 'arch/arm/mach-imx/mx6/bee.o' failed
make[2]: *** [arch/arm/mach-imx/mx6/bee.o] Error 1

"

Reviewed-by: Ye Li <ye.li@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
arch/arm/mach-imx/mx6/bee.c

index 0c6cc67..a852c5f 100644 (file)
@@ -14,6 +14,7 @@
 #include <fuse.h>
 #include <asm/arch/sys_proto.h>
 #include <cpu_func.h>
+#include <asm/global_data.h>
 
 DECLARE_GLOBAL_DATA_PTR;