]> git.sur5r.net Git - u-boot/blobdiff - board/nx823/nx823.c
POST: Add 405EX support to 4xx UART POST test
[u-boot] / board / nx823 / nx823.c
index cbcbab8945a87b70c9ebf33de4b9e2c0f2fd55ea..4a426ec4980326ed96df67b9811df5963fb9a91d 100644 (file)
 #include <malloc.h>
 #include <mpc8xx.h>
 
-/* ------------------------------------------------------------------------- */
+DECLARE_GLOBAL_DATA_PTR;
 
 static long int dram_size (long int, long int *, long int);
 
-/* ------------------------------------------------------------------------- */
-
 #define        _NOT_USED_      0xFFFFFFFF
 
 const uint sdram_table[] = {
@@ -221,7 +219,7 @@ long int initdram (int board_type)
         *
         * try 8 column mode
         */
-       size8 = dram_size (CFG_MAMR_8COL, (ulong *) SDRAM_BASE1_PRELIM,
+       size8 = dram_size (CFG_MAMR_8COL, (long *) SDRAM_BASE1_PRELIM,
                           SDRAM_MAX_SIZE);
 
        udelay (1000);
@@ -229,7 +227,7 @@ long int initdram (int board_type)
        /*
         * try 9 column mode
         */
-       size9 = dram_size (CFG_MAMR_9COL, (ulong *) SDRAM_BASE1_PRELIM,
+       size9 = dram_size (CFG_MAMR_9COL, (long *) SDRAM_BASE1_PRELIM,
                           SDRAM_MAX_SIZE);
 
        if (size8 < size9) {    /* leave configuration at 9 columns     */
@@ -248,7 +246,7 @@ long int initdram (int board_type)
         * [9 column SDRAM may also be used in 8 column mode,
         *  but then only half the real size will be used.]
         */
-       size_b1 = dram_size (memctl->memc_mamr, (ulong *) SDRAM_BASE2_PRELIM,
+       size_b1 = dram_size (memctl->memc_mamr, (long *) SDRAM_BASE2_PRELIM,
                             SDRAM_MAX_SIZE);
 /*     debug ("SDRAM Bank 1: %ld MB\n", size8 >> 20);  */
 
@@ -366,8 +364,6 @@ u_long *my_sernum;
 
 int misc_init_r (void)
 {
-       DECLARE_GLOBAL_DATA_PTR;
-
        char tmp[50];
        u_char *e = gd->bd->bi_enetaddr;
 
@@ -387,8 +383,6 @@ int misc_init_r (void)
 
 void load_sernum_ethaddr (void)
 {
-       DECLARE_GLOBAL_DATA_PTR;
-
        int i;
        bd_t *bd = gd->bd;