Commit fa379a7b authored by Laurent Pinchart's avatar Laurent Pinchart Committed by Luis Henriques

i2c: core: Dispose OF IRQ mapping at client removal time

commit e4df3a0b upstream.

Clients instantiated from OF get an IRQ mapping created at device
registration time. Dispose the mapping when the client is removed.
Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
[ luis: backported to 3.16: adjusted context ]
Signed-off-by: default avatarLuis Henriques <luis.henriques@canonical.com>
parent 0b19933d
......@@ -297,6 +297,9 @@ static int i2c_device_remove(struct device *dev)
status = driver->remove(client);
}
if (dev->of_node)
irq_dispose_mapping(client->irq);
acpi_dev_pm_detach(&client->dev, true);
return status;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment