Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=4b402c65a3a17257af45875159395278e4a2f0cd
Commit:     4b402c65a3a17257af45875159395278e4a2f0cd
Parent:     b85b3b7af52d1c1bd45bfcd47aa425a15fda45f7
Author:     Michael Buesch <[EMAIL PROTECTED]>
AuthorDate: Wed Sep 19 18:53:44 2007 +0200
Committer:  David S. Miller <[EMAIL PROTECTED]>
CommitDate: Wed Oct 10 16:52:20 2007 -0700

    [SSB]: Use ioreadX() and iowriteX() for PCI.
    
    On a PCI bus use ioreadX() and iowriteX().
    We map the I/O space with pci_iomap(), so we must use the correct
    accessor functions, too.
    readX() and writeX() are not guaranteed to accept the cookie returned
    from pci_iomap() (though, it currently works on most architectures).
    
    Signed-off-by: Michael Buesch <[EMAIL PROTECTED]>
    Signed-off-by: John W. Linville <[EMAIL PROTECTED]>
    Signed-off-by: David S. Miller <[EMAIL PROTECTED]>
---
 drivers/ssb/pci.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/ssb/pci.c b/drivers/ssb/pci.c
index 3d23ca4..e19b9f9 100644
--- a/drivers/ssb/pci.c
+++ b/drivers/ssb/pci.c
@@ -531,7 +531,7 @@ static u16 ssb_pci_read16(struct ssb_device *dev, u16 
offset)
                if (unlikely(ssb_pci_switch_core(bus, dev)))
                        return 0xFFFF;
        }
-       return readw(bus->mmio + offset);
+       return ioread16(bus->mmio + offset);
 }
 
 static u32 ssb_pci_read32(struct ssb_device *dev, u16 offset)
@@ -544,7 +544,7 @@ static u32 ssb_pci_read32(struct ssb_device *dev, u16 
offset)
                if (unlikely(ssb_pci_switch_core(bus, dev)))
                        return 0xFFFFFFFF;
        }
-       return readl(bus->mmio + offset);
+       return ioread32(bus->mmio + offset);
 }
 
 static void ssb_pci_write16(struct ssb_device *dev, u16 offset, u16 value)
@@ -557,7 +557,7 @@ static void ssb_pci_write16(struct ssb_device *dev, u16 
offset, u16 value)
                if (unlikely(ssb_pci_switch_core(bus, dev)))
                        return;
        }
-       writew(value, bus->mmio + offset);
+       iowrite16(value, bus->mmio + offset);
 }
 
 static void ssb_pci_write32(struct ssb_device *dev, u16 offset, u32 value)
@@ -570,7 +570,7 @@ static void ssb_pci_write32(struct ssb_device *dev, u16 
offset, u32 value)
                if (unlikely(ssb_pci_switch_core(bus, dev)))
                        return;
        }
-       writel(value, bus->mmio + offset);
+       iowrite32(value, bus->mmio + offset);
 }
 
 /* Not "static", as it's used in main.c */
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to