public inbox for linux-m68k@lists.linux-m68k.org
 help / color / mirror / Atom feed
* [PATCH] USB: isp116x: Fix EtherNAT if !CONFIG_ATARI_ROM_ISA
@ 2014-09-14  9:39 Geert Uytterhoeven
  2014-09-28  9:39 ` Geert Uytterhoeven
  0 siblings, 1 reply; 3+ messages in thread
From: Geert Uytterhoeven @ 2014-09-14  9:39 UTC (permalink / raw)
  To: Michael Schmitz; +Cc: linux-m68k, Geert Uytterhoeven

Commit eece8a651c96a2a3 ("USB: isp116x: isa_rom_*() calls should depend
on CONFIG_ATARI_ROM_ISA") broke USB on EtherNAT if CONFIG_ATARI_ROM_ISA
is not set, as USB on EtherNAT requires byte-swapped I/O accessors.

Add a separate #elif section for Atari without ROM port ISA to fix this.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
To be folded into "m68k/atari: USB - add ISP1160 USB host controller
support"
---
 drivers/usb/host/isp116x.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/usb/host/isp116x.h b/drivers/usb/host/isp116x.h
index 634258df159b..adebe0251574 100644
--- a/drivers/usb/host/isp116x.h
+++ b/drivers/usb/host/isp116x.h
@@ -369,6 +369,14 @@ struct isp116x_ep {
 #define isp_writew(v, p)	((((unsigned long)(__pa(p)) & 0x00000F00) == 0x00000300UL) ? isa_rom_writew_raw((v), __pa(p)) : __raw_writew((v), (p)))
 #define isp_raw_readw(p)	((((unsigned long)(__pa(p)) & 0x00000F00) == 0x00000300UL) ? isa_rom_readw(__pa(p)) : readw((p)))
 #define isp_raw_writew(v, p)	((((unsigned long)(__pa(p)) & 0x00000F00) == 0x00000300UL) ? isa_rom_writew((v), __pa(p)) : writew((v), (p)))
+#elif defined(CONFIG_ATARI)
+  /*
+   * 16 bit data bus byte swapped in hardware on EtherNAT only.
+   */
+#define isp_readw		__raw_readw
+#define isp_writew		__raw_writew
+#define isp_raw_readw		readw
+#define isp_raw_writew		writew
 #else
   /* sane hardware */
 #define isp_readw		readw
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-09-29 12:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-14  9:39 [PATCH] USB: isp116x: Fix EtherNAT if !CONFIG_ATARI_ROM_ISA Geert Uytterhoeven
2014-09-28  9:39 ` Geert Uytterhoeven
2014-09-29 12:08   ` Michael Schmitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox