mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-12-29 01:05:29 +00:00
mfd: twl4030-power: Accept standard property for power controller
Instead of only accepting the ti specific properties accept also the standard property. For uniformity, search in the parent node for the tag. The code for powering off is also isolated from the rest in this file. So it is a pure Linux design decision to put it here. Signed-off-by: Andreas Kemnade <andreas@kemnade.info> Link: https://lore.kernel.org/r/20240217082007.3238948-6-andreas@kemnade.info Signed-off-by: Lee Jones <lee@kernel.org>
This commit is contained in:
parent
ca9414a1d0
commit
8ba560ec14
@ -686,6 +686,9 @@ static bool twl4030_power_use_poweroff(const struct twl4030_power_data *pdata,
|
||||
if (of_property_read_bool(node, "ti,use_poweroff"))
|
||||
return true;
|
||||
|
||||
if (of_device_is_system_power_controller(node->parent))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user