On 07/26/12 20:50, Jordan Justen wrote:
> On Thu, Jul 26, 2012 at 9:55 AM, Paolo Bonzini <pbonz...@redhat.com> wrote:
>> Il 26/07/2012 18:40, Jordan Justen ha scritto:
>>> Shouldn't we add this range to ACPI?
>>
>> Yeah, we could. Not sure what *PNP id to use though.
>
> Probably just add it to the XTRA device.
I tried to do it after consulting
<http://sourceforge.net/mailarchive/message.php?msg_id=29533908> again
(kudos Ifan); please see the first patch. The build failed.
I figured perhaps including AutoGen.h would help (second patch). It didn't.
I noticed there's a difference between <Command.MSFT, Command.INTEL> and
<Command.GCC> in "BaseTools/Conf/build_rule.template", section
[Acpi-Source-Language-File]. I attempted to rectify it (patch three) but
the build still fails. The .iiii file passed to iasl is still littered
with typedefs and function/variable declarations. The PCD I care about
is correctly expanded, although I'll have to change its value to a plain
decimal string as Ifan pointed out earlier.
I use the RHEL-6.3 iasl package (iasl-20090123-3.1.el6.x86_64):
Intel ACPI Component Architecture
ASL Optimizing Compiler version 20090123 [Dec 4 2009]
Copyright (C) 2000 - 2009 Intel Corporation
Supports ACPI Specification Revision 3.0a
Any ideas? If so, can we please update
<http://sourceforge.net/apps/mediawiki/tianocore/index.php?title=PCD#Are_PCDs_supported_within_the_ACPI_and_AML.3F>?
Thanks!
Laszlo
From 63b3127b270b8931ed4eb2c7314b9e6eaf94da35 Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Mon, 30 Jul 2012 11:49:38 +0200
Subject: [PATCH 1/3] OvmfPkg: add QEMU debug console port to the XTRA device
Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
OvmfPkg/AcpiTables/AcpiTables.inf | 3 +++
OvmfPkg/AcpiTables/Dsdt.asl | 7 +++++++
2 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/OvmfPkg/AcpiTables/AcpiTables.inf
b/OvmfPkg/AcpiTables/AcpiTables.inf
index 1187a14..bd1eec3 100644
--- a/OvmfPkg/AcpiTables/AcpiTables.inf
+++ b/OvmfPkg/AcpiTables/AcpiTables.inf
@@ -37,4 +37,7 @@
[Packages]
MdePkg/MdePkg.dec
+ OvmfPkg/OvmfPkg.dec
+[Pcd]
+ gUefiOvmfPkgTokenSpaceGuid.PcdDebugIoPort ## CONSUMES
diff --git a/OvmfPkg/AcpiTables/Dsdt.asl b/OvmfPkg/AcpiTables/Dsdt.asl
index 0ef0d3d..a311674 100644
--- a/OvmfPkg/AcpiTables/Dsdt.asl
+++ b/OvmfPkg/AcpiTables/Dsdt.asl
@@ -445,6 +445,13 @@ DefinitionBlock ("Dsdt.aml", "DSDT", 1, "INTEL ", "OVMF
", 3) {
IO (Decode16, 0x278, 0x278, 0x00, 0x08)
IO (Decode16, 0x370, 0x370, 0x00, 0x02)
IO (Decode16, 0x378, 0x378, 0x00, 0x08)
+ IO (
+ Decode16,
+ FixedPcdGet16 (PcdDebugIoPort),
+ FixedPcdGet16 (PcdDebugIoPort),
+ 0x00,
+ 0x01
+ ) // QEMU debug console
IO (Decode16, 0x440, 0x440, 0x00, 0x10)
IO (Decode16, 0x678, 0x678, 0x00, 0x08)
IO (Decode16, 0x778, 0x778, 0x00, 0x08)
--
1.7.1
From a9a05a863105a24d6ae5c04ac54d0546796300fc Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Mon, 30 Jul 2012 11:53:56 +0200
Subject: [PATCH 2/3] OvmfPkg: include AutoGen.h in Dsdt.asl for PCDs
Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
OvmfPkg/AcpiTables/Dsdt.asl | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/OvmfPkg/AcpiTables/Dsdt.asl b/OvmfPkg/AcpiTables/Dsdt.asl
index a311674..4245c42 100644
--- a/OvmfPkg/AcpiTables/Dsdt.asl
+++ b/OvmfPkg/AcpiTables/Dsdt.asl
@@ -12,6 +12,8 @@
**/
+#include "AutoGen.h"
+
DefinitionBlock ("Dsdt.aml", "DSDT", 1, "INTEL ", "OVMF ", 3) {
//
// System Sleep States
--
1.7.1
From e6935d397bf61b5dff34ce7bf76f5d19347d947f Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Mon, 30 Jul 2012 11:53:13 +0200
Subject: [PATCH 3/3] BaseTools: trim preprocessed ASL file before compiling it
Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
BaseTools/Conf/build_rule.template | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/BaseTools/Conf/build_rule.template
b/BaseTools/Conf/build_rule.template
index 107e783..dfef153 100644
--- a/BaseTools/Conf/build_rule.template
+++ b/BaseTools/Conf/build_rule.template
@@ -359,7 +359,8 @@
<Command.GCC>
Trim --asl-file -o $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.i -i
$(INC_LIST) ${src}
"$(ASLPP)" $(ASLPP_FLAGS) $(INC) -I${s_path}
$(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.i >
$(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.iii
- "$(ASL)" $(ASL_FLAGS) $(ASL_OUTFLAGS)${dst}
$(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.iii
+ Trim --source-code -l -o $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.iiii
$(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.iii
+ "$(ASL)" $(ASL_FLAGS) $(ASL_OUTFLAGS)${dst}
$(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.iiii
[C-Code-File.AcpiTable]
<InputFile>
--
1.7.1
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel