aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ohci-tmio.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/host/ohci-tmio.c')
-rw-r--r--drivers/usb/host/ohci-tmio.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/usb/host/ohci-tmio.c b/drivers/usb/host/ohci-tmio.c
index 3558491dd87d..57ad1271fc9b 100644
--- a/drivers/usb/host/ohci-tmio.c
+++ b/drivers/usb/host/ohci-tmio.c
@@ -208,13 +208,13 @@ static int __devinit ohci_hcd_tmio_drv_probe(struct platform_device *dev)
208 } 208 }
209 209
210 hcd->rsrc_start = regs->start; 210 hcd->rsrc_start = regs->start;
211 hcd->rsrc_len = regs->end - regs->start + 1; 211 hcd->rsrc_len = resource_size(regs);
212 212
213 tmio = hcd_to_tmio(hcd); 213 tmio = hcd_to_tmio(hcd);
214 214
215 spin_lock_init(&tmio->lock); 215 spin_lock_init(&tmio->lock);
216 216
217 tmio->ccr = ioremap(config->start, config->end - config->start + 1); 217 tmio->ccr = ioremap(config->start, resource_size(config));
218 if (!tmio->ccr) { 218 if (!tmio->ccr) {
219 ret = -ENOMEM; 219 ret = -ENOMEM;
220 goto err_ioremap_ccr; 220 goto err_ioremap_ccr;
@@ -228,7 +228,7 @@ static int __devinit ohci_hcd_tmio_drv_probe(struct platform_device *dev)
228 228
229 if (!dma_declare_coherent_memory(&dev->dev, sram->start, 229 if (!dma_declare_coherent_memory(&dev->dev, sram->start,
230 sram->start, 230 sram->start,
231 sram->end - sram->start + 1, 231 resource_size(sram),
232 DMA_MEMORY_MAP | DMA_MEMORY_EXCLUSIVE)) { 232 DMA_MEMORY_MAP | DMA_MEMORY_EXCLUSIVE)) {
233 ret = -EBUSY; 233 ret = -EBUSY;
234 goto err_dma_declare; 234 goto err_dma_declare;