These patches add the DBG2/SPCR tables for FVP/Juno for kernel testing.
They allow a kernel to find a serial console without console= line.
They have been tested using the Redhat patches for SPCR support which are work in progress!
Thanks
Changes since v1 Ryan pointed out I had used RTSM in the JUNO tables - fixed.
These tables allow console initialisation for an OS without adding specific arguments to the cmdline for linux or other methods on Windows
DBG2 table needs a dummy OEM Data: field to work around a bug in iasl parser.
Cc: Leif Lindholm leif.lindholm@linaro.org Signed-off-by: Graeme Gregory graeme.gregory@linaro.org --- .../AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf | 2 + .../AcpiTables/rtsm_ve-aemv8a/dbg2.asl | 72 +++++++++++++++++++++ .../AcpiTables/rtsm_ve-aemv8a/spcr.asl | 73 ++++++++++++++++++++++ 3 files changed, 147 insertions(+) create mode 100644 ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl create mode 100644 ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl
diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf index c851d12..ecb4ca6 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf @@ -27,6 +27,8 @@ dsdt.asl facp.asl gtdt.asl + dbg2.asl + spcr.asl
[Packages] MdePkg/MdePkg.dec diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl new file mode 100644 index 0000000..47cee69 --- /dev/null +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl @@ -0,0 +1,72 @@ +/* + * Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED + * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * + * NB: This License is also known as the "BSD 2-Clause License". + * + * + * [DBG2] ACPI Table + * + */ + +[0004] Signature : "DBG2" [Debug Port table type 2] +[0004] Table Length : 0000005A +[0001] Revision : 00 +[0001] Checksum : 06 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "RTSMVEV8" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926 + +[0004] Info Offset : 0000002C +[0004] Info Count : 00000001 + +[0001] Revision : 00 +[0002] Length : 002C +[0001] Register Count : 01 +[0002] Namepath Length : 0005 +[0002] Namepath Offset : 0026 +[0002] OEM Data Length : 0000 [Optional field not present] +[0002] OEM Data Offset : 0000 [Optional field not present] +[0002] Port Type : 8000 +[0002] Port Subtype : 0003 +[0002] Reserved : 0000 +[0002] Base Address Offset : 0016 +[0002] Address Size Offset : 0022 + +[000C] Base Address Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000001C090000 + +[0004] Address Size : 00001000 + +[0004] Namepath : "COM1" +[0001] OEM Data : 00 diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl new file mode 100644 index 0000000..9d0edba --- /dev/null +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl @@ -0,0 +1,73 @@ +/* + * Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED + * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * + * NB: This License is also known as the "BSD 2-Clause License". + * + * + * [SPCR] ACPI Table + * + */ + +[0004] Signature : "SPCR" [Serial Port Console Redirection table] +[0004] Table Length : 00000050 +[0001] Revision : 02 +[0001] Checksum : 29 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "RTSMVEV8" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926 + +[0001] Interface Type : 03 +[0003] Reserved : 000000 + +[000C] Serial Port Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000001C090000 + +[0001] Interrupt Type : 08 +[0001] PCAT-compatible IRQ : 00 +[0004] Interrupt : 00000025 +[0001] Baud Rate : 07 +[0001] Parity : 00 +[0001] Stop Bits : 01 +[0001] Flow Control : 00 +[0001] Terminal Type : 03 +[0001] Reserved : 00 +[0002] PCI Device ID : FFFF +[0002] PCI Vendor ID : FFFF +[0001] PCI Bus : 00 +[0001] PCI Device : 00 +[0001] PCI Function : 00 +[0004] PCI Flags : 00000000 +[04Bh] PCI Segment : 00 +[04Ch] Reserved : 00000000 +
On 04/16/2015 05:28 AM, Graeme Gregory wrote:
These tables allow console initialisation for an OS without adding specific arguments to the cmdline for linux or other methods on Windows
DBG2 table needs a dummy OEM Data: field to work around a bug in iasl parser.
Nice addition; I tend to forget adding console= on the cmdline :).
Has a bug report been filed (or does one already exist) at ACPICA? I can do that if it hasn't been done already; it's just when the OEM Data field is missing, yeah?
Cc: Leif Lindholm leif.lindholm@linaro.org Signed-off-by: Graeme Gregory graeme.gregory@linaro.org
.../AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf | 2 + .../AcpiTables/rtsm_ve-aemv8a/dbg2.asl | 72 +++++++++++++++++++++ .../AcpiTables/rtsm_ve-aemv8a/spcr.asl | 73 ++++++++++++++++++++++ 3 files changed, 147 insertions(+) create mode 100644 ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl create mode 100644 ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl
diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf index c851d12..ecb4ca6 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf @@ -27,6 +27,8 @@ dsdt.asl facp.asl gtdt.asl
- dbg2.asl
- spcr.asl
[Packages] MdePkg/MdePkg.dec diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl new file mode 100644 index 0000000..47cee69 --- /dev/null +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl @@ -0,0 +1,72 @@ +/*
- Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org
- All rights reserved.
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions
- are met:
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- NB: This License is also known as the "BSD 2-Clause License".
- [DBG2] ACPI Table
- */
+[0004] Signature : "DBG2" [Debug Port table type 2] +[0004] Table Length : 0000005A +[0001] Revision : 00 +[0001] Checksum : 06 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "RTSMVEV8" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926
+[0004] Info Offset : 0000002C +[0004] Info Count : 00000001
+[0001] Revision : 00 +[0002] Length : 002C +[0001] Register Count : 01 +[0002] Namepath Length : 0005 +[0002] Namepath Offset : 0026 +[0002] OEM Data Length : 0000 [Optional field not present] +[0002] OEM Data Offset : 0000 [Optional field not present] +[0002] Port Type : 8000 +[0002] Port Subtype : 0003 +[0002] Reserved : 0000 +[0002] Base Address Offset : 0016 +[0002] Address Size Offset : 0022
+[000C] Base Address Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000001C090000
+[0004] Address Size : 00001000
+[0004] Namepath : "COM1" +[0001] OEM Data : 00 diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl new file mode 100644 index 0000000..9d0edba --- /dev/null +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl @@ -0,0 +1,73 @@ +/*
- Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org
- All rights reserved.
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions
- are met:
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- NB: This License is also known as the "BSD 2-Clause License".
- [SPCR] ACPI Table
- */
+[0004] Signature : "SPCR" [Serial Port Console Redirection table] +[0004] Table Length : 00000050 +[0001] Revision : 02 +[0001] Checksum : 29 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "RTSMVEV8" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926
+[0001] Interface Type : 03 +[0003] Reserved : 000000
+[000C] Serial Port Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000001C090000
+[0001] Interrupt Type : 08 +[0001] PCAT-compatible IRQ : 00 +[0004] Interrupt : 00000025 +[0001] Baud Rate : 07 +[0001] Parity : 00 +[0001] Stop Bits : 01 +[0001] Flow Control : 00 +[0001] Terminal Type : 03 +[0001] Reserved : 00 +[0002] PCI Device ID : FFFF +[0002] PCI Vendor ID : FFFF +[0001] PCI Bus : 00 +[0001] PCI Device : 00 +[0001] PCI Function : 00 +[0004] PCI Flags : 00000000 +[04Bh] PCI Segment : 00 +[04Ch] Reserved : 00000000
On 16 April 2015 at 19:04, Al Stone al.stone@linaro.org wrote:
On 04/16/2015 05:28 AM, Graeme Gregory wrote:
These tables allow console initialisation for an OS without adding specific arguments to the cmdline for linux or other methods on Windows
DBG2 table needs a dummy OEM Data: field to work around a bug in iasl parser.
Nice addition; I tend to forget adding console= on the cmdline :).
Has a bug report been filed (or does one already exist) at ACPICA? I can do that if it hasn't been done already; it's just when the OEM Data field is missing, yeah?
The compiler cannot handle an optional field that also happens to be the last field as far as I can see. I did not realise acpica had a bugzilla.
Graeme
Cc: Leif Lindholm leif.lindholm@linaro.org Signed-off-by: Graeme Gregory graeme.gregory@linaro.org
.../AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf | 2 + .../AcpiTables/rtsm_ve-aemv8a/dbg2.asl | 72 +++++++++++++++++++++ .../AcpiTables/rtsm_ve-aemv8a/spcr.asl | 73 ++++++++++++++++++++++ 3 files changed, 147 insertions(+) create mode 100644 ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl create mode 100644 ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl
diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf index c851d12..ecb4ca6 100644 --- a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/AcpiTables.inf @@ -27,6 +27,8 @@ dsdt.asl facp.asl gtdt.asl
- dbg2.asl
- spcr.asl
[Packages] MdePkg/MdePkg.dec diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl new file mode 100644 index 0000000..47cee69 --- /dev/null +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/dbg2.asl @@ -0,0 +1,72 @@ +/*
- Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org
- All rights reserved.
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions
- are met:
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- NB: This License is also known as the "BSD 2-Clause License".
- [DBG2] ACPI Table
- */
+[0004] Signature : "DBG2" [Debug Port table type 2] +[0004] Table Length : 0000005A +[0001] Revision : 00 +[0001] Checksum : 06 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "RTSMVEV8" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926
+[0004] Info Offset : 0000002C +[0004] Info Count : 00000001
+[0001] Revision : 00 +[0002] Length : 002C +[0001] Register Count : 01 +[0002] Namepath Length : 0005 +[0002] Namepath Offset : 0026 +[0002] OEM Data Length : 0000 [Optional field not present] +[0002] OEM Data Offset : 0000 [Optional field not present] +[0002] Port Type : 8000 +[0002] Port Subtype : 0003 +[0002] Reserved : 0000 +[0002] Base Address Offset : 0016 +[0002] Address Size Offset : 0022
+[000C] Base Address Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000001C090000
+[0004] Address Size : 00001000
+[0004] Namepath : "COM1" +[0001] OEM Data : 00 diff --git a/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl new file mode 100644 index 0000000..9d0edba --- /dev/null +++ b/ArmPlatformPkg/ArmVExpressPkg/AcpiTables/rtsm_ve-aemv8a/spcr.asl @@ -0,0 +1,73 @@ +/*
- Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org
- All rights reserved.
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions
- are met:
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- NB: This License is also known as the "BSD 2-Clause License".
- [SPCR] ACPI Table
- */
+[0004] Signature : "SPCR" [Serial Port Console Redirection table] +[0004] Table Length : 00000050 +[0001] Revision : 02 +[0001] Checksum : 29 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "RTSMVEV8" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926
+[0001] Interface Type : 03 +[0003] Reserved : 000000
+[000C] Serial Port Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000001C090000
+[0001] Interrupt Type : 08 +[0001] PCAT-compatible IRQ : 00 +[0004] Interrupt : 00000025 +[0001] Baud Rate : 07 +[0001] Parity : 00 +[0001] Stop Bits : 01 +[0001] Flow Control : 00 +[0001] Terminal Type : 03 +[0001] Reserved : 00 +[0002] PCI Device ID : FFFF +[0002] PCI Vendor ID : FFFF +[0001] PCI Bus : 00 +[0001] PCI Device : 00 +[0001] PCI Function : 00 +[0004] PCI Flags : 00000000 +[04Bh] PCI Segment : 00 +[04Ch] Reserved : 00000000
-- ciao, al
Al Stone Software Engineer Linaro Enterprise Group al.stone@linaro.org
On 04/16/2015 12:51 PM, G Gregory wrote:
On 16 April 2015 at 19:04, Al Stone al.stone@linaro.org wrote:
On 04/16/2015 05:28 AM, Graeme Gregory wrote:
These tables allow console initialisation for an OS without adding specific arguments to the cmdline for linux or other methods on Windows
DBG2 table needs a dummy OEM Data: field to work around a bug in iasl parser.
Nice addition; I tend to forget adding console= on the cmdline :).
Has a bug report been filed (or does one already exist) at ACPICA? I can do that if it hasn't been done already; it's just when the OEM Data field is missing, yeah?
The compiler cannot handle an optional field that also happens to be the last field as far as I can see. I did not realise acpica had a bugzilla.
Graeme
No worries; it's not like they broadcast that fact :). Do you want me to file the bug, or do you have time?
On 16 April 2015 at 20:13, Al Stone al.stone@linaro.org wrote:
On 04/16/2015 12:51 PM, G Gregory wrote:
On 16 April 2015 at 19:04, Al Stone al.stone@linaro.org wrote:
On 04/16/2015 05:28 AM, Graeme Gregory wrote:
These tables allow console initialisation for an OS without adding specific arguments to the cmdline for linux or other methods on Windows
DBG2 table needs a dummy OEM Data: field to work around a bug in iasl parser.
Nice addition; I tend to forget adding console= on the cmdline :).
Has a bug report been filed (or does one already exist) at ACPICA? I can do that if it hasn't been done already; it's just when the OEM Data field is missing, yeah?
The compiler cannot handle an optional field that also happens to be the last field as far as I can see. I did not realise acpica had a bugzilla.
Graeme
No worries; it's not like they broadcast that fact :). Do you want me to file the bug, or do you have time?
Ill try and get round to it because I should be able to remember the code lines where it goes wrong.
Graeme
These tables allow console initialisation for an OS without adding specific arguments to the cmdline for linux or other methods on Windows
DBG2 table needs a dummy OEM Data: field to work around a bug in iasl parser.
Cc: Leif Lindholm leif.lindholm@linaro.org Cc: Olivier Martin olivier.martin@arm.com Signed-off-by: Graeme Gregory graeme.gregory@linaro.org --- .../ArmJunoPkg/AcpiTables/AcpiTables.inf | 2 + ArmPlatformPkg/ArmJunoPkg/AcpiTables/Dbg2.asl | 72 +++++++++++++++++++++ ArmPlatformPkg/ArmJunoPkg/AcpiTables/Spcr.asl | 73 ++++++++++++++++++++++ 3 files changed, 147 insertions(+) create mode 100644 ArmPlatformPkg/ArmJunoPkg/AcpiTables/Dbg2.asl create mode 100644 ArmPlatformPkg/ArmJunoPkg/AcpiTables/Spcr.asl
diff --git a/ArmPlatformPkg/ArmJunoPkg/AcpiTables/AcpiTables.inf b/ArmPlatformPkg/ArmJunoPkg/AcpiTables/AcpiTables.inf index 76a0d0a..a42fdfd 100644 --- a/ArmPlatformPkg/ArmJunoPkg/AcpiTables/AcpiTables.inf +++ b/ArmPlatformPkg/ArmJunoPkg/AcpiTables/AcpiTables.inf @@ -23,6 +23,8 @@
[Sources] Dsdt.asl + Dbg2.asl + Spcr.asl Facs.aslc Fadt.aslc Gtdt.aslc diff --git a/ArmPlatformPkg/ArmJunoPkg/AcpiTables/Dbg2.asl b/ArmPlatformPkg/ArmJunoPkg/AcpiTables/Dbg2.asl new file mode 100644 index 0000000..f57fa7e --- /dev/null +++ b/ArmPlatformPkg/ArmJunoPkg/AcpiTables/Dbg2.asl @@ -0,0 +1,72 @@ +/* + * Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED + * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * + * NB: This License is also known as the "BSD 2-Clause License". + * + * + * [DBG2] ACPI Table + * + */ + +[0004] Signature : "DBG2" [Debug Port table type 2] +[0004] Table Length : 0000005A +[0001] Revision : 00 +[0001] Checksum : 06 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "ARM-JUNO" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926 + +[0004] Info Offset : 0000002C +[0004] Info Count : 00000001 + +[0001] Revision : 00 +[0002] Length : 002C +[0001] Register Count : 01 +[0002] Namepath Length : 0005 +[0002] Namepath Offset : 0026 +[0002] OEM Data Length : 0000 [Optional field not present] +[0002] OEM Data Offset : 0000 [Optional field not present] +[0002] Port Type : 8000 +[0002] Port Subtype : 0003 +[0002] Reserved : 0000 +[0002] Base Address Offset : 0016 +[0002] Address Size Offset : 0022 + +[000C] Base Address Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000007FF80000 + +[0004] Address Size : 00001000 + +[0004] Namepath : "COM1" +[0001] OEM Data : 00 diff --git a/ArmPlatformPkg/ArmJunoPkg/AcpiTables/Spcr.asl b/ArmPlatformPkg/ArmJunoPkg/AcpiTables/Spcr.asl new file mode 100644 index 0000000..2b65326 --- /dev/null +++ b/ArmPlatformPkg/ArmJunoPkg/AcpiTables/Spcr.asl @@ -0,0 +1,73 @@ +/* + * Copyright (c) 2015, Graeme Gregory graeme.gregory@linaro.org + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED + * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * + * NB: This License is also known as the "BSD 2-Clause License". + * + * + * [SPCR] ACPI Table + * + */ + +[0004] Signature : "SPCR" [Serial Port Console Redirection table] +[0004] Table Length : 00000050 +[0001] Revision : 02 +[0001] Checksum : 29 +[0006] Oem ID : "LINARO" +[0008] Oem Table ID : "ARM-JUNO" +[0004] Oem Revision : 00000000 +[0004] Asl Compiler ID : "INTL" +[0004] Asl Compiler Revision : 20140926 + +[0001] Interface Type : 03 +[0003] Reserved : 000000 + +[000C] Serial Port Register : [Generic Address Structure] +[0001] Space ID : 00 [SystemMemory] +[0001] Bit Width : 20 +[0001] Bit Offset : 00 +[0001] Encoded Access Width : 03 [DWord Access:32] +[0008] Address : 000000007FF80000 + +[0001] Interrupt Type : 08 +[0001] PCAT-compatible IRQ : 00 +[0004] Interrupt : 00000073 +[0001] Baud Rate : 07 +[0001] Parity : 00 +[0001] Stop Bits : 01 +[0001] Flow Control : 00 +[0001] Terminal Type : 03 +[0001] Reserved : 00 +[0002] PCI Device ID : FFFF +[0002] PCI Vendor ID : FFFF +[0001] PCI Bus : 00 +[0001] PCI Device : 00 +[0001] PCI Function : 00 +[0004] PCI Flags : 00000000 +[04Bh] PCI Segment : 00 +[04Ch] Reserved : 00000000 +