]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - include/cmd_boot.h
Add PCI support for MPC8250 Boards (PM825 module)
[karo-tx-uboot.git] / include / cmd_boot.h
1 /*
2  * (C) Copyright 2000
3  * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4  *
5  * See file CREDITS for list of people who contributed to this
6  * project.
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License as
10  * published by the Free Software Foundation; either version 2 of
11  * the License, or (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, write to the Free Software
20  * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
21  * MA 02111-1307 USA
22  */
23
24 /*
25  * Boot support
26  */
27 #ifndef _CMD_BOOT_H
28 #define _CMD_BOOT_H
29
30 #if (CONFIG_COMMANDS & CFG_CMD_BDI)
31 #define CMD_TBL_BDINFO  MK_CMD_TBL_ENTRY(                                       \
32         "bdinfo",       2,      1,      1,      do_bdinfo,                      \
33         "bdinfo  - print Board Info structure\n",                               \
34         NULL                                                                    \
35 ),
36 int do_bdinfo (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
37
38 #else
39 #define CMD_TBL_BDINFO
40 #endif
41
42
43 #define CMD_TBL_GO      MK_CMD_TBL_ENTRY(                                       \
44         "go",           2,      CFG_MAXARGS,    1,      do_go,                  \
45         "go      - start application at address 'addr'\n",                      \
46         "addr [arg ...]\n    - start application at address 'addr'\n"           \
47         "      passing 'arg' as arguments\n"                                    \
48 ),
49 int do_go (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
50
51 #if (CONFIG_COMMANDS & CFG_CMD_LOADS)
52 #ifdef  CFG_LOADS_BAUD_CHANGE
53 #define CMD_TBL_LOADS   MK_CMD_TBL_ENTRY(                                       \
54         "loads",        5,      3,      0,      do_load_serial,                 \
55         "loads   - load S-Record file over serial line\n",                      \
56         "[ off ] [ baud ]\n"                                                    \
57         "    - load S-Record file over serial line"                             \
58         " with offset 'off' and baudrate 'baud'\n"                              \
59 ),
60 #else   /* ! CFG_LOADS_BAUD_CHANGE */
61 #define CMD_TBL_LOADS   MK_CMD_TBL_ENTRY(                                       \
62         "loads",        5,      2,      0,      do_load_serial,                 \
63         "loads   - load S-Record file over serial line\n",                      \
64         "[ off ]\n"                                                             \
65         "    - load S-Record file over serial line with offset 'off'\n"         \
66 ),
67 #endif  /* CFG_LOADS_BAUD_CHANGE */
68 int do_load_serial (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
69
70 /*
71  * SAVES always requires LOADS support, but not vice versa
72  */
73 #if (CONFIG_COMMANDS & CFG_CMD_SAVES)
74 #ifdef  CFG_LOADS_BAUD_CHANGE
75 #define CMD_TBL_SAVES   MK_CMD_TBL_ENTRY(                                       \
76         "saves",        5,      4,      0,      do_save_serial,                 \
77         "saves   - save S-Record file over serial line\n",                      \
78         "[ off ] [size] [ baud ]\n"                                                     \
79         "    - save S-Record file over serial line"                             \
80         " with offset 'off', size 'size' and baudrate 'baud'\n"                         \
81 ),
82 #else   /* ! CFG_LOADS_BAUD_CHANGE */
83 #define CMD_TBL_SAVES   MK_CMD_TBL_ENTRY(                                       \
84         "saves",        5,      3,      0,      do_save_serial,                 \
85         "saves   - save S-Record file over serial line\n",                      \
86         "[ off ] [size]\n"                                                              \
87         "    - save S-Record file over serial line with offset 'off' and size 'size'\n"         \
88 ),
89 #endif  /* CFG_LOADS_BAUD_CHANGE */
90
91 int do_save_serial (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
92 #else   /* ! CFG_CMD_SAVES */
93 #define CMD_TBL_SAVES
94 #endif  /* CFG_CMD_SAVES */
95
96 #else   /* ! CFG_CMD_LOADS */
97 #define CMD_TBL_LOADS
98 #define CMD_TBL_SAVES
99 #endif  /* CFG_CMD_LOADS */
100
101
102 #if (CONFIG_COMMANDS & CFG_CMD_LOADB)
103 #define CMD_TBL_LOADB   MK_CMD_TBL_ENTRY(                                       \
104         "loadb",        5,      3,      0,      do_load_serial_bin,             \
105         "loadb   - load binary file over serial line (kermit mode)\n",          \
106         "[ off ] [ baud ]\n"                                                    \
107         "    - load binary file over serial line"                               \
108         " with offset 'off' and baudrate 'baud'\n"                              \
109 ),
110 int do_load_serial_bin (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
111
112 #else
113 #define CMD_TBL_LOADB
114 #endif  /* CFG_CMD_LOADB */
115
116 #define CMD_TBL_RESET   MK_CMD_TBL_ENTRY(                                       \
117         "reset",        5,      1,      0,      do_reset,                       \
118         "reset   - Perform RESET of the CPU\n",                                 \
119         NULL                                                                    \
120 ),
121
122 /* Implemented in $(CPU)/cpu.c */
123 int do_reset (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
124
125 #if (CONFIG_COMMANDS & CFG_CMD_HWFLOW)
126 #define CMD_TBL_HWFLOW  MK_CMD_TBL_ENTRY(                                       \
127         "hwflow [on|off]",      2,      2,      0,      do_hwflow,                      \
128     "hwflow  - turn the harwdare flow control on/off\n", \
129         "\n - change RTS/CTS hardware flow control over serial line\n" \
130 ),
131
132 int do_hwflow (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
133
134 #else
135 #define CMD_TBL_HWFLOW
136 #endif
137 #endif  /* _CMD_BOOT_H */