aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc/eeh.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-powerpc/eeh.h')
-rw-r--r--include/asm-powerpc/eeh.h16
1 files changed, 3 insertions, 13 deletions
diff --git a/include/asm-powerpc/eeh.h b/include/asm-powerpc/eeh.h
index 868c7139dbff..4df3e80118f4 100644
--- a/include/asm-powerpc/eeh.h
+++ b/include/asm-powerpc/eeh.h
@@ -21,7 +21,6 @@
21#define _PPC64_EEH_H 21#define _PPC64_EEH_H
22#ifdef __KERNEL__ 22#ifdef __KERNEL__
23 23
24#include <linux/config.h>
25#include <linux/init.h> 24#include <linux/init.h>
26#include <linux/list.h> 25#include <linux/list.h>
27#include <linux/string.h> 26#include <linux/string.h>
@@ -293,8 +292,6 @@ static inline void eeh_memcpy_toio(volatile void __iomem *dest, const void *src,
293static inline u8 eeh_inb(unsigned long port) 292static inline u8 eeh_inb(unsigned long port)
294{ 293{
295 u8 val; 294 u8 val;
296 if (!_IO_IS_VALID(port))
297 return ~0;
298 val = in_8((u8 __iomem *)(port+pci_io_base)); 295 val = in_8((u8 __iomem *)(port+pci_io_base));
299 if (EEH_POSSIBLE_ERROR(val, u8)) 296 if (EEH_POSSIBLE_ERROR(val, u8))
300 return eeh_check_failure((void __iomem *)(port), val); 297 return eeh_check_failure((void __iomem *)(port), val);
@@ -303,15 +300,12 @@ static inline u8 eeh_inb(unsigned long port)
303 300
304static inline void eeh_outb(u8 val, unsigned long port) 301static inline void eeh_outb(u8 val, unsigned long port)
305{ 302{
306 if (_IO_IS_VALID(port)) 303 out_8((u8 __iomem *)(port+pci_io_base), val);
307 out_8((u8 __iomem *)(port+pci_io_base), val);
308} 304}
309 305
310static inline u16 eeh_inw(unsigned long port) 306static inline u16 eeh_inw(unsigned long port)
311{ 307{
312 u16 val; 308 u16 val;
313 if (!_IO_IS_VALID(port))
314 return ~0;
315 val = in_le16((u16 __iomem *)(port+pci_io_base)); 309 val = in_le16((u16 __iomem *)(port+pci_io_base));
316 if (EEH_POSSIBLE_ERROR(val, u16)) 310 if (EEH_POSSIBLE_ERROR(val, u16))
317 return eeh_check_failure((void __iomem *)(port), val); 311 return eeh_check_failure((void __iomem *)(port), val);
@@ -320,15 +314,12 @@ static inline u16 eeh_inw(unsigned long port)
320 314
321static inline void eeh_outw(u16 val, unsigned long port) 315static inline void eeh_outw(u16 val, unsigned long port)
322{ 316{
323 if (_IO_IS_VALID(port)) 317 out_le16((u16 __iomem *)(port+pci_io_base), val);
324 out_le16((u16 __iomem *)(port+pci_io_base), val);
325} 318}
326 319
327static inline u32 eeh_inl(unsigned long port) 320static inline u32 eeh_inl(unsigned long port)
328{ 321{
329 u32 val; 322 u32 val;
330 if (!_IO_IS_VALID(port))
331 return ~0;
332 val = in_le32((u32 __iomem *)(port+pci_io_base)); 323 val = in_le32((u32 __iomem *)(port+pci_io_base));
333 if (EEH_POSSIBLE_ERROR(val, u32)) 324 if (EEH_POSSIBLE_ERROR(val, u32))
334 return eeh_check_failure((void __iomem *)(port), val); 325 return eeh_check_failure((void __iomem *)(port), val);
@@ -337,8 +328,7 @@ static inline u32 eeh_inl(unsigned long port)
337 328
338static inline void eeh_outl(u32 val, unsigned long port) 329static inline void eeh_outl(u32 val, unsigned long port)
339{ 330{
340 if (_IO_IS_VALID(port)) 331 out_le32((u32 __iomem *)(port+pci_io_base), val);
341 out_le32((u32 __iomem *)(port+pci_io_base), val);
342} 332}
343 333
344/* in-string eeh macros */ 334/* in-string eeh macros */