From 8bde7f776c77b343aca29b8c7b58464d915ac245 Mon Sep 17 00:00:00 2001 From: wdenk Date: Fri, 27 Jun 2003 21:31:46 +0000 Subject: * Code cleanup: - remove trailing white space, trailing empty lines, C++ comments, etc. - split cmd_boot.c (separate cmd_bdinfo.c and cmd_load.c) * Patches by Kenneth Johansson, 25 Jun 2003: - major rework of command structure (work done mostly by Michal Cendrowski and Joakim Kristiansen) --- board/pcippc2/Makefile | 2 +- board/pcippc2/cpc710_pci.c | 2 +- board/pcippc2/pcippc2.c | 14 ++++++++++++-- board/pcippc2/u-boot.lds | 5 +++++ 4 files changed, 19 insertions(+), 4 deletions(-) (limited to 'board/pcippc2') diff --git a/board/pcippc2/Makefile b/board/pcippc2/Makefile index d77110045..2998f23eb 100644 --- a/board/pcippc2/Makefile +++ b/board/pcippc2/Makefile @@ -33,7 +33,7 @@ AOBJS = OBJS = $(COBJS) $(AOBJS) $(LIB): .depend $(OBJS) - $(AR) crv $@ $^ + $(AR) crv $@ $(OBJS) ######################################################################### diff --git a/board/pcippc2/cpc710_pci.c b/board/pcippc2/cpc710_pci.c index 9975cdaa5..bed8aeab0 100644 --- a/board/pcippc2/cpc710_pci.c +++ b/board/pcippc2/cpc710_pci.c @@ -53,7 +53,7 @@ void cpc710_pci_init (void) u32 sdram_size = pcippc2_sdram_size(); cpc710_mapped_ram = sdram_size < PCI_MEMORY_MAXSIZE ? - sdram_size : PCI_MEMORY_MAXSIZE; + sdram_size : PCI_MEMORY_MAXSIZE; /* Select the local PCI */ diff --git a/board/pcippc2/pcippc2.c b/board/pcippc2/pcippc2.c index bab3c205a..fd3d4795d 100644 --- a/board/pcippc2/pcippc2.c +++ b/board/pcippc2/pcippc2.c @@ -66,11 +66,13 @@ long initdram (int board_type) return cpc710_ram_init (); } -void do_reset (cmd_tbl_t *cmdtp, bd_t *bd, int flag, int argc, char *argv[]) +int do_reset (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) { out32 (REG (CPC0, SPOR), 0); iobarrier_rw (); while (1); + /* notreached */ + return (-1); } int board_pre_init (void) @@ -201,7 +203,7 @@ void watchdog_reset (void) } #if (CONFIG_COMMANDS & CFG_CMD_BSP) -int do_wd (cmd_tbl_t *cmdtp, bd_t *bd, int flag, int argc, char *argv[]) +int do_wd (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) { switch (argc) { case 1: @@ -231,5 +233,13 @@ int do_wd (cmd_tbl_t *cmdtp, bd_t *bd, int flag, int argc, char *argv[]) return 1; } +cmd_tbl_t U_BOOT_CMD(wd) = MK_CMD_ENTRY( + "wd", 2, 1, do_wd, + "wd - check and set watchdog\n", + "on - switch watchDog on\n" + "wd off - switch watchdog off\n" + "wd - print current status\n" +); + #endif /* CFG_CMD_BSP */ #endif /* CONFIG_WATCHDOG */ diff --git a/board/pcippc2/u-boot.lds b/board/pcippc2/u-boot.lds index 8f480681a..6ead7f2b0 100644 --- a/board/pcippc2/u-boot.lds +++ b/board/pcippc2/u-boot.lds @@ -109,6 +109,11 @@ SECTIONS _edata = .; PROVIDE (edata = .); + __u_boot_cmd_start = .; + .u_boot_cmd : { *(.u_boot_cmd) } + __u_boot_cmd_end = .; + + __start___ex_table = .; __ex_table : { *(__ex_table) } __stop___ex_table = .; -- cgit v1.2.3