firmware: imx: scu-pd: do not power off console if no_console_suspend
Do not power off console if no_console_suspend Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>5.4-rM2-2.2.x-imx-squashed
parent
819cd1e261
commit
c2e74728f9
|
@ -45,6 +45,7 @@
|
|||
*/
|
||||
|
||||
#include <dt-bindings/firmware/imx/rsrc.h>
|
||||
#include <linux/console.h>
|
||||
#include <linux/firmware/imx/sci.h>
|
||||
#include <linux/io.h>
|
||||
#include <linux/module.h>
|
||||
|
@ -241,6 +242,10 @@ static int imx_sc_pd_power(struct generic_pm_domain *domain, bool power_on)
|
|||
msg.resource = pd->rsrc;
|
||||
msg.mode = power_on ? IMX_SC_PM_PW_MODE_ON : IMX_SC_PM_PW_MODE_LP;
|
||||
|
||||
/* keep uart console power on for no_console_suspend */
|
||||
if (imx_con_rsrc == pd->rsrc && !console_suspend_enabled && !power_on)
|
||||
return 0;
|
||||
|
||||
ret = imx_scu_call_rpc(pm_ipc_handle, &msg, true);
|
||||
if (ret)
|
||||
dev_err(&domain->dev, "failed to power %s resource %d ret %d\n",
|
||||
|
|
Loading…
Reference in New Issue