Re: [PATCH] USB: serial: simple-serial: spell out the ordering

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

 



On Thu, Jul 20, 2023 at 02:42:49PM +0200, Oliver Neukum wrote:
> On 20.07.23 14:01, Johan Hovold wrote:
> > On Thu, Jul 20, 2023 at 01:44:06PM +0200, Oliver Neukum wrote:
> 
> >> + * These tables are NOT in order of device id by intention
> >> + *
> >> + * Keep them and add new entries sorted by
> >> + *
> >> + * 1. Alphabetical order of the vendor name
> >> + * 2. Alphabetical order of the product name
> >> + *
> >> + */
> > 
> > No, this is not correct. The tables are sorted alphabetically based on
> > the symbol names, but the entries in each table is sorted by VID/PID as
> > usual.
> 
> OK, I stand corrected. You do understand that this ordering is
> extremely peculiar? I am sorry, but deducing that from the example,
> which the current order is, will just not work. Nobody gets that
> without a clear and present explanation.

It's not peculiar. And if this wasn't implemented using macros, I'm
pretty sure you would not think so. Take a look at io_edgeport.c, for
example, where edgeport_2port_device comes before edgeport_4port_device,
etc.

> This just needs a comment in the text.

I disagree, with the last few entries sorted this should be clear
enough.

Johan



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

  Powered by Linux