projects
/
platform
/
kernel
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
rename CFG_ENV macros to CONFIG_ENV
[platform/kernel/u-boot.git]
/
lib_ppc
/
board.c
diff --git
a/lib_ppc/board.c
b/lib_ppc/board.c
index
9afa88a
..
c02ac62
100644
(file)
--- a/
lib_ppc/board.c
+++ b/
lib_ppc/board.c
@@
-106,12
+106,12
@@
extern int board_start_ide(void);
DECLARE_GLOBAL_DATA_PTR;
DECLARE_GLOBAL_DATA_PTR;
-#if defined(C
F
G_ENV_IS_EMBEDDED)
+#if defined(C
ONFI
G_ENV_IS_EMBEDDED)
#define TOTAL_MALLOC_LEN CFG_MALLOC_LEN
#define TOTAL_MALLOC_LEN CFG_MALLOC_LEN
-#elif ( ((C
FG_ENV_ADDR+CF
G_ENV_SIZE) < CFG_MONITOR_BASE) || \
- (C
F
G_ENV_ADDR >= (CFG_MONITOR_BASE + CFG_MONITOR_LEN)) ) || \
- defined(C
F
G_ENV_IS_IN_NVRAM)
-#define TOTAL_MALLOC_LEN (CFG_MALLOC_LEN + C
F
G_ENV_SIZE)
+#elif ( ((C
ONFIG_ENV_ADDR+CONFI
G_ENV_SIZE) < CFG_MONITOR_BASE) || \
+ (C
ONFI
G_ENV_ADDR >= (CFG_MONITOR_BASE + CFG_MONITOR_LEN)) ) || \
+ defined(C
ONFI
G_ENV_IS_IN_NVRAM)
+#define TOTAL_MALLOC_LEN (CFG_MALLOC_LEN + C
ONFI
G_ENV_SIZE)
#else
#define TOTAL_MALLOC_LEN CFG_MALLOC_LEN
#endif
#else
#define TOTAL_MALLOC_LEN CFG_MALLOC_LEN
#endif
@@
-168,19
+168,6
@@
void *sbrk (ptrdiff_t increment)
return ((void *) old);
}
return ((void *) old);
}
-char *strmhz (char *buf, long hz)
-{
- long l, n;
- long m;
-
- n = hz / 1000000L;
- l = sprintf (buf, "%ld", n);
- m = (hz % 1000000L) / 1000L;
- if (m != 0)
- sprintf (buf + l, ".%03ld", m);
- return (buf);
-}
-
/*
* All attempts to come up with a "common" initialization sequence
* that works for all boards and architectures failed: some of the
/*
* All attempts to come up with a "common" initialization sequence
* that works for all boards and architectures failed: some of the
@@
-524,11
+511,11
@@
void board_init_f (ulong bootflag)
addr_sp -= sizeof (bd_t);
bd = (bd_t *) addr_sp;
gd->bd = bd;
addr_sp -= sizeof (bd_t);
bd = (bd_t *) addr_sp;
gd->bd = bd;
- debug ("Reserving %
d
Bytes for Board Info at: %08lx\n",
+ debug ("Reserving %
zu
Bytes for Board Info at: %08lx\n",
sizeof (bd_t), addr_sp);
addr_sp -= sizeof (gd_t);
id = (gd_t *) addr_sp;
sizeof (bd_t), addr_sp);
addr_sp -= sizeof (gd_t);
id = (gd_t *) addr_sp;
- debug ("Reserving %
d
Bytes for Global Data at: %08lx\n",
+ debug ("Reserving %
zu
Bytes for Global Data at: %08lx\n",
sizeof (gd_t), addr_sp);
/*
sizeof (gd_t), addr_sp);
/*
@@
-664,7
+651,7
@@
void board_init_r (gd_t *id, ulong dest_addr)
bd_t *bd;
int i;
extern void malloc_bin_reloc (void);
bd_t *bd;
int i;
extern void malloc_bin_reloc (void);
-#ifndef C
F
G_ENV_IS_NOWHERE
+#ifndef C
ONFI
G_ENV_IS_NOWHERE
extern char * env_name_spec;
#endif
extern char * env_name_spec;
#endif
@@
-726,7
+713,7
@@
void board_init_r (gd_t *id, ulong dest_addr)
#endif
}
/* there are some other pointer constants we must deal with */
#endif
}
/* there are some other pointer constants we must deal with */
-#ifndef C
F
G_ENV_IS_NOWHERE
+#ifndef C
ONFI
G_ENV_IS_NOWHERE
env_name_spec += gd->reloc_off;
#endif
env_name_spec += gd->reloc_off;
#endif
@@
-786,7
+773,7
@@
void board_init_r (gd_t *id, ulong dest_addr)
*/
s = getenv ("flashchecksum");
if (s && (*s == 'y')) {
*/
s = getenv ("flashchecksum");
if (s && (*s == 'y')) {
- printf (" CRC: %08
l
X",
+ printf (" CRC: %08X",
crc32 (0, (const unsigned char *) CFG_FLASH_BASE, flash_size)
);
}
crc32 (0, (const unsigned char *) CFG_FLASH_BASE, flash_size)
);
}
@@
-835,7
+822,7
@@
void board_init_r (gd_t *id, ulong dest_addr)
malloc_bin_reloc ();
#ifdef CONFIG_SPI
malloc_bin_reloc ();
#ifdef CONFIG_SPI
-# if !defined(C
F
G_ENV_IS_IN_EEPROM)
+# if !defined(C
ONFI
G_ENV_IS_IN_EEPROM)
spi_init_f ();
# endif
spi_init_r ();
spi_init_f ();
# endif
spi_init_r ();
@@
-886,7
+873,7
@@
void board_init_r (gd_t *id, ulong dest_addr)
sc3_read_eeprom();
#endif
sc3_read_eeprom();
#endif
-#if defined (C
F
G_ID_EEPROM) || defined (CFG_I2C_MAC_OFFSET)
+#if defined (C
ONFI
G_ID_EEPROM) || defined (CFG_I2C_MAC_OFFSET)
mac_read_from_eeprom();
#endif
mac_read_from_eeprom();
#endif