Greetings,
This patch cleans up pci_ids.h, reducing size of the file from
104448 to 73438 bytes. Due to the scripted changes and the
requirement to maintain ordering within the file I had to reformat
whitespace.
Compile tested with 'make allmodconfig' with some stuff turned
off to get a compile completion. No missing PCI_* symbols.
Next step is to fix PCI_* defines distributed in the source, also
this file is meant to be included via 'pci.h' some files may need a
reference to pci_ids.h removed.
As attachment as patch is 92k.
Thanks,
Grant.
On Mon, Sep 19, 2005 at 09:22:36PM +1000, Grant Coady wrote:
> Greetings,
>
> This patch cleans up pci_ids.h, reducing size of the file from
> 104448 to 73438 bytes. Due to the scripted changes and the
> requirement to maintain ordering within the file I had to reformat
> whitespace.
>
> Compile tested with 'make allmodconfig' with some stuff turned
> off to get a compile completion. No missing PCI_* symbols.
>
> Next step is to fix PCI_* defines distributed in the source, also
> this file is meant to be included via 'pci.h' some files may need a
> reference to pci_ids.h removed.
>
> As attachment as patch is 92k.
I don't think you need the change to the comments at the top of the
file.
Also, I thought we wanted to keep all of the pci class ids, why did you
delete them? We should start by removing the pci device and vendor ids
that are not currently used by the kernel, and then slowly move those
ids into the individual drivers, starting with the device ids, and maybe
eventually moving to the vendor ids.
Sound ok?
thanks,
greg k-h
On Mon, 26 Sep 2005 14:35:57 -0700, Greg KH <[email protected]> wrote:
>I don't think you need the change to the comments at the top of the
>file.
Okay
>Also, I thought we wanted to keep all of the pci class ids, why did you
>delete them?
I'll give 'em back then ;)
> We should start by removing the pci device and vendor ids
>that are not currently used by the kernel, and then slowly move those
>ids into the individual drivers, starting with the device ids, and maybe
>eventually moving to the vendor ids.
>
>Sound ok?
Yep, I'll go find that script, bash it some more... I'll leave the
whitespace cleanup to last, since we gonna delete most of pci_ids.h?
Thanks,
Grant.
On Tue, Sep 27, 2005 at 06:32:12PM +1000, Grant Coady wrote:
> On Mon, 26 Sep 2005 14:35:57 -0700, Greg KH <[email protected]> wrote:
> > We should start by removing the pci device and vendor ids
> >that are not currently used by the kernel, and then slowly move those
> >ids into the individual drivers, starting with the device ids, and maybe
> >eventually moving to the vendor ids.
> >
> >Sound ok?
>
> Yep, I'll go find that script, bash it some more... I'll leave the
> whitespace cleanup to last, since we gonna delete most of pci_ids.h?
Yes, that is the goal.
thanks,
greg k-h
Greg KH wrote:
> I don't think you need the change to the comments at the top of the
> file.
agreed.
> Also, I thought we wanted to keep all of the pci class ids, why did you
> delete them? We should start by removing the pci device and vendor ids
> that are not currently used by the kernel, and then slowly move those
> ids into the individual drivers, starting with the device ids, and maybe
> eventually moving to the vendor ids.
The vendor ids are OBVIOUSLY common constants. The proper place is
where they live now: pci_ids.h.
I see little value in moving referenced device ids into individual
drivers, as they will make them harder to grep for, as time passes.
Jeff
On Tue, 27 Sep 2005 17:23:08 -0400, Jeff Garzik <[email protected]> wrote:
>Greg KH wrote:
[...]
>> We should start by removing the pci device and vendor ids
>> that are not currently used by the kernel, and then slowly move those
>> ids into the individual drivers, starting with the device ids, and maybe
>> eventually moving to the vendor ids.
>
>The vendor ids are OBVIOUSLY common constants. The proper place is
>where they live now: pci_ids.h.
>
>I see little value in moving referenced device ids into individual
>drivers, as they will make them harder to grep for, as time passes.
Hi Jeff,
Couple weeks ago you wrote:
>Long term, we should be able to trim a lot of device ids, since they are
>usually only used in one place.
What did you mean here? Trim from where?
Currently I have about 2011 symbols in the source, and 2040 in pci_ids.h,
with about 15 duplicates (likely the macro #define ones).
The situation is like the donkey between the hay bales.
Which way?
In meantime I'll continue to document current practice here:
http://bugsplatter.mine.nu/kernel/pci_ids/
Thanks,
Grant.