mirror of
https://xff.cz/git/u-boot/
synced 2025-11-03 03:46:02 +01:00
dm: core: Add a flag for power domain control on device removal
In various cases a power domain must stay enabled after device
removal when booting OS (i.e. serial debug console or display).
Add a flag to selectively skip switching off a power domain.
Fixes: 52edfed65d ("dm: core: device: switch off power domain after device removal")
Signed-off-by: Anatolij Gustschin <agust@denx.de>
Acked-by: Neil Armstrong <narmstrong@baylibre.com>
Tested-by: Guillaume La Roque <glaroque@baylibre.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
committed by
Simon Glass
parent
8aad16916d
commit
5349e255ff
@@ -194,8 +194,9 @@ int device_remove(struct udevice *dev, uint flags)
|
||||
}
|
||||
}
|
||||
|
||||
if (!(drv->flags & DM_FLAG_DEFAULT_PD_CTRL_OFF) &&
|
||||
(dev != gd->cur_serial_dev))
|
||||
if (!(drv->flags &
|
||||
(DM_FLAG_DEFAULT_PD_CTRL_OFF | DM_FLAG_REMOVE_WITH_PD_ON)) &&
|
||||
dev != gd->cur_serial_dev)
|
||||
dev_power_domain_off(dev);
|
||||
|
||||
if (flags_remove(flags, drv->flags)) {
|
||||
|
||||
Reference in New Issue
Block a user