Bill Nottingham wrote:
For any device X-Y in /sys/bus/usb/devices, it appears
X-Y:Z/name gives either "Hub", or "usb_make_path() interface Z".

Or whatever that interface's iInterface string provides, or that interface's driver puts there. Those are purely descriptive strings, ideally meant to be read by users, and they're not to be interpreted by programs.

Great, random strings are always useful. I thought the idea of sysfs was for a uniform interface, because /proc was full of random nonstandard crap.

Erm, the "name" is not provided for program consumption but for **USERS** to have something that makes some sense.

No guarantee of uniqueness, it's just supposed to be more
or less descriptive.  See what PCI devices put there; it's
some numbers, or the kernel PCI name database entry, if
that option happens to be compiled in.

There's nothing "random" about the contents.  If the system
actually knows some string describing that interface, it's
used ... what more would a user want?  OK, a guarantee
that it's in their own language; USB provides some support,
but sysfs doesn't.

And yes, I raised the point to Pat Mochel ages ago that
by using that definition, he was causing problems:  folk
usually expect a "name" to have _much_ stronger semantics.
There are words (like "label" or "description") that don't
cause that particular confusion.

In fact "name" is such a confusing word, once you get down
to it, that it's a good word to avoid using without at
least one adjective, to say which sort of "name" is meant.
That part of driverfs is now essentially unfixable.

- Dave





-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to