summaryrefslogtreecommitdiffstats
path: root/drivers/acpi
diff options
context:
space:
mode:
authorHeikki Krogerus <heikki.krogerus@linux.intel.com>2015-01-08 09:57:25 +0200
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2015-01-22 01:20:02 +0100
commit4483d59e29fea65ef428be92a866aed50e28c795 (patch)
tree5392616f2514f0b53b64dadb8cfa187da21d12e1 /drivers/acpi
parentec6f34e5b552fb0a52e6aae1a5afbbb1605cc6cc (diff)
downloadlinux-stable-4483d59e29fea65ef428be92a866aed50e28c795.tar.gz
linux-stable-4483d59e29fea65ef428be92a866aed50e28c795.tar.bz2
linux-stable-4483d59e29fea65ef428be92a866aed50e28c795.zip
ACPI / LPSS: check the result of ioremap()
If it fails we have to skip the device. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r--drivers/acpi/acpi_lpss.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/acpi/acpi_lpss.c b/drivers/acpi/acpi_lpss.c
index 4f3febf8a589..d12f98abf836 100644
--- a/drivers/acpi/acpi_lpss.c
+++ b/drivers/acpi/acpi_lpss.c
@@ -340,6 +340,8 @@ static int acpi_lpss_create_device(struct acpi_device *adev,
pdata->mmio_size = resource_size(&rentry->res);
pdata->mmio_base = ioremap(rentry->res.start,
pdata->mmio_size);
+ if (!pdata->mmio_base)
+ goto err_out;
break;
}