Subject: Re: sys/dev/pci/pucdata.c
To: None <joda@pdc.kth.se>
From: None <cgd@broadcom.com>
List: tech-kern
Date: 07/23/2002 10:14:10
At Tue, 23 Jul 2002 16:59:35 +0000 (UTC), joda@pdc.kth.se wrote:
> itojun@iijlab.net writes:
> > 	why vendor/product code are hardcoded, instead of pcidevs.h?
> 
> I suppose the reason is that some of the entries are either masks, or
> sub vendor/product ids, and so not in pcidevs. But I see no reason to
> not use mnemonics when available.

Well, in fact, _half_ of the entries are masks.  8-)

There are a couple of other things:

* it would have made the table formatting ... much uglier.

* if you actually use vendor/product codes from pcidevs, then it's
  possible that an accidental change to pcidevs will break puc.
  Unlikely, but a little bit of a concern.  (much more of a concern
  than for most other drivers, because of the number of IDs in the
  pucdata table.)

(Also, at the time, it would have substantially added to the number of
entries in pcidevs, which seemed unnecessary and a little bit
inappropriate since nothing except the pucdata table would ever use
the IDs.)


in a nutshell, "it seemed like a good idea at the time."


cgd