[SeaBIOS] [PATCH 1/2] Rename src/ssdt-susp.dsl to src/ssdt-misc.dsl.

Kevin O'Connor kevin at koconnor.net
Thu Mar 7 04:04:51 CET 2013


Signed-off-by: Kevin O'Connor <kevin at koconnor.net>
---
 Makefile          |  2 +-
 src/acpi.c        |  8 ++++----
 src/ssdt-misc.dsl | 38 ++++++++++++++++++++++++++++++++++++++
 src/ssdt-susp.dsl | 38 --------------------------------------
 4 files changed, 43 insertions(+), 43 deletions(-)
 create mode 100644 src/ssdt-misc.dsl
 delete mode 100644 src/ssdt-susp.dsl

diff --git a/Makefile b/Makefile
index 1ce2f79..ada8fa5 100644
--- a/Makefile
+++ b/Makefile
@@ -220,7 +220,7 @@ $(OUT)%.hex: src/%.dsl ./tools/acpi_extract_preprocess.py ./tools/acpi_extract.p
 	$(Q)$(PYTHON) ./tools/acpi_extract.py $(OUT)$*.lst > $(OUT)$*.off
 	$(Q)cat $(OUT)$*.off > $@
 
-$(OUT)acpi.o: $(OUT)acpi-dsdt.hex $(OUT)ssdt-proc.hex $(OUT)ssdt-pcihp.hex $(OUT)ssdt-susp.hex $(OUT)q35-acpi-dsdt.hex
+$(OUT)acpi.o: $(OUT)acpi-dsdt.hex $(OUT)ssdt-proc.hex $(OUT)ssdt-pcihp.hex $(OUT)ssdt-misc.hex $(OUT)q35-acpi-dsdt.hex
 
 ################ Kconfig rules
 
diff --git a/src/acpi.c b/src/acpi.c
index 195dc88..658ca50 100644
--- a/src/acpi.c
+++ b/src/acpi.c
@@ -439,7 +439,7 @@ encodeLen(u8 *ssdt_ptr, int length, int bytes)
 #define SSDT_SIGNATURE 0x54445353 // SSDT
 #define SSDT_HEADER_LENGTH 36
 
-#include "ssdt-susp.hex"
+#include "ssdt-misc.hex"
 #include "ssdt-pcihp.hex"
 
 #define PCI_RMV_BASE 0xae0c
@@ -496,7 +496,7 @@ static void*
 build_ssdt(void)
 {
     int acpi_cpus = MaxCountCPUs > 0xff ? 0xff : MaxCountCPUs;
-    int length = (sizeof(ssdp_susp_aml)                     // _S3_ / _S4_ / _S5_
+    int length = (sizeof(ssdp_misc_aml)                     // _S3_ / _S4_ / _S5_
                   + (1+3+4)                                 // Scope(_SB_)
                   + (acpi_cpus * PROC_SIZEOF)               // procs
                   + (1+2+5+(12*acpi_cpus))                  // NTFY
@@ -518,14 +518,14 @@ build_ssdt(void)
     if (!sys_states || sys_state_size != 6)
         sys_states = (char[]){128, 0, 0, 129, 128, 128};
 
-    memcpy(ssdt_ptr, ssdp_susp_aml, sizeof(ssdp_susp_aml));
+    memcpy(ssdt_ptr, ssdp_misc_aml, sizeof(ssdp_misc_aml));
     if (!(sys_states[3] & 128))
         ssdt_ptr[acpi_s3_name[0]] = 'X';
     if (!(sys_states[4] & 128))
         ssdt_ptr[acpi_s4_name[0]] = 'X';
     else
         ssdt_ptr[acpi_s4_pkg[0] + 1] = ssdt[acpi_s4_pkg[0] + 3] = sys_states[4] & 127;
-    ssdt_ptr += sizeof(ssdp_susp_aml);
+    ssdt_ptr += sizeof(ssdp_misc_aml);
 
     // build Scope(_SB_) header
     *(ssdt_ptr++) = 0x10; // ScopeOp
diff --git a/src/ssdt-misc.dsl b/src/ssdt-misc.dsl
new file mode 100644
index 0000000..f0a8df3
--- /dev/null
+++ b/src/ssdt-misc.dsl
@@ -0,0 +1,38 @@
+ACPI_EXTRACT_ALL_CODE ssdp_misc_aml
+
+DefinitionBlock ("ssdt-misc.aml", "SSDT", 0x01, "BXPC", "BXSSDTSUSP", 0x1)
+{
+
+/****************************************************************
+ * Suspend
+ ****************************************************************/
+
+    Scope(\) {
+    /*
+     * S3 (suspend-to-ram), S4 (suspend-to-disk) and S5 (power-off) type codes:
+     * must match piix4 emulation.
+     */
+
+        ACPI_EXTRACT_NAME_STRING acpi_s3_name
+        Name(_S3, Package(0x04) {
+            One,  /* PM1a_CNT.SLP_TYP */
+            One,  /* PM1b_CNT.SLP_TYP */
+            Zero,  /* reserved */
+            Zero   /* reserved */
+        })
+        ACPI_EXTRACT_NAME_STRING acpi_s4_name
+        ACPI_EXTRACT_PKG_START acpi_s4_pkg
+        Name(_S4, Package(0x04) {
+            0x2,  /* PM1a_CNT.SLP_TYP */
+            0x2,  /* PM1b_CNT.SLP_TYP */
+            Zero,  /* reserved */
+            Zero   /* reserved */
+        })
+        Name(_S5, Package(0x04) {
+            Zero,  /* PM1a_CNT.SLP_TYP */
+            Zero,  /* PM1b_CNT.SLP_TYP */
+            Zero,  /* reserved */
+            Zero   /* reserved */
+        })
+    }
+}
diff --git a/src/ssdt-susp.dsl b/src/ssdt-susp.dsl
deleted file mode 100644
index ca9428f..0000000
--- a/src/ssdt-susp.dsl
+++ /dev/null
@@ -1,38 +0,0 @@
-ACPI_EXTRACT_ALL_CODE ssdp_susp_aml
-
-DefinitionBlock ("ssdt-susp.aml", "SSDT", 0x01, "BXPC", "BXSSDTSUSP", 0x1)
-{
-
-/****************************************************************
- * Suspend
- ****************************************************************/
-
-    Scope(\) {
-    /*
-     * S3 (suspend-to-ram), S4 (suspend-to-disk) and S5 (power-off) type codes:
-     * must match piix4 emulation.
-     */
-
-        ACPI_EXTRACT_NAME_STRING acpi_s3_name
-        Name(_S3, Package(0x04) {
-            One,  /* PM1a_CNT.SLP_TYP */
-            One,  /* PM1b_CNT.SLP_TYP */
-            Zero,  /* reserved */
-            Zero   /* reserved */
-        })
-        ACPI_EXTRACT_NAME_STRING acpi_s4_name
-        ACPI_EXTRACT_PKG_START acpi_s4_pkg
-        Name(_S4, Package(0x04) {
-            0x2,  /* PM1a_CNT.SLP_TYP */
-            0x2,  /* PM1b_CNT.SLP_TYP */
-            Zero,  /* reserved */
-            Zero   /* reserved */
-        })
-        Name(_S5, Package(0x04) {
-            Zero,  /* PM1a_CNT.SLP_TYP */
-            Zero,  /* PM1b_CNT.SLP_TYP */
-            Zero,  /* reserved */
-            Zero   /* reserved */
-        })
-    }
-}
-- 
1.7.11.7




More information about the SeaBIOS mailing list