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 868c7139dbff..2c3dc4a2b12a 100644 --- a/include/asm-powerpc/eeh.h +++ b/include/asm-powerpc/eeh.h | |||
@@ -293,8 +293,6 @@ static inline void eeh_memcpy_toio(volatile void __iomem *dest, const void *src, | |||
293 | static inline u8 eeh_inb(unsigned long port) | 293 | static inline u8 eeh_inb(unsigned long port) |
294 | { | 294 | { |
295 | u8 val; | 295 | u8 val; |
296 | if (!_IO_IS_VALID(port)) | ||
297 | return ~0; | ||
298 | val = in_8((u8 __iomem *)(port+pci_io_base)); | 296 | val = in_8((u8 __iomem *)(port+pci_io_base)); |
299 | if (EEH_POSSIBLE_ERROR(val, u8)) | 297 | if (EEH_POSSIBLE_ERROR(val, u8)) |
300 | return eeh_check_failure((void __iomem *)(port), val); | 298 | return eeh_check_failure((void __iomem *)(port), val); |
@@ -303,15 +301,12 @@ static inline u8 eeh_inb(unsigned long port) | |||
303 | 301 | ||
304 | static inline void eeh_outb(u8 val, unsigned long port) | 302 | static inline void eeh_outb(u8 val, unsigned long port) |
305 | { | 303 | { |
306 | if (_IO_IS_VALID(port)) | 304 | out_8((u8 __iomem *)(port+pci_io_base), val); |
307 | out_8((u8 __iomem *)(port+pci_io_base), val); | ||
308 | } | 305 | } |
309 | 306 | ||
310 | static inline u16 eeh_inw(unsigned long port) | 307 | static inline u16 eeh_inw(unsigned long port) |
311 | { | 308 | { |
312 | u16 val; | 309 | u16 val; |
313 | if (!_IO_IS_VALID(port)) | ||
314 | return ~0; | ||
315 | val = in_le16((u16 __iomem *)(port+pci_io_base)); | 310 | val = in_le16((u16 __iomem *)(port+pci_io_base)); |
316 | if (EEH_POSSIBLE_ERROR(val, u16)) | 311 | if (EEH_POSSIBLE_ERROR(val, u16)) |
317 | return eeh_check_failure((void __iomem *)(port), val); | 312 | return eeh_check_failure((void __iomem *)(port), val); |
@@ -320,15 +315,12 @@ static inline u16 eeh_inw(unsigned long port) | |||
320 | 315 | ||
321 | static inline void eeh_outw(u16 val, unsigned long port) | 316 | static inline void eeh_outw(u16 val, unsigned long port) |
322 | { | 317 | { |
323 | if (_IO_IS_VALID(port)) | 318 | out_le16((u16 __iomem *)(port+pci_io_base), val); |
324 | out_le16((u16 __iomem *)(port+pci_io_base), val); | ||
325 | } | 319 | } |
326 | 320 | ||
327 | static inline u32 eeh_inl(unsigned long port) | 321 | static inline u32 eeh_inl(unsigned long port) |
328 | { | 322 | { |
329 | u32 val; | 323 | u32 val; |
330 | if (!_IO_IS_VALID(port)) | ||
331 | return ~0; | ||
332 | val = in_le32((u32 __iomem *)(port+pci_io_base)); | 324 | val = in_le32((u32 __iomem *)(port+pci_io_base)); |
333 | if (EEH_POSSIBLE_ERROR(val, u32)) | 325 | if (EEH_POSSIBLE_ERROR(val, u32)) |
334 | return eeh_check_failure((void __iomem *)(port), val); | 326 | return eeh_check_failure((void __iomem *)(port), val); |
@@ -337,8 +329,7 @@ static inline u32 eeh_inl(unsigned long port) | |||
337 | 329 | ||
338 | static inline void eeh_outl(u32 val, unsigned long port) | 330 | static inline void eeh_outl(u32 val, unsigned long port) |
339 | { | 331 | { |
340 | if (_IO_IS_VALID(port)) | 332 | out_le32((u32 __iomem *)(port+pci_io_base), val); |
341 | out_le32((u32 __iomem *)(port+pci_io_base), val); | ||
342 | } | 333 | } |
343 | 334 | ||
344 | /* in-string eeh macros */ | 335 | /* in-string eeh macros */ |