[edk2-devel] [edk2-platforms][PATCH 0/6] Platform/RPi4: ACPI improvements

Pete Batard posted 6 patches 4 years, 4 months ago
Failed in applying to current master (apply log)
There is a newer version of this series
Platform/RaspberryPi/Library/PlatformLib/PlatformLib.inf  |   3 +
Platform/RaspberryPi/Library/PlatformLib/RaspberryPiMem.c |   8 ++
Platform/RaspberryPi/RPi4/AcpiTables/AcpiTables.h         |  12 +-
Platform/RaspberryPi/RPi4/AcpiTables/AcpiTables.inf       |   9 +-
Platform/RaspberryPi/RPi4/AcpiTables/Csrt.aslc            |  42 +++---
Platform/RaspberryPi/RPi4/AcpiTables/Dbg2.aslc            | 110 +++++++++++++--
Platform/RaspberryPi/RPi4/AcpiTables/Dsdt.asl             |   1 +
Platform/RaspberryPi/RPi4/AcpiTables/Fadt.aslc            | 104 +++++++++++----
Platform/RaspberryPi/RPi4/AcpiTables/Gtdt.aslc            |  30 ++---
Platform/RaspberryPi/RPi4/AcpiTables/Madt.aslc            |  11 +-
Platform/RaspberryPi/RPi4/AcpiTables/Mcfg.aslc            |  81 +++++++++++
Platform/RaspberryPi/RPi4/AcpiTables/Pep.asl              |   4 +-
Platform/RaspberryPi/RPi4/AcpiTables/Pep.c                |   6 +-
Platform/RaspberryPi/RPi4/AcpiTables/Pep.h                |   8 +-
Platform/RaspberryPi/RPi4/AcpiTables/Spcr.asl             |  48 -------
Platform/RaspberryPi/RPi4/AcpiTables/Spcr.aslc            | 101 ++++++++++++++
Platform/RaspberryPi/RPi4/AcpiTables/Uart.asl             |   6 +-
Platform/RaspberryPi/RPi4/AcpiTables/Xhci.asl             | 140 ++++++++++++++++++++
Platform/RaspberryPi/RPi4/RPi4.dsc                        |  29 ++++
Platform/RaspberryPi/RPi4/RPi4.fdf                        |   7 +
Platform/RaspberryPi/RPi4/Readme.md                       |  52 ++++++--
Platform/RaspberryPi/RaspberryPi.dec                      |   3 +
22 files changed, 657 insertions(+), 158 deletions(-)
create mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Mcfg.aslc
delete mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Spcr.asl
create mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Spcr.aslc
create mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Xhci.asl
[edk2-devel] [edk2-platforms][PATCH 0/6] Platform/RPi4: ACPI improvements
Posted by Pete Batard 4 years, 4 months ago
This series aims at bringing the Raspberry Pi 4 platform to a state
where its firmware can actually be used with Linux OSes

For instance, we have tested installation of vanilla Debian 10.2 on
a USB 3.0 flash drive with a UEFI firmware built with these patches
and, notwhistanding the lack of NIC or SD support (that have to do
with these drivers not being included/finalized in the current Debian 
kernel), found that the system could be installed and could run
without trouble.

A few caveats are however required to achieve this:
* If using the serial console, the platform UART should be set to
  PL011 rather than miniUART, as the miniUART baudrate is altered
  when the CPU throttles.
* ACPI needs to be enforced over Device Tree, with some additional
  limitations regarding the maximum amount of RAM reported (3 GB
  max) due to DMA.

This series effectively introduces two new build flags (PL011_ENABLE,
ACPI_BASIC_MODE_ENABLE) to deal with the above.

The rest of the series has mostly to do with ACPI improvements to
make the above possible by:
* Harmonizing and cleaning up existing ACPI sources
* Using full aslc code for FADT, SPCR and DBG2
* Adding an XHCI table as well as a dummy MCFG table (the latter
  only being added to suppress a warning from the kernel about
  missing MCFG, since PCIe for that platform is not ECAM compliant)


Andrei Warkentin (1):
  Platform/RPi4: Add XHCI and MCFG ACPI tables

Ard Biesheuvel (1):
  Platform/RPi4: Add ACPI basic mode build option

Pete Batard (4):
  Platform/RPi4: Clean up ACPI definitions
  Platform/RPi4: Improve FADT ACPI table generation
  Platform/RPi4: Improve SPCR and DBG2 ACPI table generation
  Platform/RPi4: Add switch to select between PL011 and miniUART

 Platform/RaspberryPi/Library/PlatformLib/PlatformLib.inf  |   3 +
 Platform/RaspberryPi/Library/PlatformLib/RaspberryPiMem.c |   8 ++
 Platform/RaspberryPi/RPi4/AcpiTables/AcpiTables.h         |  12 +-
 Platform/RaspberryPi/RPi4/AcpiTables/AcpiTables.inf       |   9 +-
 Platform/RaspberryPi/RPi4/AcpiTables/Csrt.aslc            |  42 +++---
 Platform/RaspberryPi/RPi4/AcpiTables/Dbg2.aslc            | 110 +++++++++++++--
 Platform/RaspberryPi/RPi4/AcpiTables/Dsdt.asl             |   1 +
 Platform/RaspberryPi/RPi4/AcpiTables/Fadt.aslc            | 104 +++++++++++----
 Platform/RaspberryPi/RPi4/AcpiTables/Gtdt.aslc            |  30 ++---
 Platform/RaspberryPi/RPi4/AcpiTables/Madt.aslc            |  11 +-
 Platform/RaspberryPi/RPi4/AcpiTables/Mcfg.aslc            |  81 +++++++++++
 Platform/RaspberryPi/RPi4/AcpiTables/Pep.asl              |   4 +-
 Platform/RaspberryPi/RPi4/AcpiTables/Pep.c                |   6 +-
 Platform/RaspberryPi/RPi4/AcpiTables/Pep.h                |   8 +-
 Platform/RaspberryPi/RPi4/AcpiTables/Spcr.asl             |  48 -------
 Platform/RaspberryPi/RPi4/AcpiTables/Spcr.aslc            | 101 ++++++++++++++
 Platform/RaspberryPi/RPi4/AcpiTables/Uart.asl             |   6 +-
 Platform/RaspberryPi/RPi4/AcpiTables/Xhci.asl             | 140 ++++++++++++++++++++
 Platform/RaspberryPi/RPi4/RPi4.dsc                        |  29 ++++
 Platform/RaspberryPi/RPi4/RPi4.fdf                        |   7 +
 Platform/RaspberryPi/RPi4/Readme.md                       |  52 ++++++--
 Platform/RaspberryPi/RaspberryPi.dec                      |   3 +
 22 files changed, 657 insertions(+), 158 deletions(-)
 create mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Mcfg.aslc
 delete mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Spcr.asl
 create mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Spcr.aslc
 create mode 100644 Platform/RaspberryPi/RPi4/AcpiTables/Xhci.asl

-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#52342): https://edk2.groups.io/g/devel/message/52342
Mute This Topic: https://groups.io/mt/68791809/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-