]> git.sur5r.net Git - u-boot/commitdiff
Fix some more print() format errors.
authorWolfgang Denk <wd@denx.de>
Thu, 10 Jul 2008 23:16:00 +0000 (01:16 +0200)
committerWolfgang Denk <wd@denx.de>
Thu, 10 Jul 2008 23:16:00 +0000 (01:16 +0200)
Signed-off-by: Wolfgang Denk <wd@denx.de>
26 files changed:
board/ads5121/ads5121.c
board/atum8548/atum8548.c
board/bc3450/cmd_bc3450.c
board/cm5200/cmd_cm5200.c
board/cm5200/fwupdate.c
board/fads/flash.c
board/freescale/mpc8544ds/mpc8544ds.c
board/freescale/mpc8610hpcd/mpc8610hpcd.c
board/freescale/mpc8641hpcn/mpc8641hpcn.c
board/mcc200/auto_update.c
board/mpc8540eval/flash.c
board/netstal/common/nm_bsp.c
board/o2dnt/flash.c
board/sandburst/metrobox/metrobox.c
board/spc1920/hpi.c
board/total5200/total5200.c
board/tqc/tqm5200/cmd_stk52xx.c
board/tqc/tqm8272/tqm8272.c
common/cmd_nand.c
common/cmd_reginfo.c
cpu/mpc512x/speed.c
cpu/mpc86xx/traps.c
drivers/net/uli526x.c
examples/test_burst.c
lib_generic/lmb.c
net/net.c

index de59991d2a43865c0d93f8d37bb2473eefd41bd2..d5cee64bde58c0e293f9670990b1cd9bea4d563b 100644 (file)
@@ -29,6 +29,8 @@
 #ifdef CONFIG_MISC_INIT_R
 #include <i2c.h>
 #endif
+#include "iopin.h"     /* for iopin_initialize() prototype */
+
 /* Clocks in use */
 #define SCCR1_CLOCKS_EN        (CLOCK_SCCR1_CFG_EN |                           \
                         CLOCK_SCCR1_LPC_EN |                           \
@@ -52,8 +54,7 @@ long int fixed_sdram(void);
 int board_early_init_f (void)
 {
        volatile immap_t *im = (immap_t *) CFG_IMMR;
-       u32 lpcaw, tmp32;
-       int i;
+       u32 lpcaw;
 
        /*
         * Initialize Local Window for the CPLD registers access (CS2 selects
@@ -206,6 +207,7 @@ long int fixed_sdram (void)
 int misc_init_r(void)
 {
        u8 tmp_val;
+       extern int ads5121_diu_init(void);
 
        /* Using this for DIU init before the driver in linux takes over
         *  Enable the TFP410 Encoder (I2C address 0x38)
index 4d8c6fbae3de15d16390d784b00d50a23ed4dc5d..34f4599048a3fc825aa0b69dae8cdc7e32b45ca8 100644 (file)
@@ -53,7 +53,7 @@ int checkboard (void)
        volatile ccsr_local_ecm_t *ecm = (void *)(CFG_MPC85xx_ECM_ADDR);
 
        if ((uint)&gur->porpllsr != 0xe00e0000) {
-               printf("immap size error %x\n",&gur->porpllsr);
+               printf("immap size error %lx\n",(ulong)&gur->porpllsr);
        }
        printf ("Board: ATUM8548\n");
 
index f7f0013c7d587dc0791deb0322ec98ab7ec64c0b..48bc65de22313ea22f2ee5c80a8dbd45a9ad9640 100644 (file)
@@ -189,7 +189,7 @@ int cmd_dip (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
        if (rc > 0x0F)
                return -1;
 
-       printf ("0x%x\n", rc);
+       printf ("0x%lx\n", rc);
        return 0;
 }
 
index 354f2bf6eb82da2c6b07baa1031a92c17e96f029..2201bdd8cc863464ff5088ce5be3deb30ab9c766 100644 (file)
@@ -335,7 +335,7 @@ int do_rs232(char *argv[])
                if (((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) & 0x10000000) !=
                                0x10000000) {
                        error_status = 2;
-                       printf("%s: failure at rs232_4, rxd status is %d "
+                       printf("%s: failure at rs232_4, rxd status is %lu "
                                "(should be 1)\n", __FUNCTION__,
                                ((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) &
                                        0x10000000) >> 28);
@@ -350,7 +350,7 @@ int do_rs232(char *argv[])
                if (((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) & 0x10000000) !=
                                0x00000000) {
                        error_status = 2;
-                       printf("%s: failure at rs232_4, rxd status is %d "
+                       printf("%s: failure at rs232_4, rxd status is %lu "
                                "(should be 0)\n", __FUNCTION__,
                                ((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) &
                                        0x10000000) >> 28);
@@ -366,7 +366,7 @@ int do_rs232(char *argv[])
                if (((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) & 0x20000000) !=
                                0x20000000) {
                        error_status = 3;
-                       printf("%s: failure at rs232_4, cts status is %d "
+                       printf("%s: failure at rs232_4, cts status is %lu "
                                "(should be 1)\n", __FUNCTION__,
                                ((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) &
                                        0x20000000) >> 29);
@@ -381,7 +381,7 @@ int do_rs232(char *argv[])
                if (((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) & 0x20000000) !=
                                0x00000000) {
                        error_status = 3;
-                       printf("%s: failure at rs232_4, cts status is %d "
+                       printf("%s: failure at rs232_4, cts status is %lu "
                                "(should be 0)\n", __FUNCTION__,
                                ((*(vu_long *)MPC5XXX_WU_GPIO_DATA_I) &
                                        0x20000000) >> 29);
index 19aa94a5a03bd202f460a4f7e28d1563f3b8a00a..5a27191352d0f5e4904e0df49c70cdea9be6347b 100644 (file)
@@ -63,7 +63,7 @@ void cm5200_fwupdate(void)
        if (!bcmd)
                return;
 
-       sprintf(ka, "%lx", LOAD_ADDR);
+       sprintf(ka, "%lx", (ulong)LOAD_ADDR);
 
        /* prepare our bootargs */
        rsargs = getenv("rs-args");
index f0fb621271952be4c021562bd005da976ddf35c0..7cda3a412ff60601a46cf5766085a204f82d61c6 100644 (file)
@@ -90,7 +90,7 @@ unsigned long flash_init (void)
        default:
                pd_size = 0;
                or_am = 0xFFE00000;
-               printf("## Unsupported flash detected by BCSR: 0x%08X\n", bcsr[2]);
+               printf("## Unsupported flash detected by BCSR: 0x%08lX\n", bcsr[2]);
        }
 
        total_size = 0;
index f615b2384a967360a09796aaf647119dabc2c413..8c4b04097e5ec986c1d1f624142dae9a860ee5a0 100644 (file)
@@ -47,7 +47,7 @@ int checkboard (void)
        volatile ccsr_local_ecm_t *ecm = (void *)(CFG_MPC85xx_ECM_ADDR);
 
        if ((uint)&gur->porpllsr != 0xe00e0000) {
-               printf("immap size error %x\n",&gur->porpllsr);
+               printf("immap size error %lx\n",(ulong)&gur->porpllsr);
        }
        printf ("Board: MPC8544DS\n");
 
index 0bf21d592db0909e7db7361afac371b064eb0aa9..ff1b892b51da2283b532993f29612f8fef4fd91a 100644 (file)
@@ -99,8 +99,8 @@ int checkboard(void)
        volatile immap_t *immap = (immap_t *)CFG_IMMR;
        volatile ccsr_local_mcm_t *mcm = &immap->im_local_mcm;
 
-       printf ("Board: MPC8610HPCD, System ID: 0x%02lx, "
-               "System Version: 0x%02lx, FPGA Version: 0x%02lx\n",
+       printf ("Board: MPC8610HPCD, System ID: 0x%02x, "
+               "System Version: 0x%02x, FPGA Version: 0x%02x\n",
                in8(PIXIS_BASE + PIXIS_ID), in8(PIXIS_BASE + PIXIS_VER),
                in8(PIXIS_BASE + PIXIS_PVER));
 
index b30c6b1e9205ed2ea562354058830d34b49f7be3..db46953044638e06cbee3c261414ceecc84eb7f4 100644 (file)
@@ -47,8 +47,8 @@ int board_early_init_f(void)
 
 int checkboard(void)
 {
-       printf ("Board: MPC8641HPCN, System ID: 0x%02lx, "
-               "System Version: 0x%02lx, FPGA Version: 0x%02lx\n",
+       printf ("Board: MPC8641HPCN, System ID: 0x%02x, "
+               "System Version: 0x%02x, FPGA Version: 0x%02x\n",
                in8(PIXIS_BASE + PIXIS_ID), in8(PIXIS_BASE + PIXIS_VER),
                in8(PIXIS_BASE + PIXIS_PVER));
        return 0;
index 5580c118878ae4fc76724eb9651311838e6737db..2ed66ddb4197cbcdc4adf61d9346351962cb7eac 100644 (file)
@@ -491,7 +491,7 @@ int do_auto_update(void)
                        aufile[i], sz, image_get_header_size ());
 
                if (sz != ausize[i]) {
-                       printf ("%s: size %d read %d?\n", aufile[i], ausize[i], sz);
+                       printf ("%s: size %ld read %ld?\n", aufile[i], ausize[i], sz);
                        continue;
                }
 
index 7300a041a21dc150c66c821d7cb4f28e18b0cfe3..79eb04ca87b65d0f5a1a3ee4e56a9f6b44ab788f 100644 (file)
@@ -591,7 +591,7 @@ int write_buff (flash_info_t *info, uchar *src, ulong addr, ulong cnt)
                cnt -= FLASH_BLOCK_SIZE;
                if (((count-cnt)>>10)>temp) {
                        temp=(count-cnt)>>10;
-                       printf("\r%d KB",temp);
+                       printf("\r%lu KB",temp);
                }
        }
        printf("\n");
@@ -699,7 +699,8 @@ static int write_block(flash_info_t *info, uchar * src, ulong dest, ulong cnt)
                        }
                }
                if (csr & 0x4040) {
-                       printf ("CSR indicates write error (%04x) at %08lx\n", csr, (ulong)addr);
+                       printf ("CSR indicates write error (%04lx) at %08lx\n",
+                               csr, (ulong)addr);
                        flag = 1;
                }
                /* Clear Status Registers Command */
@@ -756,7 +757,8 @@ static int write_short (flash_info_t *info, ulong dest, ushort data)
                        }
                }
                if (csr & 0x4040) {
-                       printf ("CSR indicates write error (%04x) at %08lx\n", csr, (ulong)addr);
+                       printf ("CSR indicates write error (%04lx) at %08lx\n",
+                               csr, (ulong)addr);
                        flag = 1;
                }
                /* Clear Status Registers Command */
index 86f491b34ec49e2564172ef8502d2130c600f8df..e38b7069ceeed12ddb656234c06ed4a48b78e2b3 100644 (file)
@@ -75,8 +75,8 @@ void set_params_for_sw_install(int install_requested, char *board_name )
                setenv("install", string);
                sprintf(string, "setenv bootargs emac(0,0)c:%s/%s_sw_inst "
                        "e=${ipaddr} h=${serverip} f=0x1000; "
-                       "bootvx ${loadaddr}\0",
-                       board_name, board_name);
+                       "bootvx ${loadaddr}%c",
+                       board_name, board_name, 0);
                setenv("boot_sw_inst", string);
        }
 }
@@ -108,10 +108,12 @@ void common_misc_init_r(void)
                gd->bd->bi_enetaddr[3] = (serial >> 16) & 0xff;
                gd->bd->bi_enetaddr[4] = (serial >>  8) & 0xff;
                gd->bd->bi_enetaddr[5] = hcu_get_slot();
-               sprintf(ethaddr, "%02X:%02X:%02X:%02X:%02X:%02X\0",
+               sprintf(ethaddr, "%02X:%02X:%02X:%02X:%02X:%02X%c",
                        gd->bd->bi_enetaddr[0], gd->bd->bi_enetaddr[1],
                        gd->bd->bi_enetaddr[2], gd->bd->bi_enetaddr[3],
-                       gd->bd->bi_enetaddr[4], gd->bd->bi_enetaddr[5]) ;
+                       gd->bd->bi_enetaddr[4],
+                       gd->bd->bi_enetaddr[5],
+                       0) ;
                printf("%s: Setting eth %s serial 0x%x\n",  __FUNCTION__,
                       ethaddr, serial);
                setenv(DEFAULT_ETH_ADDR, ethaddr);
index 037d28732d8066a76f783232201f6afb2b11c267..349086ffb52200b246f06af62077b6b2d4ede08f 100644 (file)
@@ -411,7 +411,7 @@ static int write_data (flash_info_t *info, FPWV *dest, FPW data)
 
        /* Check if Flash is (sufficiently) erased */
        if ((*addr & data) != data) {
-               printf ("not erased at %08lx (%lx)\n", (ulong) addr, *addr);
+               printf ("not erased at %08lx (%x)\n", (ulong) addr, *addr);
                return (2);
        }
        /* Disable interrupts which might cause a timeout here */
index 86d259fac4a1e2d277472ffc1617c493ae2227ee..97049013e1cea80f27867a9e7e564a1f79a6c437 100644 (file)
@@ -270,7 +270,7 @@ int checkboard (void)
        }
 
        printf ("OptoFPGA ID:\t0x%02X\tRev:  0x%02X\n", opto_id, opto_rev);
-       printf ("Board Rev:\t0x%02X\tID:  %s\n", brd_rev, board_id_as[brd_id]);
+       printf ("Board Rev:\t0x%02X\tID:  %s\n", brd_rev, (char *)board_id_as[brd_id]);
 
        /* Fix the ack in the bme 32 */
        udelay(5000);
index cd7799b277b6b97c68bfc02b97b8abacd260bcfd..cf21b215b71131a14dffa3f63dd16c687241de9a 100644 (file)
@@ -234,7 +234,8 @@ static int hpi_write_inc(u32 addr, u32 *data, u32 count)
        HPI_HPIA_1 = addr1;
        HPI_HPIA_2 = addr2;
 
-       debugX(4, "writing from data=0x%x to 0x%x\n", data, (data+count));
+       debugX(4, "writing from data=0x%lx to 0x%lx\n",
+               (ulong)data, (ulong)(data+count));
 
        for(i=0; i<count; i++) {
                HPI_HPID_INC_1 = (u16) ((data[i] >> 16) & 0xffff);
index 868ebd5f540418cc9e7128e69fa746c708c5730c..1ae24c4f3a3b250a1a0974c406def5a91d28a5a8 100644 (file)
@@ -67,14 +67,14 @@ int checkboard (void)
        puts ("Board: Total5100 ");
 #endif
 
-/*
- * Retrieve FPGA Revision.
- */
-printf ("(FPGA %08X)\n", *(vu_long *) (CFG_FPGA_BASE + 0x400));
+       /*
       * Retrieve FPGA Revision.
       */
+       printf ("(FPGA %08lX)\n", *(vu_long *) (CFG_FPGA_BASE + 0x400));
 
-/*
- * Take all peripherals in power-up mode.
- */
+       /*
       * Take all peripherals in power-up mode.
       */
 #if CONFIG_TOTAL5200_REV==2
        *(vu_char *) (CFG_CPLD_BASE + 0x46) = 0x70;
 #else
index 7472ca9e9716e3bd195a4ad9728cc008a089fd20..58039d4170c5e2ca322d658757ba6406c55f01cc 100644 (file)
@@ -478,7 +478,7 @@ static int cmd_wav(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
        }
        set_attenuation(volume);
 
-       printf("Play wave file at %#p with length %#x\n", addr, length);
+       printf("Play wave file at %lX with length %lX\n", addr, length);
        rcode = i2s_play_wave(addr, length);
 
        return rcode;
index 29099f5ed15719930f5866807849a363fdcfaff3..cde02961beae179b5468a2639299eb94fb7fd5ad 100644 (file)
@@ -652,7 +652,7 @@ static int dump_hwib(void)
                printf ("ethaddr: %s\n", hw->ethaddr);
                printf ("FLASH  : %x nr:%d\n", hw->flash, hw->flash_nr);
                printf ("RAM    : %x cs:%d\n", hw->ram, hw->ram_cs);
-               printf ("CPU    : %d\n", hw->cpunr);
+               printf ("CPU    : %lu\n", hw->cpunr);
                printf ("CAN    : %d\n", hw->can);
                if (hw->eeprom) printf ("EEprom : %x\n", hw->eeprom);
                else printf ("No EEprom\n");
@@ -663,7 +663,7 @@ static int dump_hwib(void)
                printf ("Bus %s mode.\n", (hw->Bus ? "60x" : "Single PQII"));
                printf ("  real : %s\n", (immr->im_siu_conf.sc_bcr & BCR_EBM ? \
                                 "60x" : "Single PQII"));
-               printf ("Option : %x\n", hw->option);
+               printf ("Option : %lx\n", hw->option);
                printf ("%s Security Engine\n", (hw->SecEng ? "with" : "no"));
                printf ("CPM Clk: %d\n", hw->cpmcl);
                printf ("CPU Clk: %d\n", hw->cpucl);
index cc7c5ba2419725800a4ac6146752b7b25e92719e..9e38bf768f984db114cc755a9e67f311cd297fc5 100644 (file)
@@ -886,9 +886,9 @@ int do_nand (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
                                return 1;
                        }
 
-                       printf ("\nNAND %s: device %d offset %ld, size %ld ...\n",
+                       printf ("\nNAND %s: device %d offset %ld, size %lu ...\n",
                                (cmd & NANDRW_READ) ? "read" : "write",
-                               curr_device, off, size);
+                               curr_device, off, (ulong)size);
 
                        ret = nand_legacy_rw (nand_dev_desc + curr_device,
                                              cmd, off, size,
index 1669d7496299066abc56d2498295c4e0e35b1adf..0657e4b1f101bc0bd10588ec4945b80076de281a 100644 (file)
@@ -282,54 +282,54 @@ int do_reginfo (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
        puts ("\nMPC5200 registers\n");
        printf ("MBAR=%08x\n", CFG_MBAR);
        puts ("Memory map registers\n");
-       printf ("\tCS0: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS0: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS0_START,
                *(volatile ulong*)MPC5XXX_CS0_STOP,
                *(volatile ulong*)MPC5XXX_CS0_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x00010000) ? 1 : 0);
-       printf ("\tCS1: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS1: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS1_START,
                *(volatile ulong*)MPC5XXX_CS1_STOP,
                *(volatile ulong*)MPC5XXX_CS1_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x00020000) ? 1 : 0);
-       printf ("\tCS2: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS2: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS2_START,
                *(volatile ulong*)MPC5XXX_CS2_STOP,
                *(volatile ulong*)MPC5XXX_CS2_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x00040000) ? 1 : 0);
-       printf ("\tCS3: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS3: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS3_START,
                *(volatile ulong*)MPC5XXX_CS3_STOP,
                *(volatile ulong*)MPC5XXX_CS3_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x00080000) ? 1 : 0);
-       printf ("\tCS4: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS4: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS4_START,
                *(volatile ulong*)MPC5XXX_CS4_STOP,
                *(volatile ulong*)MPC5XXX_CS4_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x00100000) ? 1 : 0);
-       printf ("\tCS5: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS5: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS5_START,
                *(volatile ulong*)MPC5XXX_CS5_STOP,
                *(volatile ulong*)MPC5XXX_CS5_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x00200000) ? 1 : 0);
-       printf ("\tCS6: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS6: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS6_START,
                *(volatile ulong*)MPC5XXX_CS6_STOP,
                *(volatile ulong*)MPC5XXX_CS6_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x04000000) ? 1 : 0);
-       printf ("\tCS7: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tCS7: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_CS7_START,
                *(volatile ulong*)MPC5XXX_CS7_STOP,
                *(volatile ulong*)MPC5XXX_CS7_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x08000000) ? 1 : 0);
-       printf ("\tBOOTCS: start %08X\tstop %08X\tconfig %08X\ten %d\n",
+       printf ("\tBOOTCS: start %08lX\tstop %08lX\tconfig %08lX\ten %d\n",
                *(volatile ulong*)MPC5XXX_BOOTCS_START,
                *(volatile ulong*)MPC5XXX_BOOTCS_STOP,
                *(volatile ulong*)MPC5XXX_BOOTCS_CFG,
                (*(volatile ulong*)MPC5XXX_ADDECR & 0x02000000) ? 1 : 0);
-       printf ("\tSDRAMCS0: %08X\n",
+       printf ("\tSDRAMCS0: %08lX\n",
                *(volatile ulong*)MPC5XXX_SDRAM_CS0CFG);
-       printf ("\tSDRAMCS1: %08X\n",
+       printf ("\tSDRAMCS1: %08lX\n",
                *(volatile ulong*)MPC5XXX_SDRAM_CS1CFG);
 #elif defined(CONFIG_MPC86xx)
        mpc86xx_reginfo();
index cfaffb57a7292b296b0bb452855a02a216ce699d..e62477bc0b422f075a61ff41625a5caf7d2984c5 100644 (file)
@@ -126,7 +126,7 @@ ulong get_bus_freq (ulong dummy)
 int do_clocks (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
 {
        printf("Clock configuration:\n");
-       printf("  CPU:                 %4d MHz\n", gd->cpu_clk / 1000000);
+       printf("  CPU:                 %4ld MHz\n", gd->cpu_clk / 1000000);
        printf("  Coherent System Bus: %4d MHz\n", gd->csb_clk / 1000000);
        printf("  IPS Bus:             %4d MHz\n", gd->ips_clk / 1000000);
        printf("  PCI:                 %4d MHz\n", gd->pci_clk / 1000000);
index 5695c3e453ae9bc6f852cea5b0b5737dbb690d20..13f386ddc847e7145957d0ba73f142f4bb99cbdf 100644 (file)
@@ -218,7 +218,7 @@ UnknownException(struct pt_regs *regs)
        if (debugger_exception_handler && (*debugger_exception_handler) (regs))
                return;
 #endif
-       printf("UnknownException regs@%x\n", regs);
+       printf("UnknownException regs@%lx\n", (ulong)regs);
        printf("Bad trap at PC: %lx, SR: %lx, vector=%lx\n",
               regs->nip, regs->msr, regs->trap);
        _exception(0, regs);
index 7145b722647e7c5db6e64d796f9fa316f7931b0f..d87638c138eab5453fa09a7360b875bfe3ea9c2d 100644 (file)
@@ -563,7 +563,7 @@ static int uli526x_rx_packet(struct eth_device *dev)
                        /* error summary bit check */
                        if (rdes0 & 0x8000) {
                                /* This is a error packet */
-                               printf("Eroor: rdes0: %lx\n", rdes0);
+                               printf("Error: rdes0: %x\n", rdes0);
                        }
 
                        if (!(rdes0 & 0x8000) ||
index 3157bc8b00e4c79bdb2e00f84f6bddaa4e937b9a..d8c5ed4a9edfd05b63f50514ae99ab45038e3af8 100644 (file)
@@ -278,7 +278,7 @@ static void test_error(
        p[2] = pattern;
 
        printf ("\nError at step %s, addr %08lx: read %08lx, pattern %08lx",
-               (unsigned long)step, addr, val, pattern);
+               step, (unsigned long)addr, val, pattern);
 }
 
 static void signal_init(void)
index 6b46fa88684640d134ad7ef94217e1c57b9abfbf..1c6cf7ce000257b1d91729f95f36b51ccdd5020e 100644 (file)
@@ -25,19 +25,21 @@ void lmb_dump_all(struct lmb *lmb)
        debug("    memory.size             = 0x%llx\n",
              (unsigned long long)lmb->memory.size);
        for (i=0; i < lmb->memory.cnt ;i++) {
-               debug("    memory.reg[0x%x].base   = 0x%llx\n", i,
-                       lmb->memory.region[i].base);
+               debug("    memory.reg[0x%lx].base   = 0x%llx\n", i,
+                       (long long unsigned)lmb->memory.region[i].base);
                debug("            .size   = 0x%llx\n",
-                       lmb->memory.region[i].size);
+                       (long long unsigned)lmb->memory.region[i].size);
        }
 
-       debug("\n    reserved.cnt          = 0x%lx\n", lmb->reserved.cnt);
-       debug("    reserved.size           = 0x%llx\n", lmb->reserved.size);
+       debug("\n    reserved.cnt          = 0x%lx\n",
+               lmb->reserved.cnt);
+       debug("    reserved.size           = 0x%llx\n",
+               (long long unsigned)lmb->reserved.size);
        for (i=0; i < lmb->reserved.cnt ;i++) {
-               debug("    reserved.reg[0x%x].base = 0x%llx\n", i,
-                       lmb->reserved.region[i].base);
+               debug("    reserved.reg[0x%lx].base = 0x%llx\n", i,
+                       (long long unsigned)lmb->reserved.region[i].base);
                debug("              .size = 0x%llx\n",
-                       lmb->reserved.region[i].size);
+                       (long long unsigned)lmb->reserved.region[i].size);
        }
 #endif /* DEBUG */
 }
@@ -266,7 +268,7 @@ phys_addr_t lmb_alloc_base(struct lmb *lmb, phys_size_t size, ulong align, phys_
 
        if (alloc == 0)
                printf("ERROR: Failed to allocate 0x%lx bytes below 0x%lx.\n",
-                     size, max_addr);
+                     (ulong)size, (ulong)max_addr);
 
        return alloc;
 }
index f55c7facf2783676ccd683e90fd45523e899e9f6..2a26bc0dd1d75ff03f22d5bcc0b1681691934c27 100644 (file)
--- a/net/net.c
+++ b/net/net.c
@@ -1520,7 +1520,8 @@ NetReceive(volatile uchar * inpkt, int len)
                                xsum = (xsum & 0x0000ffff) + ((xsum >> 16) & 0x0000ffff);
                        }
                        if ((xsum != 0x00000000) && (xsum != 0x0000ffff)) {
-                               printf(" UDP wrong checksum %08x %08x\n", xsum, ntohs(ip->udp_xsum));
+                               printf(" UDP wrong checksum %08lx %08x\n",
+                                       xsum, ntohs(ip->udp_xsum));
                                return;
                        }
                }