From 5349e255ff913971d8b812eb363da62eace169bc Mon Sep 17 00:00:00 2001 From: Anatolij Gustschin Date: Mon, 17 Feb 2020 12:36:43 +0100 Subject: 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: 52edfed65de9 ("dm: core: device: switch off power domain after device removal") Signed-off-by: Anatolij Gustschin Acked-by: Neil Armstrong Tested-by: Guillaume La Roque Reviewed-by: Simon Glass --- include/dm/device.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include') diff --git a/include/dm/device.h b/include/dm/device.h index ab806d0b7e9..a56164b19bb 100644 --- a/include/dm/device.h +++ b/include/dm/device.h @@ -67,6 +67,12 @@ struct driver_info; /* Driver platdata has been read. Cleared when the device is removed */ #define DM_FLAG_PLATDATA_VALID (1 << 12) +/* + * Device is removed without switching off its power domain. This might + * be required, i. e. for serial console (debug) output when booting OS. + */ +#define DM_FLAG_REMOVE_WITH_PD_ON (1 << 13) + /* * One or multiple of these flags are passed to device_remove() so that * a selective device removal as specified by the remove-stage and the -- cgit v1.2.3