diff options
author | wdenk | 2003-10-09 20:09:04 +0000 |
---|---|---|
committer | wdenk | 2003-10-09 20:09:04 +0000 |
commit | 5da627a424b3ad2d38a81886ba4a18e5123a6788 (patch) | |
tree | 13d274effe8b9c740a07f4cb47989f3215c20bb4 /common/cmd_ide.c | |
parent | 15647dc7fd86bbaeb68740929ecb9f8473c7ceae (diff) |
* Patch by Steven Scholz, 10 Oct 2003
- Add support for Altera FPGA ACEX1K
* Patches by Thomas Lange, 09 Oct 2003:
- Endian swap ATA identity for all big endian CPUs, not just PPC
- MIPS only: New option CONFIG_MEMSIZE_IN_BYTES for passing memsize
args to linux
- add support for dbau1x00 board (MIPS32)
Diffstat (limited to 'common/cmd_ide.c')
-rw-r--r-- | common/cmd_ide.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/common/cmd_ide.c b/common/cmd_ide.c index ae5602b138d..21a666644f9 100644 --- a/common/cmd_ide.c +++ b/common/cmd_ide.c @@ -170,9 +170,6 @@ static uchar ide_wait (int dev, ulong t); static void __inline__ ide_outb(int dev, int port, unsigned char val); static unsigned char __inline__ ide_inb(int dev, int port); -#ifdef __PPC__ -static void input_swap_data(int dev, ulong *sect_buf, int words); -#endif static void input_data(int dev, ulong *sect_buf, int words); static void output_data(int dev, ulong *sect_buf, int words); static void ident_cpy (unsigned char *dest, unsigned char *src, unsigned int len); @@ -815,7 +812,13 @@ output_data_short(int dev, ulong *sect_buf, int words) *pbuf = 0; } # endif /* CONFIG_AMIGAONEG3SE */ +#endif /* __PPC_ */ +/* 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) +#define input_swap_data(x,y,z) input_data(x,y,z) +#else static void input_swap_data(int dev, ulong *sect_buf, int words) { @@ -827,9 +830,7 @@ input_swap_data(int dev, ulong *sect_buf, int words) *dbuf++ = ld_le16(pbuf); } } -#else /* ! __PPC__ */ -#define input_swap_data(x,y,z) input_data(x,y,z) -#endif /* __PPC__ */ +#endif /* __LITTLE_ENDIAN || CONFIG_AU1X00 */ #ifdef __PPC__ |