qemu/include/hw/acpi
Igor Mammedov b7f23f62e4 pci: acpi: add _DSM method to PCI devices
Implement _DSM according to:
    PCI Firmware Specification 3.1
    4.6.7.  DSM for Naming a PCI or PCI Express Device Under
            Operating Systems
and wire it up to cold and hot-plugged PCI devices.
Feature depends on ACPI hotplug being enabled (as that provides
PCI devices descriptions in ACPI and MMIO registers that are
reused to fetch acpi-index).

acpi-index should work for
  - cold plugged NICs:
      $QEMU -device e1000,acpi-index=100
         => 'eno100'
  - hot-plugged
      (monitor) device_add e1000,acpi-index=200,id=remove_me
         => 'eno200'
  - re-plugged
      (monitor) device_del remove_me
      (monitor) device_add e1000,acpi-index=1
         => 'eno1'

Windows also sees index under "PCI Label Id" field in properties
dialog but otherwise it doesn't seem to have any effect.

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
Message-Id: <20210315180102.3008391-6-imammedo@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2021-03-22 18:58:19 -04:00
..
acpi_dev_interface.h qapi: Extract ACPI commands to 'acpi.json' 2020-09-29 15:41:36 +02:00
acpi-defs.h acpi: Permit OEM ID and OEM table ID fields to be changed 2021-02-05 08:52:59 -05:00
acpi.h acpi/core: always set SCI_EN when SMM isn't supported 2021-02-23 10:58:42 -05:00
aml-build.h acpi: add aml_to_decimalstring() and aml_call6() helpers 2021-03-22 18:58:19 -04:00
bios-linker-loader.h
cpu_hotplug.h
cpu.h x86: acpi: let the firmware handle pending "CPU remove" events in SMM 2020-12-09 13:04:17 -05:00
generic_event_device.h Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
ghes.h acpi: Permit OEM ID and OEM table ID fields to be changed 2021-02-05 08:52:59 -05:00
ich9.h ich9, piix4: add property, smm-compat, to keep compatibility of SMM 2021-02-23 10:58:42 -05:00
ipmi.h ipmi: Fix SSIF ACPI handling to use the right CRS 2019-09-20 14:08:10 -05:00
memory_hotplug.h hw/acpi: Make ACPI IO address space configurable 2019-10-05 17:12:08 -04:00
pc-hotplug.h
pci.h pci: acpi: add _DSM method to PCI devices 2021-03-22 18:58:19 -04:00
pcihp.h pci: introduce acpi-index property for PCI device 2021-03-22 18:58:19 -04:00
tco.h Include migration/vmstate.h less 2019-08-16 13:31:52 +02:00
tpm.h acpi: build TPM Physical Presence interface 2019-01-17 21:10:57 -05:00
utils.h hw/acpi: extract acpi_add_rom_blob() 2019-06-16 16:16:52 -04:00
vmgenid.h acpi: Permit OEM ID and OEM table ID fields to be changed 2021-02-05 08:52:59 -05:00