diff options
Diffstat (limited to 'drivers/edac/i3200_edac.c')
-rw-r--r-- | drivers/edac/i3200_edac.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/edac/i3200_edac.c b/drivers/edac/i3200_edac.c index d41f9002da4..aa08497a075 100644 --- a/drivers/edac/i3200_edac.c +++ b/drivers/edac/i3200_edac.c | |||
@@ -101,6 +101,19 @@ struct i3200_priv { | |||
101 | 101 | ||
102 | static int nr_channels; | 102 | static int nr_channels; |
103 | 103 | ||
104 | #ifndef readq | ||
105 | static inline __u64 readq(const volatile void __iomem *addr) | ||
106 | { | ||
107 | const volatile u32 __iomem *p = addr; | ||
108 | u32 low, high; | ||
109 | |||
110 | low = readl(p); | ||
111 | high = readl(p + 1); | ||
112 | |||
113 | return low + ((u64)high << 32); | ||
114 | } | ||
115 | #endif | ||
116 | |||
104 | static int how_many_channels(struct pci_dev *pdev) | 117 | static int how_many_channels(struct pci_dev *pdev) |
105 | { | 118 | { |
106 | unsigned char capid0_8b; /* 8th byte of CAPID0 */ | 119 | unsigned char capid0_8b; /* 8th byte of CAPID0 */ |