From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-qk1-f196.google.com (mail-qk1-f196.google.com [209.85.222.196]) by mx.groups.io with SMTP id smtpd.web10.3783.1588238828000026251 for ; Thu, 30 Apr 2020 02:27:08 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20161025 header.b=F2zuPg3p; spf=pass (domain: gmail.com, ip: 209.85.222.196, mailfrom: andrey.warkentin@gmail.com) Received: by mail-qk1-f196.google.com with SMTP id t3so5003668qkg.1 for ; Thu, 30 Apr 2020 02:27:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=FtdnrlHdGfkS2bH4Bj1vQlzHoxzrK0dmbmwS5AklMEg=; b=F2zuPg3ps3oxnwJ5nO5Eog3fFuvrhM5e9g2nMqkeNyonIUv/cXEU/mAThnDRxC1Hcq 9FWFaO3u9PWGD/KodPL8JOkuJRooh+CjXpoPnOP79v60oBfwrf7W0StBXEjkak2CMUZy wrhqgcTKB+IpN32NSJhYmMBX5KvNLHfJ+QpynFX26L7aeYIMRE40JLEIe10IiXRbsbV5 /oTdl1V42aOdt4WtD4Vd3lrrJKiK1jaK8XQRdIWQeDz/7JC2KBXAFZrBccLOrZNysHMS rlT1fn43vUuoT1id6Y5HeUWUA/HvluWVUq/CyCS9p3p9yH0+Q5jyvObJ63CbCHhhu4fi 58eg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=FtdnrlHdGfkS2bH4Bj1vQlzHoxzrK0dmbmwS5AklMEg=; b=b7t4rXpoMKSPgySDM/all4p1gh/EpuIHBVvg9owDvq9dLLP8Ny5Occ8C879nPF8am5 nV7tnaVNUrGUZTBG8pKOgcGuLYQu4+7531Y2T5j73OJA1RUcqBPM3fsCSHLRyoqvyLq7 vCVeMCYkedTlyG+iyyXi9NqgpKK8L6+DYXqlUd3K/6Amkhh+z/jidK4gpPjI90C+dtfZ kd/6+uB90hsqpOx6IUfUJyGj9NbpWrz1uTmy1D9NZmToIrFR4ZStvvxDoWQwomzxG1AW EEgv3PXfDDRXu9D5AY6NXKD5Jsm7Frwlbl7sMdHlL6p7Svkt1H/epT/kh7muEWKXGGbU Tdtg== X-Gm-Message-State: AGi0Pua1v2yZTjEGd4P3+T0Qp6ZseERMo9vU3gNnS5PrO9wJ+bRX/CsS y2koxNXTPoUP7qpumbm0CjqNGmxCOEA= X-Google-Smtp-Source: APiQypJGopGYKUd5dBM/fj6zAMxtXtxZcIAcVoHqCiN8Sgz+dOhBQ2sYQUUZ5GK9wIfY7VRgPcRzGg== X-Received: by 2002:a05:620a:556:: with SMTP id o22mr2719943qko.166.1588238826789; Thu, 30 Apr 2020 02:27:06 -0700 (PDT) Return-Path: Received: from localhost.localdomain (c-98-214-99-181.hsd1.il.comcast.net. [98.214.99.181]) by smtp.gmail.com with ESMTPSA id i5sm1430355qki.42.2020.04.30.02.27.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 Apr 2020 02:27:06 -0700 (PDT) From: "Andrei Warkentin" To: devel@edk2.groups.io Cc: ard.biesheuvel@arm.com, leif@nuviainc.com, pete@akeo.ie, philmd@redhat.com Subject: [edk2-platforms][PATCH 4/4] RPi: document CM3, Pi 2B (v1.2) and Pi 3A+ support, update Pi 4 docs Date: Thu, 30 Apr 2020 02:26:52 -0700 Message-Id: <20200430092652.54526-5-andrey.warkentin@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200430092652.54526-1-andrey.warkentin@gmail.com> References: <20200430092652.54526-1-andrey.warkentin@gmail.com> This cleans up the (related) Readme.md files for both platforms. - The RPi3 target also supports the 3A+, so let's document it. (The 3A+ lacks the ethernet port and has less RAM) - Clarify RPi3 is for BCM2837-based variants, while RPi4 is for the BCM2711-based variants. - v1.2 (not older) actually uses the same BCM2837 SoC as Pi 3, and is thus a 64-bit device that this firmware easily supports as a minor variant of the Pi 3. The difference from Pi 3 is choice of UART (PL011), no WiFi, no BT and slower clock due to thermal problems caused by older board design. Signed-off-by: Andrei Warkentin --- Platform/RaspberryPi/RPi3/Readme.md | 49 +++++++++++++------- Platform/RaspberryPi/RPi4/Readme.md | 35 ++++++++++++-- 2 files changed, 65 insertions(+), 19 deletions(-) diff --git a/Platform/RaspberryPi/RPi3/Readme.md b/Platform/RaspberryPi/RPi3/Readme.md index 05f498ee..55c6265d 100644 --- a/Platform/RaspberryPi/RPi3/Readme.md +++ b/Platform/RaspberryPi/RPi3/Readme.md @@ -1,19 +1,33 @@ -Raspberry Pi Platform -===================== +Raspberry Pi 3 Platform +======================= # Summary -This is a port of 64-bit Tiano Core UEFI firmware for the Raspberry Pi 3/3B+ platforms, -based on [Ard Bisheuvel's 64-bit](http://www.workofard.com/2017/02/uefi-on-the-pi/) +This is a port of 64-bit Tiano Core UEFI firmware for the Raspberry Pi 3B (and related) +platforms, based on [Ard Bisheuvel's 64-bit](http://www.workofard.com/2017/02/uefi-on-the-pi/) and [Microsoft's 32-bit](https://github.com/ms-iot/RPi-UEFI/tree/ms-iot/Pi3BoardPkg) implementations, as maintained by [Andrei Warkentin](https://github.com/andreiw/RaspberryPiPkg). -This is meant as a generally useful 64-bit ATF + UEFI implementation for the Raspberry -Pi 3/3B+ which should be good enough for most kind of UEFI development, as well as for -running consummer Operating Systems in such as Linux or Windows. +This is meant as a generally useful 64-bit ATF + UEFI implementation for Raspberry Pi +variants based on the BCM2837 SoC, which should be good enough for most kind of UEFI development, +as well as for running consummer Operating Systems in such as Linux, Windows or the BSDs. Raspberry Pi is a trademark of the [Raspberry Pi Foundation](http://www.raspberrypi.org). +# Hardware Supported + +The RPi3 target supports Pi revisions based on the BCM2837 SoC: +- Raspberry Pi 2B v1.2 (older versions are *not* compatible) +- Raspberry Pi 3A+ +- Raspberry Pi 3B +- Raspberry Pi 3B+ +- Raspberry Pi CM3 + +Note: a CM3L, lacking eMMC and thus similar to the 3B, will probably work as well, but just +has not been tested. + +Please see the RPi4 target for BCM2711-based variants, such as the Raspberry Pi 4B. + # Status This firmware, that has been validated to compile against the current @@ -138,27 +152,28 @@ This should allow you to set whatever date/time you want using the Shell date an time commands. While in UEFI or HLOS, the time will tick forward. `RtcEpochSeconds` is not updated on reboots. -## uSD +## uSD (and eMMC for CM3) -UEFI supports both the Arasan SDHCI and the Broadcom SDHost controllers to access the uSD slot. -You can use either. The other controller gets routed to the SDIO card. The choice made will +UEFI supports both the Arasan SDHCI and the Broadcom SDHost controllers to access the flash +media (eMMC on CM3, and uSD slot on everything else). You can use either. The other controller +gets routed to the SDIO WiFi card (N/A to models without WiFi). The choice made will impact ACPI OSes booted (e.g. Windows 10). Arasan, being an SDIO controller, is usually used -with the WiFi adapter where available. SDHost cannot be used with SDIO. In UEFI setup screen: +with the WiFi adapter (where available). SDHost cannot be used with SDIO. In UEFI setup screen: - go to `Device Manager` - go to `Raspberry Pi Configuration` -- go to `Chipset` -- configure `Boot uSD Routing` +- go to `SD/MMC Configuration` +- configure `uSD/eMMC Routing` Known issues: - Arasan HS/4bit support is missing. -- No 8 bit mode support for (e)MMC (irrelevant for the Pi 3). +- No 8 bit mode support for (e)MMC (slow UEFI file I/O on CM3). - Hacky (e)MMC support (no HS). - No card removal/replacement detection, tons of timeouts and slow down during boot without an uSD card present. ## USB - USB1 BBB mass storage devices untested (USB2 and USB3 devices are fine). -- USB1 CBI mass storage devices don't work (e.g. HP FD-05PUB floppy). +- Some USB1 CBI (e.g. UFI floppy) mass storage devices may not work. ## ACPI @@ -172,4 +187,6 @@ install a kernel that relies on Device Tree rather than ACPI. ## Missing Functionality - Network booting via onboard NIC. -- Ability to switch UART use to PL011. +- SPCR hardcodes UART type to miniUART, and thus will not expose correct + (PL011) UART on CM3 and Pi2B or if DT overlays to switch UART are used + on Pi 3B/3B+/3A+. diff --git a/Platform/RaspberryPi/RPi4/Readme.md b/Platform/RaspberryPi/RPi4/Readme.md index fa9b3146..c1ecfc99 100644 --- a/Platform/RaspberryPi/RPi4/Readme.md +++ b/Platform/RaspberryPi/RPi4/Readme.md @@ -3,14 +3,23 @@ Raspberry Pi 4 Platform # Summary -This is a port of 64-bit Tiano Core UEFI firmware for the Raspberry Pi 4 platforms. +This is a port of 64-bit Tiano Core UEFI firmware for the Raspberry Pi 4B platform. This is intended to be useful 64-bit [TF-A](https://www.trustedfirmware.org/) + -UEFI implementation for the Raspberry Pi 4 which should be good enough for most -kind of UEFI development, as well as for running consummer Operating Systems. +UEFI implementation for the Raspberry Pi variants based on the BCM2711 SoC, +which should be good enough for most kind of UEFI development, as well running consumer +Operating Systems. Raspberry Pi is a trademark of the [Raspberry Pi Foundation](https://www.raspberrypi.org). +# Hardware Supported + +The RPi4 target supports Pi revisions based on the BCM2711 SoC: +- Raspberry Pi 4B + +Please see the RPi3 target for the BCM2837-based variants, such as the Raspberry +Pi 3B. + # Status This firmware is still in development stage, meaning that it comes with the @@ -112,3 +121,23 @@ An `RtcEpochSeconds` NVRAM variable is used to store the boot time. This should allow you to set whatever date/time you want using the Shell date and time commands. While in UEFI or HLOS, the time will tick forward. `RtcEpochSeconds` is not updated on reboots. + +## USB + +This UEFI supports both the USB3 xHCI ports (front ports), and the Pi 3-style +DesignWare USB2 controller via the Type-C port (host only). + +The following only apply to the Type-C port: +- USB1 BBB mass storage devices untested (USB2 and USB3 devices are fine). +- Some USB1 CBI (e.g. UFI floppy) mass storage devices may not work. + +## ACPI + +OS support for ACPI description of Pi-specific devices is still in development. Not +all functionality may be available. + +## Missing Functionality + +- Network booting via onboard NIC. +- SPCR hardcodes type to PL011, and thus will not expose correct + (miniUART) UART if DT overlays to switch UART are used on Pi 4B. \ No newline at end of file -- 2.17.1