diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2020-06-11 07:35:39 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2020-06-11 07:35:39 +0200 |
commit | 1fb15fcfe9ecb079b88df7eb01f1e29144cd8f96 (patch) | |
tree | 651ae01bac7ed264934baccd0fccbfeec6905da6 /drivers/usb | |
parent | d6757bacf8180b17692682c58dd6a9938d0c3c1d (diff) | |
parent | aa2cd910c7465eaf6de04da1b4d110205ad63c77 (diff) | |
download | barebox-1fb15fcfe9ecb079b88df7eb01f1e29144cd8f96.tar.gz barebox-1fb15fcfe9ecb079b88df7eb01f1e29144cd8f96.tar.xz |
Merge branch 'for-next/sandbox-compile-test'
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/host/xhci.h | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/drivers/usb/host/xhci.h b/drivers/usb/host/xhci.h index 886cbef14c..9ffbb103d5 100644 --- a/drivers/usb/host/xhci.h +++ b/drivers/usb/host/xhci.h @@ -17,8 +17,8 @@ #define HOST_XHCI_H_ #include <asm/types.h> -#include <asm/cache.h> #include <io.h> +#include <io-64-nonatomic-lo-hi.h> #include <linux/list.h> #define MAX_EP_CTX_NUM 31 @@ -1113,10 +1113,7 @@ static inline u64 xhci_readq(__le64 volatile *regs) #if BITS_PER_LONG == 64 return readq(regs); #else - __u32 *ptr = (__u32 *)regs; - u64 val_lo = readl(ptr); - u64 val_hi = readl(ptr + 1); - return val_lo + (val_hi << 32); + return lo_hi_readq(regs); #endif } @@ -1125,12 +1122,7 @@ static inline void xhci_writeq(__le64 volatile *regs, const u64 val) #if BITS_PER_LONG == 64 writeq(val, regs); #else - __u32 *ptr = (__u32 *)regs; - u32 val_lo = lower_32_bits(val); - /* FIXME */ - u32 val_hi = upper_32_bits(val); - writel(val_lo, ptr); - writel(val_hi, ptr + 1); + lo_hi_writeq(val, regs); #endif } |