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