Re: [PATCH 001/001] usbserial: New mobile broadband modems to be supported through option module

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Saturday 07 February 2009 00:47:16 schrieb Greg KH:

> > The specifity is not affected at all.
> 
> If you look at the names that were changed, they are now more
> descriptive than before, always a good thing to have.

They are not descriptive. As far as USB devices have names,
these names _are_ the numbers. You will be very hard pressed
to guess from a name on a box that you may or may not have
which OEM's hardware really is in that box. If you have IDs
everything is clear. People who look at this code will mostly
have bug reports which will hopefully include lsusb, but not the
symbolic name in the kernel.

We dont do
*(base + 8) = 0xb3;
here. That would be bad. We use a clearly defined macro, USB_DEVICE
which takes id _numbers_. Device IDs have no meaning. They are meant
to be unique. You can give sensible names only to things that have meaning.

This is like doing
u8 init_string1[] = { INIT_STRING1_BYTE0, INIT_STRING1_BYTE1, ...

Don't make a fetish out of symbolic names.

	Regards
		Oliver

PS: Yes, I've had a professor who did prefer it this way.

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux