projects
/
oweals
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge with git://www.denx.de/git/u-boot.git
[oweals/u-boot.git]
/
board
/
bf533-stamp
/
bf533-stamp.c
diff --git
a/board/bf533-stamp/bf533-stamp.c
b/board/bf533-stamp/bf533-stamp.c
index 3e074e3a1b23f56f058980bdb61fc8e0895e8bb6..69e425bf974e7cf69a96d31067feca236416d3a4 100644
(file)
--- a/
board/bf533-stamp/bf533-stamp.c
+++ b/
board/bf533-stamp/bf533-stamp.c
@@
-1,7
+1,7
@@
/*
* U-boot - stamp.c STAMP board specific routines
*
/*
* U-boot - stamp.c STAMP board specific routines
*
- * Copyright (c) 2005
blackfin.uclinux.org
+ * Copyright (c) 2005
-2007 Analog Devices Inc.
*
* (C) Copyright 2000-2004
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*
* (C) Copyright 2000-2004
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
@@
-21,14
+21,17
@@
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
*
* 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., 5
9 Temple Place, Suite 330
, Boston,
- * MA 0211
1-1307
USA
+ * Foundation, Inc., 5
1 Franklin St, Fifth Floor
, Boston,
+ * MA 0211
0-1301
USA
*/
#include <common.h>
#include <asm/mem_init.h>
*/
#include <common.h>
#include <asm/mem_init.h>
+#include <asm/io.h>
#include "bf533-stamp.h"
#include "bf533-stamp.h"
+DECLARE_GLOBAL_DATA_PTR;
+
#define STATUS_LED_OFF 0
#define STATUS_LED_ON 1
#define STATUS_LED_OFF 0
#define STATUS_LED_ON 1
@@
-54,7
+57,6
@@
int checkboard(void)
long int initdram(int board_type)
{
long int initdram(int board_type)
{
- DECLARE_GLOBAL_DATA_PTR;
#ifdef DEBUG
printf("SDRAM attributes:\n");
printf
#ifdef DEBUG
printf("SDRAM attributes:\n");
printf
@@
-74,9
+76,9
@@
void swap_to(int device_id)
if (device_id == ETHERNET) {
*pFIO_DIR = PF0;
if (device_id == ETHERNET) {
*pFIO_DIR = PF0;
-
__builtin_bfin_s
sync();
+ sync();
*pFIO_FLAG_S = PF0;
*pFIO_FLAG_S = PF0;
-
__builtin_bfin_s
sync();
+ sync();
} else if (device_id == FLASH) {
*pFIO_DIR = (PF4 | PF3 | PF2 | PF1 | PF0);
*pFIO_FLAG_S = (PF4 | PF3 | PF2);
} else if (device_id == FLASH) {
*pFIO_DIR = (PF4 | PF3 | PF2 | PF1 | PF0);
*pFIO_FLAG_S = (PF4 | PF3 | PF2);
@@
-86,7
+88,7
@@
void swap_to(int device_id)
*pFIO_EDGE = (PF8 | PF7 | PF6 | PF5);
*pFIO_INEN = (PF8 | PF7 | PF6 | PF5);
*pFIO_FLAG_D = (PF4 | PF3 | PF2);
*pFIO_EDGE = (PF8 | PF7 | PF6 | PF5);
*pFIO_INEN = (PF8 | PF7 | PF6 | PF5);
*pFIO_FLAG_D = (PF4 | PF3 | PF2);
-
__builtin_bfin_s
sync();
+ sync();
} else {
printf("Unknown bank to switch\n");
}
} else {
printf("Unknown bank to switch\n");
}
@@
-153,15
+155,15
@@
void cf_outb(unsigned char val, volatile unsigned char *addr)
*/
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
*/
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
-
__builtin_bfin_s
sync();
+ sync();
*(addr) = val;
*(addr) = val;
-
__builtin_bfin_s
sync();
+ sync();
/* Setback PF1 PF0 to 0 0 to address external
* memory banks */
*(volatile unsigned short *)pFIO_FLAG_C = CF_PF1_PF0;
/* Setback PF1 PF0 to 0 0 to address external
* memory banks */
*(volatile unsigned short *)pFIO_FLAG_C = CF_PF1_PF0;
-
__builtin_bfin_s
sync();
+ sync();
}
unsigned char cf_inb(volatile unsigned char *addr)
}
unsigned char cf_inb(volatile unsigned char *addr)
@@
-170,13
+172,13
@@
unsigned char cf_inb(volatile unsigned char *addr)
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
-
__builtin_bfin_s
sync();
+ sync();
c = *(addr);
c = *(addr);
-
__builtin_bfin_s
sync();
+ sync();
*pFIO_FLAG_C = CF_PF1_PF0;
*pFIO_FLAG_C = CF_PF1_PF0;
-
__builtin_bfin_s
sync();
+ sync();
return c;
}
return c;
}
@@
-187,15
+189,15
@@
void cf_insw(unsigned short *sect_buf, unsigned short *addr, int words)
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
-
__builtin_bfin_s
sync();
+ sync();
for (i = 0; i < words; i++) {
*(sect_buf + i) = *(addr);
for (i = 0; i < words; i++) {
*(sect_buf + i) = *(addr);
-
__builtin_bfin_s
sync();
+ sync();
}
*pFIO_FLAG_C = CF_PF1_PF0;
}
*pFIO_FLAG_C = CF_PF1_PF0;
-
__builtin_bfin_s
sync();
+ sync();
}
void cf_outsw(unsigned short *addr, unsigned short *sect_buf, int words)
}
void cf_outsw(unsigned short *addr, unsigned short *sect_buf, int words)
@@
-204,15
+206,15
@@
void cf_outsw(unsigned short *addr, unsigned short *sect_buf, int words)
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
*pFIO_FLAG_S = CF_PF0;
*pFIO_FLAG_C = CF_PF1;
-
__builtin_bfin_s
sync();
+ sync();
for (i = 0; i < words; i++) {
*(addr) = *(sect_buf + i);
for (i = 0; i < words; i++) {
*(addr) = *(sect_buf + i);
-
__builtin_bfin_s
sync();
+ sync();
}
*pFIO_FLAG_C = CF_PF1_PF0;
}
*pFIO_FLAG_C = CF_PF1_PF0;
-
__builtin_bfin_s
sync();
+ sync();
}
#endif
}
#endif
@@
-233,7
+235,7
@@
void stamp_led_set(int LED1, int LED2, int LED3)
*pFIO_FLAG_S = PF4;
else
*pFIO_FLAG_C = PF4;
*pFIO_FLAG_S = PF4;
else
*pFIO_FLAG_C = PF4;
-
__builtin_bfin_s
sync();
+ sync();
}
void show_boot_progress(int status)
}
void show_boot_progress(int status)