1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-10-26 16:13:55 +01:00

x86: Forward declare gd_t

So it can be used as a type in struct global_data and remove an ugly typecast

Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Marek Vasut <marex@denx.de>
This commit is contained in:
Graeme Russ
2012-11-27 15:38:35 +00:00
committed by Simon Glass
parent d41b3cc16f
commit e4fb611649
3 changed files with 7 additions and 5 deletions

View File

@@ -33,9 +33,11 @@
#ifndef __ASSEMBLY__
typedef struct global_data {
typedef struct global_data gd_t;
struct global_data {
/* NOTE: gd_addr MUST be first member of struct global_data! */
unsigned long gd_addr; /* Location of Global Data */
gd_t *gd_addr; /* Location of Global Data */
bd_t *bd;
unsigned long flags;
unsigned int baudrate;
@@ -57,7 +59,7 @@ typedef struct global_data {
unsigned long reset_status; /* reset status register at boot */
void **jt; /* jump table */
char env_buf[32]; /* buffer for getenv() before reloc. */
} gd_t;
};
static inline gd_t *get_fs_gd_ptr(void)
{