linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/2] USB: DTS: allow suggesting busnumber for platform USB bus via DTS alias
@ 2018-11-27 16:57 David R. Piegdon
  2018-12-11 22:42 ` Rob Herring
  0 siblings, 1 reply; 2+ messages in thread
From: David R. Piegdon @ 2018-11-27 16:57 UTC (permalink / raw)
  To: Gustavo A. R. Silva, Alan Stern, Chunfeng Yun,
	Greg Kroah-Hartman, Johan Hovold, Kay Sievers, Mark Rutland,
	Martin Blumenstingl, Mathias Nyman, Rob Herring, Roger Quadros,
	Sebastian Andrzej Siewior, devicetree, linux-kernel, linux-usb,
	systemd-devel

Hi,

on our embedded systems we rely on systemd's persistent netdev names.
Those currently do not work for USB netdevs that are connected to a
platform USB bus.

In https://github.com/systemd/systemd/pull/7273 a systemd patch was
suggested that would allow exactly this, but it was (rightfully) said
that numbering of theses busses is not guaranteed. Internally we used
the patch for a while now, but exactly that has happened with one of our
platforms across different kernel revisions.

The following kernel patches allow suggesting a USB busnumber for each
USB platform bus via a DTS alias, as can be done similarly for many
other devices.
In combination with above systemd patch, these changes allow use of
persistent netdev names also on platform USB busses.

NOTE: this patch might change ordering of busses on devices that use
platform-busses, if aliases for these busses have already been defined!
In the current master there are a few platforms that contain such
aliases, e.g. am33xx, dm814x or imx6qdl

Yours,

David

David R. Piegdon (2):
  usb core: dts: allow suggesting usb bus number for platform busses
  dt-bindings: allow suggesting usb bus number for usb platform busses

 Documentation/devicetree/bindings/usb/usb-hcd.txt |  9 +++++++
 drivers/usb/core/hcd.c                            | 30 ++++++++++++++++++-----
 2 files changed, 33 insertions(+), 6 deletions(-)

-- 
2.11.0

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [RFC PATCH 0/2] USB: DTS: allow suggesting busnumber for platform USB bus via DTS alias
  2018-11-27 16:57 [RFC PATCH 0/2] USB: DTS: allow suggesting busnumber for platform USB bus via DTS alias David R. Piegdon
@ 2018-12-11 22:42 ` Rob Herring
  0 siblings, 0 replies; 2+ messages in thread
From: Rob Herring @ 2018-12-11 22:42 UTC (permalink / raw)
  To: David R. Piegdon
  Cc: Gustavo A. R. Silva, Alan Stern, Chunfeng Yun,
	Greg Kroah-Hartman, Johan Hovold, Kay Sievers, Mark Rutland,
	Martin Blumenstingl, Mathias Nyman, Roger Quadros,
	Sebastian Andrzej Siewior, devicetree, linux-kernel, linux-usb,
	systemd-devel

On Tue, Nov 27, 2018 at 04:57:05PM +0000, David R. Piegdon wrote:
> Hi,
> 
> on our embedded systems we rely on systemd's persistent netdev names.
> Those currently do not work for USB netdevs that are connected to a
> platform USB bus.
> 
> In https://github.com/systemd/systemd/pull/7273 a systemd patch was
> suggested that would allow exactly this, but it was (rightfully) said
> that numbering of theses busses is not guaranteed. Internally we used
> the patch for a while now, but exactly that has happened with one of our
> platforms across different kernel revisions.
> 
> The following kernel patches allow suggesting a USB busnumber for each
> USB platform bus via a DTS alias, as can be done similarly for many
> other devices.
> In combination with above systemd patch, these changes allow use of
> persistent netdev names also on platform USB busses.

I don't think this is doing what was suggested in the link above. Though 
I'm not familiar with what ACPI provides. Userspace would still be 
relying on the Linux enumeration numbering. How would userspace tell if 
that numbering is persistent or not other than looking at the DT itself 
(which isn't a good solution either)?

I don't understand though why userspace needs anything more that the mac 
address of a net device to provide a persistent name.

Rob

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-12-11 22:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-27 16:57 [RFC PATCH 0/2] USB: DTS: allow suggesting busnumber for platform USB bus via DTS alias David R. Piegdon
2018-12-11 22:42 ` Rob Herring

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).