public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Pete Batard" <pete@akeo.ie>
To: devel@edk2.groups.io
Cc: ard.biesheuvel@linaro.org, leif.lindholm@linaro.org, philmd@redhat.com
Subject: [edk2-platforms][PATCH 0/6] Platform/RPi4: ACPI improvements
Date: Wed, 18 Dec 2019 11:41:50 +0000	[thread overview]
Message-ID: <20191218114156.9036-1-pete@akeo.ie> (raw)

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


             reply	other threads:[~2019-12-18 11:42 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-18 11:41 Pete Batard [this message]
2019-12-18 11:41 ` [edk2-platforms][PATCH 1/6] Platform/RPi4: Clean up ACPI definitions Pete Batard
2019-12-18 11:41 ` [edk2-platforms][PATCH 2/6] Platform/RPi4: Improve FADT ACPI table generation Pete Batard
2019-12-18 14:46   ` Ard Biesheuvel
2019-12-18 16:31     ` Pete Batard
2019-12-18 11:41 ` [edk2-platforms][PATCH 3/6] Platform/RPi4: Improve SPCR and DBG2 " Pete Batard
2019-12-18 15:57   ` Philippe Mathieu-Daudé
2019-12-18 16:36     ` Pete Batard
2019-12-18 17:00       ` Philippe Mathieu-Daudé
2019-12-18 17:10         ` Pete Batard
2019-12-18 11:41 ` [edk2-platforms][PATCH 4/6] Platform/RPi4: Add switch to select between PL011 and miniUART Pete Batard
2019-12-18 16:05   ` Philippe Mathieu-Daudé
2019-12-18 16:59     ` [edk2-devel] " Pete Batard
2019-12-18 17:05       ` Philippe Mathieu-Daudé
2019-12-18 11:41 ` [edk2-platforms][PATCH 5/6] Platform/RPi4: Add XHCI and MCFG ACPI tables Pete Batard
2019-12-18 14:55   ` Ard Biesheuvel
2019-12-18 16:31     ` Pete Batard
2019-12-18 11:41 ` [edk2-platforms][PATCH 6/6] Platform/RPi4: Add ACPI basic mode build option Pete Batard
2019-12-18 12:10   ` Leif Lindholm

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191218114156.9036-1-pete@akeo.ie \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox