summaryrefslogtreecommitdiff
path: root/common/cmd_ide.c
diff options
context:
space:
mode:
authorWolfgang Denk <wd@nyx.denx.de>2006-06-19 01:46:08 +0200
committerWolfgang Denk <wd@nyx.denx.de>2006-06-19 01:46:08 +0200
commit8d352247ecf3638cdd1ef7df31a6ad700bb80574 (patch)
treed8f2202361ce6cc944abb39195f66411003b0571 /common/cmd_ide.c
parent9e18a4bc6cb512dc7ae3a6fc2ed912f71bd8c6c0 (diff)
parenta650cfa286e8933144a776693d56dfd858922aa4 (diff)
downloadu-boot-imx-8d352247ecf3638cdd1ef7df31a6ad700bb80574.zip
u-boot-imx-8d352247ecf3638cdd1ef7df31a6ad700bb80574.tar.gz
u-boot-imx-8d352247ecf3638cdd1ef7df31a6ad700bb80574.tar.bz2
Merge with ssh://atlas/home/wd/git/u-boot/work
Diffstat (limited to 'common/cmd_ide.c')
-rw-r--r--common/cmd_ide.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/common/cmd_ide.c b/common/cmd_ide.c
index 41621ba..a415502 100644
--- a/common/cmd_ide.c
+++ b/common/cmd_ide.c
@@ -855,7 +855,7 @@ output_data_short(int dev, ulong *sect_buf, int words)
/* We only need to swap data if we are running on a big endian cpu. */
/* But Au1x00 cpu:s already swaps data in big endian mode! */
-#if defined(__LITTLE_ENDIAN) || defined(CONFIG_AU1X00)
+#if defined(__LITTLE_ENDIAN) || ( defined(CONFIG_AU1X00) && !defined(CONFIG_GTH2) )
#define input_swap_data(x,y,z) input_data(x,y,z)
#else
static void
@@ -881,8 +881,13 @@ input_swap_data(int dev, ulong *sect_buf, int words)
debug("in input swap data base for read is %lx\n", (unsigned long) pbuf);
while (words--) {
+#ifdef __MIPS__
+ *dbuf++ = swab16p((u16*)pbuf);
+ *dbuf++ = swab16p((u16*)pbuf);
+#else
*dbuf++ = ld_le16(pbuf);
*dbuf++ = ld_le16(pbuf);
+#endif /* !MIPS */
}
#endif
}