aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/i2c
diff options
context:
space:
mode:
authorArjan van de Ven <arjan@infradead.org>2008-10-22 14:21:32 -0400
committerJean Delvare <khali@linux-fr.org>2008-10-22 14:21:32 -0400
commitc7a5f22d1f15a03d0bfed5b1795e3172b6309d86 (patch)
tree474ad173bc08b239623584b1ff9d4846a46e869a /drivers/i2c
parent00155a94a691c25d6672c16c8f2cafa7f9a722a3 (diff)
i2c: Use pci_ioremap_bar()
Use the newly introduced pci_ioremap_bar() function in drivers/i2c. pci_ioremap_bar() just takes a pci device and a bar number, with the goal of making it really hard to get wrong, while also having a central place to stick sanity checks. Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'drivers/i2c')
-rw-r--r--drivers/i2c/busses/i2c-hydra.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/busses/i2c-hydra.c b/drivers/i2c/busses/i2c-hydra.c
index 1098f21ace13..648aa7baff83 100644
--- a/drivers/i2c/busses/i2c-hydra.c
+++ b/drivers/i2c/busses/i2c-hydra.c
@@ -123,7 +123,7 @@ static int __devinit hydra_probe(struct pci_dev *dev,
123 hydra_adap.name)) 123 hydra_adap.name))
124 return -EBUSY; 124 return -EBUSY;
125 125
126 hydra_bit_data.data = ioremap(base, pci_resource_len(dev, 0)); 126 hydra_bit_data.data = pci_ioremap_bar(dev, 0);
127 if (hydra_bit_data.data == NULL) { 127 if (hydra_bit_data.data == NULL) {
128 release_mem_region(base+offsetof(struct Hydra, CachePD), 4); 128 release_mem_region(base+offsetof(struct Hydra, CachePD), 4);
129 return -ENODEV; 129 return -ENODEV;