lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aNNAtlP768mMPPVC@nchen-desktop>
Date: Wed, 24 Sep 2025 08:52:06 +0800
From: "Peter Chen (CIX)" <peter.chen@...nel.org>
To: Peng Fan <peng.fan@....com>
Cc: "Rafael J. Wysocki" <rafael@...nel.org>,
	Pavel Machek <pavel@...nel.org>, Len Brown <lenb@...nel.org>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Danilo Krummrich <dakr@...nel.org>,
	Ulf Hansson <ulf.hansson@...aro.org>,
	Shawn Guo <shawnguo@...nel.org>,
	Sascha Hauer <s.hauer@...gutronix.de>,
	Pengutronix Kernel Team <kernel@...gutronix.de>,
	Fabio Estevam <festevam@...il.com>,
	Thinh Nguyen <Thinh.Nguyen@...opsys.com>, linux-pm@...r.kernel.org,
	linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org,
	imx@...ts.linux.dev, linux-arm-kernel@...ts.infradead.org,
	Xu Yang <xu.yang_2@....com>
Subject: Re: [PATCH v4 4/5] usb: chipidea: ci_hdrc_imx: Set out of band
 wakeup for i.MX95

On 25-09-22 10:21:09, Peng Fan wrote:
> i.MX95 USB2 inside HSIOMIX could still wakeup Linux, even if HSIOMIX
> power domain(Digital logic) is off. There is still always on logic
> have the wakeup capability which is out band wakeup capbility.
> 
> So use device_set_out_band_wakeup for i.MX95 to make sure usb2 could
> wakeup system even if HSIOMIX power domain is in off state.
> 
> Tested-by: Xu Yang <xu.yang_2@....com>
> Reviewed-by: Xu Yang <xu.yang_2@....com>
> Signed-off-by: Peng Fan <peng.fan@....com>

Acked-by: Peter Chen <peter.chen@...nel.org> 

Feel free add my ack if power part has accepted.

Peter
> ---
>  drivers/usb/chipidea/ci_hdrc_imx.c | 11 ++++++++++-
>  include/linux/usb/chipidea.h       |  1 +
>  2 files changed, 11 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/usb/chipidea/ci_hdrc_imx.c b/drivers/usb/chipidea/ci_hdrc_imx.c
> index d7c2a1a3c2715967203b98c819fa864e06a00a32..d4ee9e16332fe8b506711e4739c9008f73a377bf 100644
> --- a/drivers/usb/chipidea/ci_hdrc_imx.c
> +++ b/drivers/usb/chipidea/ci_hdrc_imx.c
> @@ -79,6 +79,10 @@ static const struct ci_hdrc_imx_platform_flag imx8ulp_usb_data = {
>  		CI_HDRC_HAS_PORTSC_PEC_MISSED,
>  };
>  
> +static const struct ci_hdrc_imx_platform_flag imx95_usb_data = {
> +	.flags = CI_HDRC_SUPPORTS_RUNTIME_PM | CI_HDRC_OUT_BAND_WAKEUP,
> +};
> +
>  static const struct ci_hdrc_imx_platform_flag s32g_usb_data = {
>  	.flags = CI_HDRC_DISABLE_HOST_STREAMING,
>  };
> @@ -94,6 +98,7 @@ static const struct of_device_id ci_hdrc_imx_dt_ids[] = {
>  	{ .compatible = "fsl,imx7d-usb", .data = &imx7d_usb_data},
>  	{ .compatible = "fsl,imx7ulp-usb", .data = &imx7ulp_usb_data},
>  	{ .compatible = "fsl,imx8ulp-usb", .data = &imx8ulp_usb_data},
> +	{ .compatible = "fsl,imx95-usb", .data = &imx95_usb_data},
>  	{ .compatible = "nxp,s32g2-usb", .data = &s32g_usb_data},
>  	{ /* sentinel */ }
>  };
> @@ -704,9 +709,13 @@ static int ci_hdrc_imx_suspend(struct device *dev)
>  
>  	pinctrl_pm_select_sleep_state(dev);
>  
> -	if (data->wakeup_irq > 0 && device_may_wakeup(dev))
> +	if (data->wakeup_irq > 0 && device_may_wakeup(dev)) {
>  		enable_irq_wake(data->wakeup_irq);
>  
> +		if (data->plat_data->flags & CI_HDRC_OUT_BAND_WAKEUP)
> +			device_set_out_band_wakeup(dev);
> +	}
> +
>  	return ret;
>  }
>  
> diff --git a/include/linux/usb/chipidea.h b/include/linux/usb/chipidea.h
> index e17ebeee24e3ecc4b1c2d153d9ea9b656b5a3d35..c6451191d2de68607a9380482701d11f949d0ff7 100644
> --- a/include/linux/usb/chipidea.h
> +++ b/include/linux/usb/chipidea.h
> @@ -66,6 +66,7 @@ struct ci_hdrc_platform_data {
>  #define CI_HDRC_HAS_PORTSC_PEC_MISSED	BIT(17)
>  #define CI_HDRC_FORCE_VBUS_ACTIVE_ALWAYS	BIT(18)
>  #define	CI_HDRC_HAS_SHORT_PKT_LIMIT	BIT(19)
> +#define	CI_HDRC_OUT_BAND_WAKEUP		BIT(20)
>  	enum usb_dr_mode	dr_mode;
>  #define CI_HDRC_CONTROLLER_RESET_EVENT		0
>  #define CI_HDRC_CONTROLLER_STOPPED_EVENT	1
> 
> -- 
> 2.37.1
> 

-- 

Best regards,
Peter

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ