[edk2-devel] [edk2-platforms Patch 25/28] Vlv2DeviceRefCodePlg/AcpiTablesPCAT: Fix ASL error
Michael D Kinney
michael.d.kinney at intel.com
Wed Jul 10 19:05:13 UTC 2019
Remove use of a method to read a register from a BAR
and instead access the register directly. Resolves the
following error from the latest iasl compiler.
Or(ShiftLeft(Derefof(Index(CDCT, \_SB.PCI0.GFX0.MCHK.DCFE)), 21),PARM, PARM)
Error 6163 - Object is created temporarily in another method
and cannot be accessed ^ (\_SB.PCI0.GFX0.MCHK.DCFE)
Cc: Zailiang Sun <zailiang.sun at intel.com>
Cc: Yi Qian <yi.qian at intel.com>
Cc: Gary Lin <glin at suse.com>
Signed-off-by: Michael D Kinney <michael.d.kinney at intel.com>
---
.../AcpiTablesPCAT/IgdOGBDA.ASL | 14 ++++++++++++--
.../AcpiTablesPCAT/IgdOpRn.ASL | 18 +-----------------
2 files changed, 13 insertions(+), 19 deletions(-)
diff --git a/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOGBDA.ASL b/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOGBDA.ASL
index 4482db6906..379fca7379 100644
--- a/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOGBDA.ASL
+++ b/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOGBDA.ASL
@@ -1,6 +1,6 @@
/*++
-Copyright (c) 1999 - 2014, Intel Corporation. All rights reserved
+Copyright (c) 1999 - 2019, Intel Corporation. All rights reserved
SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -125,7 +125,17 @@ Method (GBDA, 0, Serialized)
// Report the graphics frequency based on DISPLAY_CLOCK_FREQUENCY_ENCODING [MMADR+0x20C8]
- Or(ShiftLeft(Derefof(Index(CDCT, \_SB.PCI0.GFX0.MCHK.DCFE)), 21),PARM, PARM)
+ If (LNotEqual (MADR, 0xFFFFFFFF))
+ {
+ OperationRegion(IGMM,SystemMemory,MADR,0x3000)
+ Field(IGMM,AnyAcc, NoLock, Preserve)
+ {
+ Offset(0X20C8),
+ , 4,
+ DCFE, 4, // DISPLAY_CLOCK_FREQUENCY_ENCODING
+ }
+ Or(ShiftLeft(Derefof(Index(CDCT, DCFE)), 21),PARM, PARM)
+ }
Store(1, GESF) // Set the modified settings flag
Return(SUCC)
diff --git a/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOpRn.ASL b/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOpRn.ASL
index 8575fbfe6c..386ad3e65e 100644
--- a/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOpRn.ASL
+++ b/Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOpRn.ASL
@@ -1,6 +1,6 @@
/*++
-Copyright (c) 1999 - 2014, Intel Corporation. All rights reserved
+Copyright (c) 1999 - 2019, Intel Corporation. All rights reserved
SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -70,22 +70,6 @@ Field(IGDP, AnyAcc, NoLock, Preserve)
ASLS, 32, // Reg 0xFC, Address of the IGD OpRegion
}
-Method (MCHK, 0, Serialized)
-{
-
- If (LNotEqual (MADR, 0xFFFFFFFF))
- {
- OperationRegion(IGMM,SystemMemory,MADR,0x3000)
- Field(IGMM,AnyAcc, NoLock, Preserve)
- {
- Offset(0X20C8),
- , 4,
- DCFE, 4, // DISPLAY_CLOCK_FREQUENCY_ENCODING
- }
- }
-}
-
-
// Define an OperationRegion to cover the IGD OpRegion layout.
OperationRegion(IGDM, SystemMemory, ASLB, 0x2000)
--
2.21.0.windows.1
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#43521): https://edk2.groups.io/g/devel/message/43521
Mute This Topic: https://groups.io/mt/32419754/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-
More information about the edk2-devel-archive
mailing list