Răsfoiți Sursa

mmc: atmel-mci.c: use resource_size()

[cjb: rebased patch against Linus]
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: <linux-mmc@vger.kernel.org>
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Chris Ball <cjb@laptop.org>
H Hartley Sweeten 15 ani în urmă
părinte
comite
e8e3f6ca12
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      drivers/mmc/host/atmel-mci.c

+ 1 - 1
drivers/mmc/host/atmel-mci.c

@@ -1777,7 +1777,7 @@ static int __init atmci_probe(struct platform_device *pdev)
 	}
 
 	ret = -ENOMEM;
-	host->regs = ioremap(regs->start, regs->end - regs->start + 1);
+	host->regs = ioremap(regs->start, resource_size(regs));
 	if (!host->regs)
 		goto err_ioremap;