On 12/9/20 12:15 PM, Souptick Joarder wrote:
> Kernel test robot throws below warning ->
> 
> In file included from drivers/usb/cdns3/core.c:23:
>>> drivers/usb/cdns3/host-export.h:27:51: warning: 'struct usb_hcd'
>>> declared inside parameter list will not be visible outside of this
>>> definition or declaration
>       27 | static inline int xhci_cdns3_suspend_quirk(struct usb_hcd
> *hcd)
>          |                                                   ^~~~~~~
> 
> This patch will silence it.

Really?  Didn't silence it for me when I tested this patch.

Also, please see

https://lore.kernel.org/linux-usb/dbbpr04mb7979502194410bb1ae96df038b...@dbbpr04mb7979.eurprd04.prod.outlook.com/T/#m7f73fdd57c0f1577fb610dcaf28646b53fa7dc26

(what a strange URL)

I now get these 2 warnings:

In file included from ../drivers/usb/cdns3/core.c:23:0:
../drivers/usb/cdns3/host-export.h:27:44: warning: ‘struct usb_hcd’ declared 
inside parameter list will not be visible outside of this definition or 
declaration
 static int xhci_cdns3_suspend_quirk(struct usb_hcd *hcd)
                                            ^~~~~~~
  CC [M]  drivers/usb/gadget/function/uvc_queue.o
../drivers/usb/cdns3/host-export.h:27:12: warning: ‘xhci_cdns3_suspend_quirk’ 
defined but not used [-Wunused-function]
 static int xhci_cdns3_suspend_quirk(struct usb_hcd *hcd)
            ^~~~~~~~~~~~~~~~~~~~~~~~


> Reported-by: kernel test robot <[email protected]>
> Signed-off-by: Souptick Joarder <[email protected]>
> ---
>  drivers/usb/cdns3/host-export.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/usb/cdns3/host-export.h b/drivers/usb/cdns3/host-export.h
> index fb8541b..c1259af 100644
> --- a/drivers/usb/cdns3/host-export.h
> +++ b/drivers/usb/cdns3/host-export.h
> @@ -24,7 +24,7 @@ static inline int cdns_host_init(struct cdns *cdns)
>  }
>  
>  static inline void cdns_host_exit(struct cdns *cdns) { }
> -static inline int xhci_cdns3_suspend_quirk(struct usb_hcd *hcd)
> +static int xhci_cdns3_suspend_quirk(struct usb_hcd *hcd)
>  {
>       return 0;
>  }
> 


-- 
~Randy
Reported-by: Randy Dunlap <[email protected]>

Reply via email to