[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aDeCwUsYTh7z7uuo@lizhi-Precision-Tower-5810>
Date: Wed, 28 May 2025 17:40:17 -0400
From: Frank Li <Frank.li@....com>
To: Dan Carpenter <dan.carpenter@...aro.org>
Cc: Peter Chen <peter.chen@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Shawn Guo <shawnguo@...nel.org>,
Sascha Hauer <s.hauer@...gutronix.de>,
Pengutronix Kernel Team <kernel@...gutronix.de>,
Fabio Estevam <festevam@...il.com>, linux-usb@...r.kernel.org,
imx@...ts.linux.dev, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org,
Ghennadi Procopciuc <ghennadi.procopciuc@....com>, s32@....com,
linaro-s32@...aro.org
Subject: Re: [PATCH 4/4] usb: chipidea: s32g: Add usb support for s32g3
On Wed, May 28, 2025 at 10:57:39PM +0300, Dan Carpenter wrote:
> From: Ghennadi Procopciuc <ghennadi.procopciuc@....com>
>
> Enable USB driver for the s32g3 USB device.
>
> Signed-off-by: Ghennadi Procopciuc <ghennadi.procopciuc@....com>
> Signed-off-by: Dan Carpenter <dan.carpenter@...aro.org>
> ---
> drivers/usb/chipidea/ci_hdrc_imx.c | 1 +
> drivers/usb/chipidea/usbmisc_imx.c | 15 +++++++++++++++
> 2 files changed, 16 insertions(+)
>
> diff --git a/drivers/usb/chipidea/ci_hdrc_imx.c b/drivers/usb/chipidea/ci_hdrc_imx.c
> index ce207f8566d5..d062399ce15e 100644
> --- a/drivers/usb/chipidea/ci_hdrc_imx.c
> +++ b/drivers/usb/chipidea/ci_hdrc_imx.c
> @@ -95,6 +95,7 @@ static const struct of_device_id ci_hdrc_imx_dt_ids[] = {
> { .compatible = "fsl,imx7ulp-usb", .data = &imx7ulp_usb_data},
> { .compatible = "fsl,imx8ulp-usb", .data = &imx8ulp_usb_data},
> { .compatible = "nxp,s32g2-usb", .data = &s32g_usb_data},
> + { .compatible = "nxp,s32g3-usb", .data = &s32g_usb_data},
If it is same, suggest compatible string fallback to nxp,s32g2-usb
compatible = "nxp,s32g3-usb", "nxp,s32g2-usb".
Frank
> { /* sentinel */ }
> };
> MODULE_DEVICE_TABLE(of, ci_hdrc_imx_dt_ids);
> diff --git a/drivers/usb/chipidea/usbmisc_imx.c b/drivers/usb/chipidea/usbmisc_imx.c
> index 43098a150e83..34fd26faa303 100644
> --- a/drivers/usb/chipidea/usbmisc_imx.c
> +++ b/drivers/usb/chipidea/usbmisc_imx.c
> @@ -677,6 +677,11 @@ static int usbmisc_s32g2_init(struct imx_usbmisc_data *data)
> return usbmisc_s32g_init(data, S32G_UCMALLBE);
> }
>
> +static int usbmisc_s32g3_init(struct imx_usbmisc_data *data)
> +{
> + return usbmisc_s32g_init(data, 0);
> +}
> +
> static int usbmisc_imx7d_set_wakeup
> (struct imx_usbmisc_data *data, bool enabled)
> {
> @@ -1200,6 +1205,12 @@ static const struct usbmisc_ops s32g2_usbmisc_ops = {
> .flags = REINIT_DURING_RESUME,
> };
>
> +static const struct usbmisc_ops s32g3_usbmisc_ops = {
> + .init = usbmisc_s32g3_init,
> + .set_wakeup = usbmisc_s32g_set_wakeup,
> + .flags = REINIT_DURING_RESUME,
> +};
> +
> static inline bool is_imx53_usbmisc(struct imx_usbmisc_data *data)
> {
> struct imx_usbmisc *usbmisc = dev_get_drvdata(data->dev);
> @@ -1432,6 +1443,10 @@ static const struct of_device_id usbmisc_imx_dt_ids[] = {
> .compatible = "nxp,s32g2-usbmisc",
> .data = &s32g2_usbmisc_ops,
> },
> + {
> + .compatible = "nxp,s32g3-usbmisc",
> + .data = &s32g3_usbmisc_ops,
> + },
> { /* sentinel */ }
> };
> MODULE_DEVICE_TABLE(of, usbmisc_imx_dt_ids);
> --
> 2.47.2
>
Powered by blists - more mailing lists