Re: [PATCH v2] usb: dwc3: imx8mp: make dwc3_imx_glue_ops static and rename to imx8mp
From: Thinh Nguyen
Date: Mon Jun 29 2026 - 20:39:23 EST
On Mon, Jun 29, 2026, Ben Dooks wrote:
> On 26/06/2026 23:32, Thinh Nguyen wrote:
> > On Tue, Jun 23, 2026, Ben Dooks wrote:
> > > The dwc3_imx_glue_ops is not used outside this file, and technically this
> > > is the dwc3-imx8mp driver so whilst making this static to avoid the
> > > following warning, rename it dwc3_imx8mp_glue_ops to distinguish it from
> > > the other driver which also has dwc3_imx_glue_ops.
> > >
> > > Fixes:
> > > drivers/usb/dwc3/dwc3-imx8mp.c:176:22: warning: symbol 'dwc3_imx_glue_ops' was not declared. Should it be static?
> > >
> > > Signed-off-by: Ben Dooks <ben.dooks@xxxxxxxxxxxxxxx>
> > > ---
> > > drivers/usb/dwc3/dwc3-imx8mp.c | 8 ++++----
> > > 1 file changed, 4 insertions(+), 4 deletions(-)
> > >
> > > diff --git a/drivers/usb/dwc3/dwc3-imx8mp.c b/drivers/usb/dwc3/dwc3-imx8mp.c
> > > index 1cf96540b66e..de8c17bc940d 100644
> > > --- a/drivers/usb/dwc3/dwc3-imx8mp.c
> > > +++ b/drivers/usb/dwc3/dwc3-imx8mp.c
> > > @@ -158,7 +158,7 @@ static irqreturn_t dwc3_imx8mp_interrupt(int irq, void *_dwc3_imx)
> > > return IRQ_HANDLED;
> > > }
> > > -static void dwc3_imx_pre_set_role(struct dwc3 *dwc, enum usb_role role)
> > > +static void dwc3_imx8mp_pre_set_role(struct dwc3 *dwc, enum usb_role role)
> > > {
> > > if (role == USB_ROLE_HOST)
> > > /*
> > > @@ -173,8 +173,8 @@ static void dwc3_imx_pre_set_role(struct dwc3 *dwc, enum usb_role role)
> > > pm_runtime_use_autosuspend(dwc->dev);
> > > }
> > > -struct dwc3_glue_ops dwc3_imx_glue_ops = {
> > > - .pre_set_role = dwc3_imx_pre_set_role,
> > > +static struct dwc3_glue_ops dwc3_imx8mp_glue_ops = {
> > > + .pre_set_role = dwc3_imx8mp_pre_set_role,
> > > };
> > > static int dwc3_imx8mp_probe(struct platform_device *pdev)
> > > @@ -266,7 +266,7 @@ static int dwc3_imx8mp_probe(struct platform_device *pdev)
> > > goto put_dwc3;
> > > }
> > > - dwc3->glue_ops = &dwc3_imx_glue_ops;
> > > + dwc3->glue_ops = &dwc3_imx8mp_glue_ops;
> > > if (dwc3->dr_mode == USB_DR_MODE_HOST)
> > > pm_runtime_dont_use_autosuspend(dwc3->dev);
> > > --
> > > 2.37.2.352.g3c44437643
> > >
> >
> > Please add Fixes and Cc stable tags and backport this change also.
>
> Hi, I thought fixes was only for bugs not warnings and stable is
> only for serious bugs?
>
>
Does it trigger -Werror build failure? If so, it should go in stable.
Thanks,
Thinh