Commit 68f50e52 authored by Al Viro's avatar Al Viro Committed by Linus Torvalds

[PATCH] hci_{read,write}l() does force casts to wrong type for no reason

readl() et.al. expect iomem pointer, so WTF force-cast it to normal one???
Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 53ebb3b8
...@@ -677,10 +677,10 @@ static inline unsigned int ehci_readl (const struct ehci_hcd *ehci, ...@@ -677,10 +677,10 @@ static inline unsigned int ehci_readl (const struct ehci_hcd *ehci,
{ {
#ifdef CONFIG_USB_EHCI_BIG_ENDIAN_MMIO #ifdef CONFIG_USB_EHCI_BIG_ENDIAN_MMIO
return ehci_big_endian_mmio(ehci) ? return ehci_big_endian_mmio(ehci) ?
readl_be((__force u32 *)regs) : readl_be(regs) :
readl((__force u32 *)regs); readl(regs);
#else #else
return readl((__force u32 *)regs); return readl(regs);
#endif #endif
} }
...@@ -689,10 +689,10 @@ static inline void ehci_writel (const struct ehci_hcd *ehci, ...@@ -689,10 +689,10 @@ static inline void ehci_writel (const struct ehci_hcd *ehci,
{ {
#ifdef CONFIG_USB_EHCI_BIG_ENDIAN_MMIO #ifdef CONFIG_USB_EHCI_BIG_ENDIAN_MMIO
ehci_big_endian_mmio(ehci) ? ehci_big_endian_mmio(ehci) ?
writel_be(val, (__force u32 *)regs) : writel_be(val, regs) :
writel(val, (__force u32 *)regs); writel(val, regs);
#else #else
writel(val, (__force u32 *)regs); writel(val, regs);
#endif #endif
} }
......
...@@ -507,10 +507,10 @@ static inline unsigned int _ohci_readl (const struct ohci_hcd *ohci, ...@@ -507,10 +507,10 @@ static inline unsigned int _ohci_readl (const struct ohci_hcd *ohci,
{ {
#ifdef CONFIG_USB_OHCI_BIG_ENDIAN_MMIO #ifdef CONFIG_USB_OHCI_BIG_ENDIAN_MMIO
return big_endian_mmio(ohci) ? return big_endian_mmio(ohci) ?
readl_be ((__force u32 *)regs) : readl_be (regs) :
readl ((__force u32 *)regs); readl (regs);
#else #else
return readl ((__force u32 *)regs); return readl (regs);
#endif #endif
} }
...@@ -519,10 +519,10 @@ static inline void _ohci_writel (const struct ohci_hcd *ohci, ...@@ -519,10 +519,10 @@ static inline void _ohci_writel (const struct ohci_hcd *ohci,
{ {
#ifdef CONFIG_USB_OHCI_BIG_ENDIAN_MMIO #ifdef CONFIG_USB_OHCI_BIG_ENDIAN_MMIO
big_endian_mmio(ohci) ? big_endian_mmio(ohci) ?
writel_be (val, (__force u32 *)regs) : writel_be (val, regs) :
writel (val, (__force u32 *)regs); writel (val, regs);
#else #else
writel (val, (__force u32 *)regs); writel (val, regs);
#endif #endif
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment