From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jerry Van Baren Date: Wed, 25 Apr 2007 08:08:18 -0400 Subject: [U-Boot-Users] LIBFDT: bogus definition of fdt in libfdt_env.h In-Reply-To: <462F1243.20005@grandegger.com> References: <462F1243.20005@grandegger.com> Message-ID: <462F44B2.8040706@smiths-aerospace.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Wolfgang Grandegger wrote: > Hi Jerry, > > in libfdt_env.h there is fdt defined as: > > struct fdt_header *fdt; /* Pointer to the working fdt */ > > I think it should be declared "extern", because the file is included by > more than one file. Or the declaration should be moved to cmd_fdt.c, > because it's the only file actually using it. > > Wolfgang. Hi Wolfgang G, Yes, that is not declared properly. IIRC, I split the fdt_support.c out of cmd_fdt.c and moved the declaration into the .h file because I thought I would need it in more places (cmd_bootm.c, IIRC). The move was done poorly. I'll add figuring out the proper location and declaration to the cleanup list. It probably should move (as a static) back into cmd_fdt.c until it is actually needed elsewhere. Thanks, gvb