Commit d35818a9 authored by Andy Shevchenko's avatar Andy Shevchenko Committed by Rafael J. Wysocki

PM / clk: don't leave clocks enabled when driver not bound

There is a new notification BUS_NOTIFY_DRIVER_NOT_BOUND that is issued when
driver fails during binding. In such case pm_clk_notify(), when PM_CLK=n,
leaves clocks enabled. Undo operations that have been done in
BUS_NOTIFY_BIND_DRIVER case.
Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent 04a407f6
...@@ -473,6 +473,7 @@ static int pm_clk_notify(struct notifier_block *nb, ...@@ -473,6 +473,7 @@ static int pm_clk_notify(struct notifier_block *nb,
enable_clock(dev, NULL); enable_clock(dev, NULL);
} }
break; break;
case BUS_NOTIFY_DRIVER_NOT_BOUND:
case BUS_NOTIFY_UNBOUND_DRIVER: case BUS_NOTIFY_UNBOUND_DRIVER:
if (clknb->con_ids[0]) { if (clknb->con_ids[0]) {
for (con_id = clknb->con_ids; *con_id; con_id++) for (con_id = clknb->con_ids; *con_id; con_id++)
......
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