From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f65.google.com (mail-wm1-f65.google.com [209.85.128.65]) by mx.groups.io with SMTP id smtpd.web10.5256.1576078561955555342 for ; Wed, 11 Dec 2019 07:36:02 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@akeo-ie.20150623.gappssmtp.com header.s=20150623 header.b=aMUlXqeh; spf=none, err=permanent DNS error (domain: akeo.ie, ip: 209.85.128.65, mailfrom: pete@akeo.ie) Received: by mail-wm1-f65.google.com with SMTP id t14so7423443wmi.5 for ; Wed, 11 Dec 2019 07:36:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=akeo-ie.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=2s6uL2I0b9iHnw9yGKNINwAHU+OqLyz1NggyFNGfE4E=; b=aMUlXqehyMrKWaVa1JGDGlzXgRftDFz1j+6Ydss6N/q63AUvB6nn6e4769ofE9WleE 2RWdW7mweqZcVfPX841nrCY4OS4Sk7+/bRk97AAsyV2qlvJqnPmD3V08zbBCdGqt6rmn WEZF2DQzhoO14fMFSvjCESCjQCDjOwl/lvlloG016wu80HN6CRhAhHgnP7nYp57uBy3e LVNxZUprvrUyfu04Lf3wmOHHlK0ghuhj0zmucpnwjpWxIre40tEDQXaP/uw+nQddfY7c pK1enLOnH2gCGn3Kz4HJptGNF6dO1J6eGcYPLFSpexPdAi/uxUrp1UJ3IjUa9quCGv07 TGAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=2s6uL2I0b9iHnw9yGKNINwAHU+OqLyz1NggyFNGfE4E=; b=SXMIU9bBFUXRDEXYovoV+NUZNahe00e0lVCX6j9ZCLxeDBwSJC4kp0Qj6dm0K/CzK5 Gd3eZF7Pwy1MgSAA/R1rGCvmVQI2LYMbEAhtCoDedFq/VG6KoFb9EEKmjGb53RI0XIks jUjnxkyHcHzi3rxmV4ww9406Q4N2cEaUs7QsSB9TH5NOEQWXudNDkSBjILrs3BtEv7CF q5B2L3U7Z0aX+t1l4oq3k/ElAjjzwSMU9AeqqgPLty0UzMG2lclM6RzV47oN4BuBSxtu amn8R9l6zyFcHjJ3s0HiwrI6P7DIkln6WMr2oQeleahRWHL2JVHc6DV/0sPT5A/d3gbo Qpgg== X-Gm-Message-State: APjAAAVaiKItRazR4R+9KlmoQdeDdrh9oazYG/zQvHod/W85tPSB+uqi 7sgdTQbslJ3+LSBMy02dburIvg== X-Google-Smtp-Source: APXvYqx13NhArCkWaPOo00nRDUgWdN+FZ9zm5r5/By/vlLS3zX38Lwnz4tZ0kyS1rYRWRXuOmNx2sw== X-Received: by 2002:a7b:cb0a:: with SMTP id u10mr475228wmj.104.1576078560426; Wed, 11 Dec 2019 07:36:00 -0800 (PST) Return-Path: Received: from [10.0.0.122] ([84.203.45.230]) by smtp.googlemail.com with ESMTPSA id c15sm2548344wrt.1.2019.12.11.07.35.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 11 Dec 2019 07:35:59 -0800 (PST) Subject: Re: [edk2-non-osi][PATCH 2/2] Platforms/RPi4: Add Trusted Firmware binaries To: Leif Lindholm Cc: devel@edk2.groups.io, ard.biesheuvel@linaro.org, philmd@redhat.com References: <20191211112400.1872-1-pete@akeo.ie> <20191211112400.1872-3-pete@akeo.ie> <20191211141443.GB7359@bivouac.eciton.net> From: "Pete Batard" Message-ID: Date: Wed, 11 Dec 2019 15:35:58 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.9.1 MIME-Version: 1.0 In-Reply-To: <20191211141443.GB7359@bivouac.eciton.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit Hi Leif, On 2019.12.11 14:14, Leif Lindholm wrote: > On Wed, Dec 11, 2019 at 11:24:00 +0000, Pete Batard wrote: >> Similar to what is the case with the Raspberry Pi 3, the Raspberry Pi >> 4 UEFI firmware requires the provision of a Trusted Firmware binary >> (TF-A). >> >> The binary is built for a dtb base address of 0x00020000 and a UEFI >> payload base address of 0x00030000. >> >> Binaries are built using a custom version of TF-A (the source of which >> is documented in the Readme), since the official repository is missing >> a fix to get proper baudrate when using a recent version of start4.elf, >> as we as the ability to switch between PL011 and mini UART. We are >> currently working with TF-A to upstream both these fixes so that we can >> switch to binaries built from official source at a later date. >> >> In order to provide the ability to switch serial I/O controllers, a >> feature we will be adding to the RPi4 UEFI Firmware, and not lose TF-A >> output, two binaries are provided, one for mini UART output and one for >> PL011 output. >> >> Signed-off-by: Pete Batard >> --- >> Platform/RaspberryPi/RPi4/TrustedFirmware/License.txt | 26 ++++++++++++++++++++ >> Platform/RaspberryPi/RPi4/TrustedFirmware/Readme.md | 12 +++++++++ >> Platform/RaspberryPi/RPi4/TrustedFirmware/bl31_miniuart.bin | Bin 0 -> 41072 bytes >> Platform/RaspberryPi/RPi4/TrustedFirmware/bl31_pl011.bin | Bin 0 -> 41072 bytes >> 4 files changed, 38 insertions(+) >> > >> new file mode 100644 >> index 000000000000..7f1749dfc3a0 >> --- /dev/null >> +++ b/Platform/RaspberryPi/RPi4/TrustedFirmware/Readme.md >> @@ -0,0 +1,12 @@ >> +ARM Trusted Firmware for Raspberry Pi 4 >> +======================================= >> + >> +The `bl31_#####.bin` TF-A binaries found in this repository were built on a Debian 10.2 system >> +from https://github.com/pbatard/arm-trusted-firmware/tree/pi4 (pi4 branch) using the command: >> + >> +``` >> +make PLAT=rpi4 RPI3_PRELOADED_DTB_BASE=0x20000 PRELOADED_BL33_BASE=0x30000 SUPPORT_VFP=1 [RPI3_USE_PL011_UART=1] DEBUG=0 all >> +``` >> + >> +The only difference between these firmwares is that the `RPI3_USE_PL011_UART=1` option was added >> +to build `bl31_pl011.bin` so that it uses PL011 for serial output rather than the "mini UART". > > Sanity check: do the build commands still use RPI3_ options for rpi4? That's correct. This is an option that's meant to apply to both Pi 3 and Pi 4, and for now, I'm keeping everything in line with the current RPi common options that are still prefixed with RPI3_. There are some vague talks about merging the Pi 3 and Pi 4 TF-A platforms, so maybe we'll drop RPI3_ prefixed options then, but for now, pretty much all of the Pi 4 build options I know of use RPI3_ as a prefix. Regards, /Pete > > Best Regards, > > Leif >