summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2007-08-14 18:43:14 +0200
committerWolfgang Denk <wd@denx.de>2007-08-14 18:43:14 +0200
commit541d41b2f23182047c0d655ad8d795f33dd37df2 (patch)
treeb6c9395bacc120d62415f45a0598a41ea0b5d018 /common
parentf01dbb5424a81453c81190dd30e945891466f621 (diff)
parent3b3bff4cbf2cb14f9a3e7d03f26ebab900efe4ae (diff)
downloadu-boot-imx-541d41b2f23182047c0d655ad8d795f33dd37df2.zip
u-boot-imx-541d41b2f23182047c0d655ad8d795f33dd37df2.tar.gz
u-boot-imx-541d41b2f23182047c0d655ad8d795f33dd37df2.tar.bz2
Merge with /home/wd/git/u-boot/custodian/u-boot-ppc4xx
Diffstat (limited to 'common')
-rw-r--r--common/flash.c10
-rw-r--r--common/soft_spi.c2
2 files changed, 7 insertions, 5 deletions
diff --git a/common/flash.c b/common/flash.c
index a64bc98..888ff9c 100644
--- a/common/flash.c
+++ b/common/flash.c
@@ -47,16 +47,16 @@ flash_protect (int flag, ulong from, ulong to, flash_info_t *info)
short s_end = info->sector_count - 1; /* index of last sector */
int i;
- debug ("flash_protect %s: from 0x%08lX to 0x%08lX\n",
- (flag & FLAG_PROTECT_SET) ? "ON" :
- (flag & FLAG_PROTECT_CLEAR) ? "OFF" : "???",
- from, to);
-
/* Do nothing if input data is bad. */
if (info->sector_count == 0 || info->size == 0 || to < from) {
return;
}
+ debug ("flash_protect %s: from 0x%08lX to 0x%08lX\n",
+ (flag & FLAG_PROTECT_SET) ? "ON" :
+ (flag & FLAG_PROTECT_CLEAR) ? "OFF" : "???",
+ from, to);
+
/* There is nothing to do if we have no data about the flash
* or the protect range and flash range don't overlap.
*/
diff --git a/common/soft_spi.c b/common/soft_spi.c
index 00a57de..e425061 100644
--- a/common/soft_spi.c
+++ b/common/soft_spi.c
@@ -79,7 +79,9 @@ void spi_init (void)
*/
int spi_xfer(spi_chipsel_type chipsel, int bitlen, uchar *dout, uchar *din)
{
+#ifdef CFG_IMMR
volatile immap_t *immr = (immap_t *)CFG_IMMR;
+#endif
uchar tmpdin = 0;
uchar tmpdout = 0;
int j;