All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 1/2] Use defines instead of numbers for pci hotplug sts bit
@ 2010-10-17  9:45 Gleb Natapov
  2010-10-17  9:45 ` [Qemu-devel] [PATCH 2/2] Fix pci hotplug to generate level triggered interrupt Gleb Natapov
  2010-10-20 22:24 ` [Qemu-devel] [PATCH 1/2] Use defines instead of numbers for pci hotplug sts bit Anthony Liguori
  0 siblings, 2 replies; 3+ messages in thread
From: Gleb Natapov @ 2010-10-17  9:45 UTC (permalink / raw)
  To: qemu-devel


Signed-off-by: Gleb Natapov <gleb@redhat.com>
---
 hw/acpi_piix4.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c
index c8733e5..bec42b4 100644
--- a/hw/acpi_piix4.c
+++ b/hw/acpi_piix4.c
@@ -38,6 +38,8 @@
 #define PCI_BASE 0xae00
 #define PCI_EJ_BASE 0xae08
 
+#define PIIX4_PCI_HOTPLUG_STATUS 2
+
 struct gpe_regs {
     uint16_t sts; /* status */
     uint16_t en;  /* enabled */
@@ -596,13 +598,13 @@ static void piix4_acpi_system_hot_add_init(PCIBus *bus, PIIX4PMState *s)
 
 static void enable_device(PIIX4PMState *s, int slot)
 {
-    s->gpe.sts |= 2;
+    s->gpe.sts |= PIIX4_PCI_HOTPLUG_STATUS;
     s->pci0_status.up |= (1 << slot);
 }
 
 static void disable_device(PIIX4PMState *s, int slot)
 {
-    s->gpe.sts |= 2;
+    s->gpe.sts |= PIIX4_PCI_HOTPLUG_STATUS;
     s->pci0_status.down |= (1 << slot);
 }
 
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-10-20 22:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-17  9:45 [Qemu-devel] [PATCH 1/2] Use defines instead of numbers for pci hotplug sts bit Gleb Natapov
2010-10-17  9:45 ` [Qemu-devel] [PATCH 2/2] Fix pci hotplug to generate level triggered interrupt Gleb Natapov
2010-10-20 22:24 ` [Qemu-devel] [PATCH 1/2] Use defines instead of numbers for pci hotplug sts bit Anthony Liguori

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.