diff options
Diffstat (limited to 'drivers/spi')
-rw-r--r-- | drivers/spi/atmel_spi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/spi/atmel_spi.c b/drivers/spi/atmel_spi.c index 8ce70cbdbb96..d21c24eaf0a9 100644 --- a/drivers/spi/atmel_spi.c +++ b/drivers/spi/atmel_spi.c | |||
@@ -788,7 +788,7 @@ static int __init atmel_spi_probe(struct platform_device *pdev) | |||
788 | spin_lock_init(&as->lock); | 788 | spin_lock_init(&as->lock); |
789 | INIT_LIST_HEAD(&as->queue); | 789 | INIT_LIST_HEAD(&as->queue); |
790 | as->pdev = pdev; | 790 | as->pdev = pdev; |
791 | as->regs = ioremap(regs->start, (regs->end - regs->start) + 1); | 791 | as->regs = ioremap(regs->start, resource_size(regs)); |
792 | if (!as->regs) | 792 | if (!as->regs) |
793 | goto out_free_buffer; | 793 | goto out_free_buffer; |
794 | as->irq = irq; | 794 | as->irq = irq; |