[PATCH 4/6] usb: gadget: Drop dev_to_usb_gadget()

Mattijs Korpershoek mkorpershoek at baylibre.com
Thu Aug 29 09:43:07 CEST 2024


Hi Marek,

Thank you for the patch.

On lun., août 26, 2024 at 16:38, Marek Vasut <marek.vasut+renesas at mailbox.org> wrote:

> This function is unused, remove it.
>
> Signed-off-by: Marek Vasut <marek.vasut+renesas at mailbox.org>

Reviewed-by: Mattijs Korpershoek <mkorpershoek at baylibre.com>

> ---
> Cc: Linus Walleij <linus.walleij at linaro.org>
> Cc: Lukasz Majewski <lukma at denx.de>
> Cc: Mattijs Korpershoek <mkorpershoek at baylibre.com>
> Cc: Miquel Raynal <miquel.raynal at bootlin.com>
> Cc: Neil Armstrong <neil.armstrong at linaro.org>
> Cc: Nishanth Menon <nm at ti.com>
> Cc: Zixun LI <admin at hifiphile.com>
> ---
>  include/linux/usb/gadget.h | 5 -----
>  1 file changed, 5 deletions(-)
>
> diff --git a/include/linux/usb/gadget.h b/include/linux/usb/gadget.h
> index a2b8520bc99..194025ebd12 100644
> --- a/include/linux/usb/gadget.h
> +++ b/include/linux/usb/gadget.h
> @@ -558,11 +558,6 @@ static inline void *get_gadget_data(struct usb_gadget *gadget)
>  	return gadget->driver_data;
>  }
>  
> -static inline struct usb_gadget *dev_to_usb_gadget(struct device *dev)
> -{
> -	return container_of(dev, struct usb_gadget, dev);
> -}
> -
>  /* iterates the non-control endpoints; 'tmp' is a struct usb_ep pointer */
>  #define gadget_for_each_ep(tmp, gadget) \
>  	list_for_each_entry(tmp, &(gadget)->ep_list, ep_list)
> -- 
> 2.45.2


More information about the U-Boot mailing list