mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-05 16:53:55 -06:00
pc: use AcpiDeviceIfClass.send_event to issue GPE events
it reduces number of args passed in handlers by 1 and a number of used proxy wrappers saving ~20LOC. Also it allows to make cpu/mem hotplug code more universal as it would allow ARM to reuse it without rewrite by providing its own send_event callback to trigger events usiong GPIO instead of GPE as fixed hadrware ACPI model doen't have GPE at all. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
eaf23bf794
commit
0058c08238
10 changed files with 50 additions and 72 deletions
|
@ -15,13 +15,14 @@
|
|||
#include "hw/acpi/acpi.h"
|
||||
#include "hw/acpi/pc-hotplug.h"
|
||||
#include "hw/acpi/aml-build.h"
|
||||
#include "hw/hotplug.h"
|
||||
|
||||
typedef struct AcpiCpuHotplug {
|
||||
MemoryRegion io;
|
||||
uint8_t sts[ACPI_GPE_PROC_LEN];
|
||||
} AcpiCpuHotplug;
|
||||
|
||||
void legacy_acpi_cpu_plug_cb(ACPIREGS *ar, qemu_irq irq,
|
||||
void legacy_acpi_cpu_plug_cb(HotplugHandler *hotplug_dev,
|
||||
AcpiCpuHotplug *g, DeviceState *dev, Error **errp);
|
||||
|
||||
void legacy_acpi_cpu_hotplug_init(MemoryRegion *parent, Object *owner,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue