acpi: build PCI hotplug devices from a single template

More than 1kb of data is taken by the 32 copies of the PCI hotplug SSDT
methods.  We can build them from a single template like we do for CPUs
(wrapped in a Scope(\_SB.PCI0) block).

Three items differ for each slot: the device name, bits 16-23 of _ADR,
the _SUN value.  On top of this we have to rename the eject method for
non-removable slots, like we already do in build_pcihp.

There is a small change in the ASL: instead of including the number of
the slot in the implementation of _EJ0, we just call _SUN.  This is also
similar to what we do for CPU hotplug.

Once we do this, there is no need to keep a separate SSDT for PCI hotplug.
Everything can reside in the same table.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2 files changed
tree: 05268f9c325b4f01e75d643f7bb47c03dc8eff94
  1. .gitignore
  2. COPYING
  3. COPYING.LESSER
  4. Makefile
  5. README
  6. TODO
  7. src/
  8. tools/
  9. vgasrc/