public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Tom Rini <trini@konsulko.com>
To: Marek Vasut <marex@denx.de>
Cc: u-boot@lists.denx.de, Kevin Hilman <khilman@baylibre.com>,
	Lukasz Majewski <lukma@denx.de>,
	Miquel Raynal <miquel.raynal@bootlin.com>,
	Simon Glass <sjg@chromium.org>
Subject: Re: [PATCH v5 3/3] usb: gadget: ether: Handle gadget driver registration in probe and remove
Date: Fri, 4 Aug 2023 16:15:34 -0400	[thread overview]
Message-ID: <20230804201534.GF3630934@bill-the-cat> (raw)
In-Reply-To: <20230804154111.97042-3-marex@denx.de>

[-- Attachment #1: Type: text/plain, Size: 1066 bytes --]

On Fri, Aug 04, 2023 at 05:41:11PM +0200, Marek Vasut wrote:

> Move the ethernet gadget driver registration and removal from ethernet
> bind and unbind callbacks into driver DM probe and remove callbacks.
> This way, when the driver is bound, which is triggered deliberately
> using 'bind' command, the USB ethernet gadget driver is instantiated
> and bound to the matching UDC. In reverse, when the driver is unbound,
> which is again triggered deliberately using 'unbind' command, the USB
> ethernet gadget driver instance is removed.
> 
> Effectively, this now behaves like running either 'ums' or 'dfu' or
> any other commands utilizing USB gadget functionality.
> 
> This also drops use of usb_gadget_release() and moves the use of
> usb_gadget_initialize() into usb_ether_init() used only by legacy
> platforms that do not use 'bind' command properly yet. Those have
> no place in drivers.
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Tested-by: Tom Rini <trini@konsulko.com>

Reviewed-by: Tom Rini <trini@konsulko.com>

-- 
Tom

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]

  parent reply	other threads:[~2023-08-04 20:16 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-04 15:41 [PATCH v5 1/3] usb: gadget: ether: Inline functions used once Marek Vasut
2023-08-04 15:41 ` [PATCH v5 2/3] usb: gadget: ether: Move probe function above driver structure Marek Vasut
2023-08-04 16:06   ` Tom Rini
2023-08-04 19:45   ` Miquel Raynal
2023-08-04 19:45   ` Miquel Raynal
2023-08-04 20:15   ` Tom Rini
2023-08-04 15:41 ` [PATCH v5 3/3] usb: gadget: ether: Handle gadget driver registration in probe and remove Marek Vasut
2023-08-04 16:06   ` [PATCH] cmd: Enable BIND by default if we have USB_ETHER Tom Rini
2023-08-04 17:09     ` Miquel Raynal
2023-08-04 16:06   ` [PATCH v5 3/3] usb: gadget: ether: Handle gadget driver registration in probe and remove Tom Rini
2023-08-04 20:15   ` Tom Rini [this message]
2023-08-04 16:06 ` [PATCH v5 1/3] usb: gadget: ether: Inline functions used once Tom Rini
2023-08-04 19:44 ` Miquel Raynal
2023-08-04 20:15 ` Tom Rini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230804201534.GF3630934@bill-the-cat \
    --to=trini@konsulko.com \
    --cc=khilman@baylibre.com \
    --cc=lukma@denx.de \
    --cc=marex@denx.de \
    --cc=miquel.raynal@bootlin.com \
    --cc=sjg@chromium.org \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox