[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] hvmloader: Add an ACPI device exposing a package called ADDR,



# HG changeset patch
# User Paul Durrant <paul.durrant@xxxxxxxxxx>
# Date 1322664436 28800
# Node ID e5a53cdd425202d5bc9c800b88a0c4a425f66b67
# Parent  67c447c02537d8e6c8736b62d45bf6892149fc97
hvmloader: Add an ACPI device exposing a package called ADDR,
evaluating to two integers, and with _CID and _DDN set to
"VM_Gen_Counter".

Signed-off-by: Paul Durrant <paul.durrant@xxxxxxxxxx>
Committed-by: Keir Fraser <keir@xxxxxxx>
---


diff -r 67c447c02537 -r e5a53cdd4252 tools/firmware/hvmloader/acpi/build.c
--- a/tools/firmware/hvmloader/acpi/build.c     Wed Nov 30 06:42:04 2011 -0800
+++ b/tools/firmware/hvmloader/acpi/build.c     Wed Nov 30 06:47:16 2011 -0800
@@ -47,6 +47,7 @@
     uint32_t pci_min, pci_len;  /* 4, 8 - PCI I/O hole boundaries */
     uint32_t madt_csum_addr;    /* 12   - Address of MADT checksum */
     uint32_t madt_lapic0_addr;  /* 16   - Address of first MADT LAPIC struct */
+    uint32_t vm_gid_addr;       /* 20   - Address of VM generation id buffer */
 };
 
 /* Number of processor objects in the chosen DSDT. */
diff -r 67c447c02537 -r e5a53cdd4252 tools/firmware/hvmloader/acpi/dsdt.asl
--- a/tools/firmware/hvmloader/acpi/dsdt.asl    Wed Nov 30 06:42:04 2011 -0800
+++ b/tools/firmware/hvmloader/acpi/dsdt.asl    Wed Nov 30 06:47:16 2011 -0800
@@ -55,7 +55,8 @@
            PMIN, 32,
            PLEN, 32,
            MSUA, 32, /* MADT checksum address */
-           MAPA, 32  /* MADT LAPIC0 address */
+           MAPA, 32, /* MADT LAPIC0 address */
+           VGIA, 32  /* VM generation id address */
        }
 
         /* Fix HCT test for 0x400 pci memory:
@@ -396,6 +397,31 @@
                         IRQNoFlags () {7}
                     })
                 } 
+
+                Device(VGID) {
+                    Name(_HID, EisaID ("PNP0A06"))
+                    Name(_UID, 0x00)
+                    Name(_CID, "VM_Gen_Counter")
+                    Name(_DDN, "VM_Gen_Counter")
+                    Method(_STA, 0, NotSerialized)
+                    {
+                        If(LEqual(\_SB.VGIA, 0x00000000)) {
+                            Return(0x00)
+                        } Else {
+                            Return(0x0F)
+                        }
+                    }
+                    Name(PKG, Package ()
+                    {
+                        0x00000000,
+                        0x00000000
+                    })
+                    Method(ADDR, 0, NotSerialized)
+                    {
+                        Store(\_SB.VGIA, Index(PKG, 0))
+                        Return(PKG)
+                    }
+                }
             }
         }
     }

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.