diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2006-12-27 23:26:59 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-02-07 18:44:32 -0500 |
commit | b32e904d54d163c6f97fc3c7586d381f4f11c3a5 (patch) | |
tree | f06669d447a8e2d4e6648394f54c9d7a1d4178e8 | |
parent | 083522d76662cda71328df1f3d75e5a9057c7c9f (diff) |
USB: Fix OHCI warning
This patch fixes a warning introduces by the split endian OHCI support
patch on platforms that don't have readl_be/writel_be variants (though
mostly harmless as those are called in an if (0) statement, but gcc
still warns).
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | drivers/usb/host/ohci.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/usb/host/ohci.h b/drivers/usb/host/ohci.h index fc7c1614cf9e..0dafcda37291 100644 --- a/drivers/usb/host/ohci.h +++ b/drivers/usb/host/ohci.h | |||
@@ -505,17 +505,25 @@ static inline struct usb_hcd *ohci_to_hcd (const struct ohci_hcd *ohci) | |||
505 | static inline unsigned int _ohci_readl (const struct ohci_hcd *ohci, | 505 | static inline unsigned int _ohci_readl (const struct ohci_hcd *ohci, |
506 | __hc32 __iomem * regs) | 506 | __hc32 __iomem * regs) |
507 | { | 507 | { |
508 | #ifdef CONFIG_USB_OHCI_BIG_ENDIAN_MMIO | ||
508 | return big_endian_mmio(ohci) ? | 509 | return big_endian_mmio(ohci) ? |
509 | readl_be ((__force u32 *)regs) : | 510 | readl_be ((__force u32 *)regs) : |
510 | readl ((__force u32 *)regs); | 511 | readl ((__force u32 *)regs); |
512 | #else | ||
513 | return readl ((__force u32 *)regs); | ||
514 | #endif | ||
511 | } | 515 | } |
512 | 516 | ||
513 | static inline void _ohci_writel (const struct ohci_hcd *ohci, | 517 | static inline void _ohci_writel (const struct ohci_hcd *ohci, |
514 | const unsigned int val, __hc32 __iomem *regs) | 518 | const unsigned int val, __hc32 __iomem *regs) |
515 | { | 519 | { |
520 | #ifdef CONFIG_USB_OHCI_BIG_ENDIAN_MMIO | ||
516 | big_endian_mmio(ohci) ? | 521 | big_endian_mmio(ohci) ? |
517 | writel_be (val, (__force u32 *)regs) : | 522 | writel_be (val, (__force u32 *)regs) : |
518 | writel (val, (__force u32 *)regs); | 523 | writel (val, (__force u32 *)regs); |
524 | #else | ||
525 | writel (val, (__force u32 *)regs); | ||
526 | #endif | ||
519 | } | 527 | } |
520 | 528 | ||
521 | #ifdef CONFIG_ARCH_LH7A404 | 529 | #ifdef CONFIG_ARCH_LH7A404 |