[RFC 3/7] eb_cpu5282: Declare diplay_width / display_height as externs

Tom Rini trini at konsulko.com
Mon May 3 22:48:55 CEST 2021


The board code here references the display_width / display_height
variables set in the video driver, declare these as externs as gcc-11
will notice and lead to a multiple definition error.

Signed-off-by: Tom Rini <trini at konsulko.com>
---
 board/BuS/eb_cpu5282/eb_cpu5282.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/board/BuS/eb_cpu5282/eb_cpu5282.c b/board/BuS/eb_cpu5282/eb_cpu5282.c
index 153ed0e963b0..144a08922b10 100644
--- a/board/BuS/eb_cpu5282/eb_cpu5282.c
+++ b/board/BuS/eb_cpu5282/eb_cpu5282.c
@@ -22,8 +22,8 @@
 DECLARE_GLOBAL_DATA_PTR;
 
 #if IS_ENABLED(CONFIG_VIDEO_VCXK)
-unsigned long display_width;
-unsigned long display_height;
+extern unsigned long display_width;
+extern unsigned long display_height;
 #endif
 
 /*---------------------------------------------------------------------------*/
-- 
2.17.1



More information about the U-Boot mailing list