summaryrefslogtreecommitdiffstats
path: root/include/configs/wepep250.h
blob: b70a53139060fdce94badb6edd8eded9bf861ebd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
/*
 * Copyright (C) 2003 ETC s.r.o.
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License as
 * published by the Free Software Foundation; either version 2 of
 * the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
 * MA 02111-1307 USA
 *
 * Written by Peter Figuli <peposh@etc.sk>, 2003.
 *
 */

#ifndef __CONFIG_H
#define __CONFIG_H

#define CONFIG_PXA250          1        /* this is an PXA250 CPU     */
#define CONFIG_WEPEP250        1        /* config for wepep250 board */
#undef  CONFIG_USE_IRQ                  /* don't need use IRQ/FIQ    */


/*
 * Select serial console configuration
 */
#define CONFIG_BTUART          1       /* BTUART is default on WEP dev board */
#define CONFIG_BAUDRATE   115200


/*
 * BOOTP options
 */
#define CONFIG_BOOTP_BOOTFILESIZE
#define CONFIG_BOOTP_BOOTPATH
#define CONFIG_BOOTP_GATEWAY
#define CONFIG_BOOTP_HOSTNAME


/*
 * Command line configuration.
 */
#include <config_cmd_default.h>

#undef CONFIG_CMD_NET
#undef CONFIG_CMD_LOADS
#undef CONFIG_CMD_CONSOLE
#undef CONFIG_CMD_AUTOSCRIPT


/*
 * Boot options. Setting delay to -1 stops autostart count down.
 * NOTE: Sending parameters to kernel depends on kernel version and
 * 2.4.19-rmk6-pxa1 patch used while my u-boot coding didn't accept
 * parameters at all! Do not get confused by them so.
 */
#define CONFIG_BOOTDELAY   -1
#define CONFIG_BOOTARGS    "root=/dev/mtdblock2 mem=32m console=ttyS01,115200n8"
#define CONFIG_BOOTCOMMAND "bootm 40000"


/*
 * General options for u-boot. Modify to save memory foot print
 */
#define CONFIG_SYS_LONGHELP                                  /* undef saves memory  */
#define CONFIG_SYS_PROMPT              "WEP> "               /* prompt string       */
#define CONFIG_SYS_CBSIZE              256                   /* console I/O buffer  */
#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE+sizeof(CONFIG_SYS_PROMPT)+16) /* print buffer size   */
#define CONFIG_SYS_MAXARGS             16                    /* max command args    */
#define CONFIG_SYS_BARGSIZE            CONFIG_SYS_CBSIZE            /* boot args buf size  */

#define CONFIG_SYS_MEMTEST_START       0xa0400000            /* memtest test area   */
#define CONFIG_SYS_MEMTEST_END         0xa0800000

#undef  CONFIG_SYS_CLKS_IN_HZ                       /* use HZ for freq. display     */

#define CONFIG_SYS_HZ                  3686400      /* incrementer freq: 3.6864 MHz */
#define CONFIG_SYS_CPUSPEED            0x141        /* core clock - register value  */

#define CONFIG_SYS_BAUDRATE_TABLE      { 9600, 19200, 38400, 57600, 115200 }

/*
 * Definitions related to passing arguments to kernel.
 */
#define CONFIG_CMDLINE_TAG           1   /* send commandline to Kernel       */
#define CONFIG_SETUP_MEMORY_TAGS     1   /* send memory definition to kernel */
#undef  CONFIG_INITRD_TAG                /* do not send initrd params        */
#undef  CONFIG_VFD                       /* do not send framebuffer setup    */


/*
 * Malloc pool need to host env + 128 Kb reserve for other allocations.
 */
#define CONFIG_SYS_MALLOC_LEN	  (CONFIG_ENV_SIZE + (128<<10) )
#define CONFIG_SYS_GBL_DATA_SIZE	128	/* size in bytes reserved for initial data */

#define CONFIG_STACKSIZE        (120<<10)      /* stack size */

#ifdef CONFIG_USE_IRQ
#define CONFIG_STACKSIZE_IRQ    (4<<10)        /* IRQ stack  */
#define CONFIG_STACKSIZE_FIQ    (4<<10)        /* FIQ stack  */
#endif

/*
 * SDRAM Memory Map
 */
#define CONFIG_NR_DRAM_BANKS    1                /* we have 1 bank of SDRAM */
#define WEP_SDRAM_1            0xa0000000        /* SDRAM bank #1           */
#define WEP_SDRAM_1_SIZE       0x02000000        /* 32 MB ( 2 chip )        */
#define WEP_SDRAM_2            0xa2000000        /* SDRAM bank #2           */
#define WEP_SDRAM_2_SIZE       0x00000000        /* 0 MB                    */
#define WEP_SDRAM_3            0xa8000000        /* SDRAM bank #3           */
#define WEP_SDRAM_3_SIZE       0x00000000        /* 0 MB                    */
#define WEP_SDRAM_4            0xac000000        /* SDRAM bank #4           */
#define WEP_SDRAM_4_SIZE       0x00000000        /* 0 MB                    */

#define CONFIG_SYS_DRAM_BASE           0xa0000000
#define CONFIG_SYS_DRAM_SIZE           0x02000000

/* Uncomment used SDRAM chip */
#define WEP_SDRAM_K4S281633
/*#define WEP_SDRAM_K4S561633*/


/*
 * Configuration for FLASH memory
 */
#define CONFIG_SYS_MAX_FLASH_BANKS	1	/* FLASH banks count (not chip count)*/
#define CONFIG_SYS_MAX_FLASH_SECT	128	/* number of sector in FLASH bank    */
#define WEP_FLASH_BUS_WIDTH	4	/* we use 32 bit FLASH memory...     */
#define WEP_FLASH_INTERLEAVE	2	/* ... made of 2 chips */
#define WEP_FLASH_BANK_SIZE  0x2000000  /* size of one flash bank*/
#define WEP_FLASH_SECT_SIZE  0x0040000  /* size of erase sector */
#define WEP_FLASH_BASE       0x0000000  /* location of flash memory */
#define WEP_FLASH_UNLOCK        1       /* perform hw unlock first */


/* This should be defined if CFI FLASH device is present. Actually benefit
   is not so clear to me. In other words we can provide more informations
   to user, but this expects more complex flash handling we do not provide
   now.*/
#undef  CONFIG_SYS_FLASH_CFI

#define CONFIG_SYS_FLASH_ERASE_TOUT    (2*CONFIG_SYS_HZ)    /* timeout for Erase operation */
#define CONFIG_SYS_FLASH_WRITE_TOUT    (2*CONFIG_SYS_HZ)    /* timeout for Write operation */

#define CONFIG_SYS_FLASH_BASE          WEP_FLASH_BASE

/*
 * This is setting for JFFS2 support in u-boot.
 * Right now there is no gain for user, but later on booting kernel might be
 * possible. Consider using XIP kernel running from flash to save RAM
 * footprint.
 * NOTE: Enable CONFIG_CMD_JFFS2 for JFFS2 support.
 */
#define CONFIG_SYS_JFFS2_FIRST_BANK		0
#define CONFIG_SYS_JFFS2_FIRST_SECTOR		5
#define CONFIG_SYS_JFFS2_NUM_BANKS		1

/*
 * Environment setup. Definitions of monitor location and size with
 * definition of environment setup ends up in 2 possibilities.
 * 1. Embeded environment - in u-boot code is space for environment
 * 2. Environment is read from predefined sector of flash
 * Right now we support 2. possiblity, but expecting no env placed
 * on mentioned address right now. This also needs to provide whole
 * sector for it - for us 256Kb is really waste of memory. U-boot uses
 * default env. and until kernel parameters could be sent to kernel
 * env. has no sense to us.
 */

#define CONFIG_SYS_MONITOR_BASE	PHYS_FLASH_1
#define CONFIG_SYS_MONITOR_LEN		0x20000		/* 128kb ( 1 flash sector )  */
#define CONFIG_ENV_IS_IN_FLASH	1
#define CONFIG_ENV_ADDR		0x20000	        /* absolute address for now  */
#define CONFIG_ENV_SIZE		0x2000

#undef  CONFIG_ENV_OVERWRITE                    /* env is not writable now   */

/*
 * Well this has to be defined, but on the other hand it is used differently
 * one may expect. For instance loadb command do not cares :-)
 * So advice is - do not relay on this...
 */
#define CONFIG_SYS_LOAD_ADDR        0x40000

#endif  /* __CONFIG_H */