mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
PM / Domain: remove conditional from error case
There is no point running the conditional 'if' statement if the genpd isn't present. Signed-off-by: Viresh Kumar <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
This commit is contained in:
parent
c02ed2e75e
commit
8ce95844c8
1 changed files with 5 additions and 5 deletions
|
|
@ -1700,12 +1700,12 @@ int of_genpd_add_provider_simple(struct device_node *np,
|
|||
|
||||
mutex_lock(&gpd_list_lock);
|
||||
|
||||
if (pm_genpd_present(genpd))
|
||||
if (pm_genpd_present(genpd)) {
|
||||
ret = genpd_add_provider(np, genpd_xlate_simple, genpd);
|
||||
|
||||
if (!ret) {
|
||||
genpd->provider = &np->fwnode;
|
||||
genpd->has_provider = true;
|
||||
if (!ret) {
|
||||
genpd->provider = &np->fwnode;
|
||||
genpd->has_provider = true;
|
||||
}
|
||||
}
|
||||
|
||||
mutex_unlock(&gpd_list_lock);
|
||||
|
|
|
|||
Loading…
Reference in a new issue