forked from Minki/linux
spi: spi_mpc8xxx.c: use resource_size()
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: David Brownell <dbrownell@users.sourceforge.net> Cc: Kumar Gala <galak@kernel.crashing.org> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
This commit is contained in:
parent
74947b8982
commit
82de76513e
@ -566,7 +566,7 @@ mpc8xxx_spi_probe(struct device *dev, struct resource *mem, unsigned int irq)
|
||||
|
||||
init_completion(&mpc8xxx_spi->done);
|
||||
|
||||
mpc8xxx_spi->base = ioremap(mem->start, mem->end - mem->start + 1);
|
||||
mpc8xxx_spi->base = ioremap(mem->start, resource_size(mem));
|
||||
if (mpc8xxx_spi->base == NULL) {
|
||||
ret = -ENOMEM;
|
||||
goto put_master;
|
||||
|
Loading…
Reference in New Issue
Block a user