mbox series

[libdrm,0/4] intel: rework how we add PCI IDs

Message ID 20180824235649.19444-1-lucas.demarchi@intel.com (mailing list archive)
Headers show
Series intel: rework how we add PCI IDs | expand

Message

Lucas De Marchi Aug. 24, 2018, 11:56 p.m. UTC
Adding PCI IDs to different projects is a boring manual task that
motivated me to create this series. The idea is to centralize the IDs in
the kernel header and let other projects copy it.

Initially my plan was to convert all gens, back to gen2, but that proved
slightly difficult since there are some corner cases to cover and I
didn't want to block the important part, i.e.:  for recent gens, there's
no risk of missing a PCI ID.

It does increase the size a little bit, but doesn't explode. Size diff
below showing ~3k:

-  36533            176      40   36749    8f8d build/intel/intel@@drm_intel@sha/intel_bufmgr_gem.c.o
-  66237           1384      24   67645   1083d build/intel/intel@@drm_intel@sha/intel_decode.c.o
+  39362            176      40   39578    9a9a build/intel/intel@@drm_intel@sha/intel_bufmgr_gem.c.o
+  68935           1384      24   70343   112c7 build/intel/intel@@drm_intel@sha/intel_decode.c.o

Let me know what you think.


Lucas De Marchi (4):
  intel: add IS_GENX() generic macro
  intel: make gen11 use generic gen macro
  intel: make gen10 use generic gen macro
  intel: make gen9 use generic gen macro

 intel/i915_pciids.h   | 461 ++++++++++++++++++++++++++++++++++++++++++
 intel/intel_chipset.h | 267 +++---------------------
 2 files changed, 487 insertions(+), 241 deletions(-)
 create mode 100644 intel/i915_pciids.h