From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp-relay-internal-1.canonical.com (smtp-relay-internal-1.canonical.com [185.125.188.123]) by mx.groups.io with SMTP id smtpd.web10.18422.1686762695699464082 for ; Wed, 14 Jun 2023 10:11:36 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@canonical.com header.s=20210705 header.b=SEDRdM+Z; spf=pass (domain: canonical.com, ip: 185.125.188.123, mailfrom: heinrich.schuchardt@canonical.com) Received: from mail-lf1-f69.google.com (mail-lf1-f69.google.com [209.85.167.69]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-1.canonical.com (Postfix) with ESMTPS id 3D4923F171 for ; Wed, 14 Jun 2023 17:11:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1686762692; bh=ghTl4Goyt2KWXxh+jMSgFggLYZ7bD8DwAoV7a5Y0PXo=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=SEDRdM+Z8NtR7Y0LiMiNXRc4QDP09oSgRi58quJvoAG32MbmVMowDvisIbGCUOdkF l3QrWCHI0c2dfGdgVM+e0CnFn6U47WIP9GWLdpMLRXsGTU+XfGXB/dKoopR+9CE9/L skNITNLTeTMBjk31DB1fTsnVPkRmXhvPD7SQMoztOJ66gVyxsuiBP7MA5dfuX+rSfx xHRuGOpBsew/4pO5APFWWmftJcbzy4XPq85qNvIzcyt43Vf7+hyvEmoq60/YRcDjoL fhYoM+DEUHx2u8tKJ9RWU34bnnnoAkLR2iwXG/iZtZDM9KXF6CcuZc5V0xxs6UkyxF sr7CJ5eyFm4vA== Received: by mail-lf1-f69.google.com with SMTP id 2adb3069b0e04-4f76712f950so845239e87.0 for ; Wed, 14 Jun 2023 10:11:32 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686762690; x=1689354690; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ghTl4Goyt2KWXxh+jMSgFggLYZ7bD8DwAoV7a5Y0PXo=; b=Rwqma9a4YV4jOzNorJ7FW712b9v2ClCBPxLQX78dyeI5zBKZXZEcTTtXqntfZNyae/ Vti3E6Spq+2PUMW6CdR5TZ8Zf9dDXnV8Kvp4xtlfrcIsorjmyMp6yVq5ZrfDeeeltgVa KdiuRpYShDWLSWstzBKtPDRFsz3iwAMBYjUiSfIVQcCUH1ZDOflUmH5LgD4mhyMDWk5w j0ovqowGt+XY2dcMKrLMJSNlqsi9CnKUeNdDAxhFRY8NLOJ8bSxqcjP1rsF+n0hCrO0f Zfnhcw6kWiIIAkLaur27kHV4ka4rbtQarFkDIENGLwtn4acdFCqMaZNed/cSTda/HbTb R0uw== X-Gm-Message-State: AC+VfDymbi6FNgPVofevirb/0zkKlT8jtyh79IShFoGppNUQbXcHSaUH GpKTS2tbuFAO9aS2LdQXcksLU0C6R9W/ITF0GCPpGQuz2Lbruw9Oj4NJ2pr8JbczRs0a4gLviA2 4NCeuVt031kUZTTMWNfMKLXRa/YxRXg6jeIHRBZiHI/UkxZM= X-Received: by 2002:ac2:5f91:0:b0:4f7:6363:e64 with SMTP id r17-20020ac25f91000000b004f763630e64mr2156542lfe.38.1686762690004; Wed, 14 Jun 2023 10:11:30 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ49HX1m3YwEUBaGUMxeyT32Pykk972gJyaLusBsWFHzqt15CXhqWT4IABM8JkYmFvCow1GzQrANIlXZ2VJw7bY= X-Received: by 2002:ac2:5f91:0:b0:4f7:6363:e64 with SMTP id r17-20020ac25f91000000b004f763630e64mr2156511lfe.38.1686762689511; Wed, 14 Jun 2023 10:11:29 -0700 (PDT) MIME-Version: 1.0 References: <20230614170151.1204982-1-sunilvl@ventanamicro.com> In-Reply-To: <20230614170151.1204982-1-sunilvl@ventanamicro.com> From: Heinrich Schuchardt Date: Wed, 14 Jun 2023 19:11:18 +0200 Message-ID: Subject: Re: [PATCH 0/4] OvmfPkg/RiscVVirt: Separate code and variable storage To: Sunil V L Cc: devel@edk2.groups.io, Ard Biesheuvel , Jiewen Yao , Jordan Justen , Gerd Hoffmann , Andrei Warkentin , Dann Frazier Content-Type: multipart/alternative; boundary="000000000000edde7905fe1a0a56" --000000000000edde7905fe1a0a56 Content-Type: text/plain; charset="UTF-8" Sunil V L schrieb am Mi., 14. Juni 2023, 19:01: > Recent updates to RISC-V qemu virt platform merged today (07/14), > have enabled both pflash devices for the S-mode payload like EDK2. > These updates also aligned the design similar to other architectures > where pflash0 is for read-only code and pflash1 for variable store. > Previously only pflash1 was available for S-mode use. > > Current EDK2 will not work with this latest qemu changes since it always > assumed to boot from pflash1. So, separate the code and variable > store and use pflash0 to keep the code. > Not all users will have the newest QEMU provided by their Linx distro. Will it be possible to boot the the same EDK II binary on old and new QEMU releases? Best regards Heinrich > Add 'readme' about build and test as per these changes. > > The changes are available in the branch : > https://github.com/vlsunil/edk2/tree/separate_code_vars > > CI tests passed (#4553). > > Cc: Ard Biesheuvel > Cc: Jiewen Yao > Cc: Jordan Justen > Cc: Gerd Hoffmann > Cc: Andrei Warkentin > Cc: Heinrich Schuchardt > Cc: Dann Frazier > > > Sunil V L (4): > OvmfPkg/RiscVVirt: Fix couple of issues in VarStore > OvmfPkg/RiscVVirt: Add VirtNorFlashDeviceTreeLib library > OvmfPkg/RiscVVirt: Add support for separate code and variable store > OvmfPkg/RiscVVirt: Add a readme for build and test > > OvmfPkg/RiscVVirt/RiscVVirtQemu.dsc | 2 +- > OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf | 9 +- > .../VirtNorFlashDeviceTreeLib.inf | 40 +++++ > .../VirtNorFlashDeviceTreeLib.c | 137 ++++++++++++++++++ > OvmfPkg/RiscVVirt/README.md | 41 ++++++ > OvmfPkg/RiscVVirt/RiscVVirt.fdf.inc | 12 +- > OvmfPkg/RiscVVirt/VarStore.fdf.inc | 25 ++-- > 7 files changed, 245 insertions(+), 21 deletions(-) > create mode 100644 > OvmfPkg/RiscVVirt/Library/VirtNorFlashPlatformLib/VirtNorFlashDeviceTreeLib.inf > create mode 100644 > OvmfPkg/RiscVVirt/Library/VirtNorFlashPlatformLib/VirtNorFlashDeviceTreeLib.c > create mode 100644 OvmfPkg/RiscVVirt/README.md > > -- > 2.34.1 > > --000000000000edde7905fe1a0a56 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


Sunil V L <sunilvl@ventanamicro.com> schrieb am Mi., 14. Juni 2023, 19:01:<= br>
Recent updates to RISC-V qemu virt = platform merged today (07/14),
have enabled both pflash devices for the S-mode payload like EDK2.
These updates also aligned the design similar to other architectures
where pflash0 is for read-only code and pflash1 for variable store.
Previously only pflash1 was available for S-mode use.

Current EDK2 will not work with this latest qemu changes since it always assumed to boot from pflash1. So, separate the code and variable
store and use pflash0 to keep the code.

Not all users will have the newest Q= EMU provided by their Linx distro. Will it be possible to boot the the same= EDK II binary on old and new QEMU releases?

Best regards

Heinrich


Add 'readme' about build and test as per these changes.

The changes are available in the branch :
https://github.com/vlsunil/edk2/tr= ee/separate_code_vars

CI tests passed (#4553).

Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Gerd Hoffmann <kraxel@redhat.com>
Cc: Andrei Warkentin <andrei.warkentin@intel.com>
Cc: Heinrich Schuchardt <heinrich.schuchardt@canonical.co= m>
Cc: Dann Frazier <dann.frazier@canonical.com>


Sunil V L (4):
=C2=A0 OvmfPkg/RiscVVirt: Fix couple of issues in VarStore
=C2=A0 OvmfPkg/RiscVVirt: Add VirtNorFlashDeviceTreeLib library
=C2=A0 OvmfPkg/RiscVVirt: Add support for separate code and variable store<= br> =C2=A0 OvmfPkg/RiscVVirt: Add a readme for build and test

=C2=A0OvmfPkg/RiscVVirt/RiscVVirtQemu.dsc=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0= =C2=A0|=C2=A0 =C2=A02 +-
=C2=A0OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0= =C2=A0|=C2=A0 =C2=A09 +-
=C2=A0.../VirtNorFlashDeviceTreeLib.inf=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0|=C2=A0 40 +++++
=C2=A0.../VirtNorFlashDeviceTreeLib.c=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0| 137 ++++++++++++++++++
=C2=A0OvmfPkg/RiscVVirt/README.md=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0|=C2=A0 41 ++++++
=C2=A0OvmfPkg/RiscVVirt/RiscVVirt.fdf.inc=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0= =C2=A0|=C2=A0 12 +-
=C2=A0OvmfPkg/RiscVVirt/VarStore.fdf.inc=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 |=C2=A0 25 ++--
=C2=A07 files changed, 245 insertions(+), 21 deletions(-)
=C2=A0create mode 100644 OvmfPkg/RiscVVirt/Library/VirtNorFlashPlatformLib/= VirtNorFlashDeviceTreeLib.inf
=C2=A0create mode 100644 OvmfPkg/RiscVVirt/Library/VirtNorFlashPlatformLib/= VirtNorFlashDeviceTreeLib.c
=C2=A0create mode 100644 OvmfPkg/RiscVVirt/README.md

--
2.34.1

--000000000000edde7905fe1a0a56--