PM / OPP: Reorganize _generic_set_opp_regulator()
authorViresh Kumar <viresh.kumar@linaro.org>
Tue, 23 May 2017 04:02:10 +0000 (09:32 +0530)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 22 Jun 2017 01:15:29 +0000 (03:15 +0200)
commitc74b32fadc00f2412d86a19295eb867b1a772948
treee9eca6b6a1e54604931c3e4f7a4ca83d3c9ec5cc
parent41f1830f5a7af77cf5c86359aba3cbd706687e52
PM / OPP: Reorganize _generic_set_opp_regulator()

The code was overly complicated here because of the limitations that we
had with RCUs (Couldn't use opp-table and OPPs outside RCU protected
section and can't call sleep-able routines from within that). But that
is long gone now.

Reorganize _generic_set_opp_regulator() in order to avoid using "struct
dev_pm_set_opp_data" and copying data into it for the case where
opp_table->set_opp is not set.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Reviewed-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/base/power/opp/core.c