summaryrefslogtreecommitdiff
path: root/ReferenceCode/AcpiTables/SsdtIRMT
diff options
context:
space:
mode:
authorraywu <raywu0301@gmail.com>2018-06-15 00:00:50 +0800
committerraywu <raywu0301@gmail.com>2018-06-15 00:00:50 +0800
commitb7c51c9cf4864df6aabb99a1ae843becd577237c (patch)
treeeebe9b0d0ca03062955223097e57da84dd618b9a /ReferenceCode/AcpiTables/SsdtIRMT
downloadzprj-b7c51c9cf4864df6aabb99a1ae843becd577237c.tar.xz
init. 1AQQW051HEADmaster
Diffstat (limited to 'ReferenceCode/AcpiTables/SsdtIRMT')
-rw-r--r--ReferenceCode/AcpiTables/SsdtIRMT/IntelRMT.asl108
-rw-r--r--ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.cif10
-rw-r--r--ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.mak80
-rw-r--r--ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.sdl31
4 files changed, 229 insertions, 0 deletions
diff --git a/ReferenceCode/AcpiTables/SsdtIRMT/IntelRMT.asl b/ReferenceCode/AcpiTables/SsdtIRMT/IntelRMT.asl
new file mode 100644
index 0000000..a37c052
--- /dev/null
+++ b/ReferenceCode/AcpiTables/SsdtIRMT/IntelRMT.asl
@@ -0,0 +1,108 @@
+//
+// Defined as an SSDT to be able to dynamically load based on BIOS
+// setup options
+//
+DefinitionBlock (
+ "IntelRMT.aml",
+ "SSDT",
+ 0x01,
+ "Intel",
+ "IntelRMT",
+ 0x1000
+ )
+
+
+{
+External(\ADBG, MethodObj)
+External(P8XH, MethodObj)
+External(INSC, IntObj)
+
+
+ Scope(\_SB)
+ {
+ Device (INSD)
+ {
+ Name (_HID, "INT3398")
+ Name (_CID, EISAID("PNP0C02"))
+ Name (_UID, 0x00)
+
+ Name (NBT1, 0) // Intel Intelr RMT Technology local variable
+ // Intelr RMT Modes
+ // 0: Exit Intelr RMT
+ // 1: Enter Intelr RMT Active State
+ // 2: Enter Intelr RMT Idle State
+ // 3: Enter Intelr RMT Do Not Disturb State
+ // 4: Enter Suspend
+
+ Method(GNSC, 0, NotSerialized)
+ {
+ // DEBUG START //
+ Store(INSC, Local0)
+ P8XH(0,0xAA)
+ ADBG("GNSC: ")
+ ADBG(ToHexString(Local0))
+ // DEBUG END //
+ return (INSC)
+ }
+
+ Method(GNSM, 0, Serialized)
+ {
+ Store(NBT1, Local0)
+ // DEBUG START //
+ P8XH(0,0x71)
+ ADBG("GNSM: ")
+ ADBG(ToHexString(Local0))
+ // DEBUG END //
+ Return (Local0)
+ }
+
+ Method(SNSM, 1, Serialized)
+ {
+ Store(Arg0, NBT1)
+ Store(NBT1, Local0)
+ Switch(ToInteger(Local0))
+ {
+ Case (0)
+ {
+ ADBG("case 0: ")
+ // 0: Exit Intelr RMT
+ // TODO: Add platform specific code here
+ }
+ Case (1)
+ {
+ ADBG("case 1: ")
+ // 1: Enter Intelr RMT Active State
+ // TODO: Add platform specific code here
+ }
+ Case (2)
+ {
+ ADBG("case 2: ")
+ // 2: Enter Intelr RMT Idle State
+ // TODO: Add platform specific code here
+ }
+ Case (3)
+ {
+ ADBG("case 3: ")
+ // 3: Enter Intelr RMT Do Not Disturb State
+ // TODO: Add platform specific code here
+ }
+ Case (4)
+ {
+ ADBG("case 4: ")
+ // 4: Enter Suspend
+ // TODO: Add platform specific code here
+ }
+
+ }
+
+ // DEBUG START //
+ P8XH(0,0x72)
+ ADBG("SNSM: ")
+ ADBG(ToHexString(Local0))
+ // DEBUG END //
+ }
+
+ } // Device (INSD)
+
+ } // end \_SB scope
+} // end SSDT
diff --git a/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.cif b/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.cif
new file mode 100644
index 0000000..38a2bd1
--- /dev/null
+++ b/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.cif
@@ -0,0 +1,10 @@
+<component>
+ name = "SsdtIRMT"
+ category = ModulePart
+ LocalRoot = "ReferenceCode\AcpiTables\SsdtIRMT\"
+ RefName = "SsdtIRMT"
+[files]
+"SsdtIRMT.sdl"
+"SsdtIRMT.mak"
+"IntelRMT.asl"
+<endComponent>
diff --git a/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.mak b/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.mak
new file mode 100644
index 0000000..9f2b6b7
--- /dev/null
+++ b/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.mak
@@ -0,0 +1,80 @@
+#*************************************************************************
+#*************************************************************************
+#** **
+#** (C)Copyright 1985-2014, American Megatrends, Inc. **
+#** **
+#** All Rights Reserved. **
+#** **
+#** 5555 Oakbrook Parkway, Suite 200, Norcross, GA 30093 **
+#** **
+#** Phone: (770)-246-8600 **
+#** **
+#*************************************************************************
+#*************************************************************************
+
+#*************************************************************************
+#<AMI_FHDR_START>
+#
+# Name: SsdtIRMT.mak
+#
+# Description: MAke file to build Aptio ACPI ASL components
+#
+#
+#<AMI_FHDR_END>
+#*************************************************************************
+all : BuildIRMT
+
+BuildIRMT : $(BUILD_DIR)\IntelRMT.ffs
+
+#-----------------------------------------------------------------------
+# ASL compiler definition
+#-----------------------------------------------------------------------
+!IF "$(ACPIPLATFORM_ASL_COMPILER)"==""
+!ERROR It is an invalid path, please check your ASL compiler path.
+!ENDIF
+
+IASL = $(ACPIPLATFORM_ASL_COMPILER)
+#-----------------------------------------------------------------------
+$(BUILD_DIR)\IntelRMT.aml : $(INTEL_IRMT_ASL_FILE)
+ @cl /C /EP $(INTEL_IRMT_ASL_FILE) > $(BUILD_DIR)\IntelRMT.asl
+ $(IASL) -p $(BUILD_DIR)\IntelRMT.aml $(BUILD_DIR)\IntelRMT.asl
+
+$(BUILD_DIR)\IntelRMT.sec: $(BUILD_DIR)\IntelRMT.aml
+ $(GENSECTION) -I $*.aml -O $@ -S EFI_SECTION_RAW
+
+#Note. Expand the package with PTID tables.
+# DXE phase will load the tables
+# and update Aml contents if provided in Acpiplatform.c
+
+$(BUILD_DIR)\IntelRMT.ffs: $(BUILD_DIR)\IntelRMT.sec
+ $(GENFFSFILE) -B $(BUILD_DIR) -V -o $@ -P1 <<$(BUILD_DIR)\IntelRMT.pkg
+
+PACKAGE.INF
+[.]
+BASE_NAME = IntelRMT
+FFS_FILEGUID = CE2007C7-B389-49c5-84E3-DB36A1F0993B
+FFS_FILETYPE = EFI_FV_FILETYPE_FREEFORM
+FFS_ATTRIB_CHECKSUM = TRUE
+
+IMAGE_SCRIPT =
+{
+ Compress (dummy) {
+ $(PROJECT_DIR)\$(BUILD_DIR)\IntelRMT.sec
+ }
+}
+<<KEEP
+
+
+#*************************************************************************
+#*************************************************************************
+#** **
+#** (C)Copyright 1985-2014, American Megatrends, Inc. **
+#** **
+#** All Rights Reserved. **
+#** **
+#** 5555 Oakbrook Parkway, Suite 200, Norcross, GA 30093 **
+#** **
+#** Phone: (770)-246-8600 **
+#** **
+#*************************************************************************
+#*************************************************************************
diff --git a/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.sdl b/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.sdl
new file mode 100644
index 0000000..62458f6
--- /dev/null
+++ b/ReferenceCode/AcpiTables/SsdtIRMT/SsdtIRMT.sdl
@@ -0,0 +1,31 @@
+TOKEN
+ Name = "IntelRMT_SUPPORT"
+ Value = "1"
+ Help = "Main switch to enable Intel Ready Mode Technology support in Project"
+ TokenType = Boolean
+ TargetMAK = Yes
+ TargetH = Yes
+ Master = Yes
+End
+
+PATH
+ Name = "INTEL_SSDTIRMT_DIR"
+End
+
+TOKEN
+ Name = "INTEL_IRMT_ASL_FILE"
+ Value = "$(INTEL_SSDTIRMT_DIR)\IntelRMT.asl"
+ TokenType = Expression
+ TargetMAK = Yes
+End
+
+MODULE
+ Help = "Includes SsdtIRMT.mak to Project"
+ File = "SsdtIRMT.mak"
+End
+
+ELINK
+ Name = "$(BUILD_DIR)\IntelRMT.ffs"
+ Parent = "FV_MAIN"
+ InvokeOrder = AfterParent
+End