mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
serial: bfin_5xx: fix off-by-one with resource size
This doesn't cause any real bugs, but it should still be fixed. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
5a3c6b251d
commit
7c365bac44
1 changed files with 1 additions and 2 deletions
|
@ -1304,8 +1304,7 @@ static int bfin_serial_probe(struct platform_device *pdev)
|
|||
goto out_error_free_peripherals;
|
||||
}
|
||||
|
||||
uart->port.membase = ioremap(res->start,
|
||||
res->end - res->start);
|
||||
uart->port.membase = ioremap(res->start, resource_size(res));
|
||||
if (!uart->port.membase) {
|
||||
dev_err(&pdev->dev, "Cannot map uart IO\n");
|
||||
ret = -ENXIO;
|
||||
|
|
Loading…
Reference in a new issue