From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pg1-f178.google.com (mail-pg1-f178.google.com [209.85.215.178]) by mx.groups.io with SMTP id smtpd.web11.6715.1687255370514045221 for ; Tue, 20 Jun 2023 03:02:50 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@ventanamicro.com header.s=google header.b=EVNScokM; spf=pass (domain: ventanamicro.com, ip: 209.85.215.178, mailfrom: sunilvl@ventanamicro.com) Received: by mail-pg1-f178.google.com with SMTP id 41be03b00d2f7-517ab9a4a13so3510036a12.1 for ; Tue, 20 Jun 2023 03:02:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ventanamicro.com; s=google; t=1687255370; x=1689847370; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=54T1EphykB2shCxD1r/9haSNenTQaH0rAPjW/5hVdcI=; b=EVNScokMhGaU+ZiUtvCZlf9j5uJAirsegbuM5iTmL1ogfUn3T3iIJDW5r6TO9LfAQ5 VpscJXyOMfnRVj+ZCJMxvee/p/+rNO42J5sGhdhLuaQVbAJMSnDekpXbgLJp/2osxAeW xJ+kEnr3rdVEzWekA4gztkbDWlCS4ao4LmhBge2A6CxMgazDiqnYqfUX2uK2opbybWs6 bJJ8WnjwL2q8txcUuzdhZqFq9swMwbgY8tr68VILv3AZvcSiqyHfJn5lGJMjs1l/GgtG SVEXuUAvL4dfVbkbFwwVGlxu0Vikp0cUIbIc0RNKYFc/vEGnNImPgM5wfY6VCEA3R+mJ JPeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687255370; x=1689847370; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=54T1EphykB2shCxD1r/9haSNenTQaH0rAPjW/5hVdcI=; b=QnVfrCenOESzno7+j5eB2gJYDRR5SW41P0FWBNLq2++mKPtp8voTauVrbW316XCmOv Y0Vg2TnkB2Uv2kroeVCMsMi9ayqpoQrHY16JbyS6nEuB81ajKGZMMpmOBc7Rz/S0nPLw 7ARZDV7/DCRGXs9+KSJeo52+1EunmGsQQiGTOT9J586Rr3+BZY0Gst/YZw9ytZcvtpTK CM3A5oXvY8Mmr15J7POoOHehjdzYOrDIGd/W6IjHHNiYXZj0dtc5yxsUFnzHoAD8jkgd VW7hXhhJwZW9UPgPFQvOZ15tzIjAV1rU6N61qaRPF2C9XqAwMOOHNzQ4YeSpzeLC6d/b 4S7w== X-Gm-Message-State: AC+VfDw5Nsiyjj2dGUDOlbXLc46JCnyQ/N1eof7YYqyMAD4aqj2urdOC aaq8q3ByIDKUFsKYOUUH6niHg56vw1jSoxjicmg= X-Google-Smtp-Source: ACHHUZ6+jfRlB35iULqzusb2xJI95wsHh666zxHHgjBPBDUEYakkRJxiB60eq0JEaQPqlffcrH9KxQ== X-Received: by 2002:a05:6a21:339a:b0:122:450b:48aa with SMTP id yy26-20020a056a21339a00b00122450b48aamr2721990pzb.21.1687255369747; Tue, 20 Jun 2023 03:02:49 -0700 (PDT) Return-Path: Received: from kerodi.Dlink ([106.51.184.72]) by smtp.gmail.com with ESMTPSA id v14-20020aa7808e000000b00666b3b04758sm1033433pff.37.2023.06.20.03.02.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Jun 2023 03:02:49 -0700 (PDT) From: "Sunil V L" To: devel@edk2.groups.io Cc: Sunil V L , Ard Biesheuvel , Jiewen Yao , Jordan Justen , Gerd Hoffmann , Andrei Warkentin , Heinrich Schuchardt , Dann Frazier Subject: [PATCH v3 0/4] OvmfPkg/RiscVVirt: Separate code and variable storage Date: Tue, 20 Jun 2023 15:32:40 +0530 Message-Id: <20230620100244.1404606-1-sunilvl@ventanamicro.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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. 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 Cc: Ard Biesheuvel Cc: Jiewen Yao Cc: Jordan Justen Cc: Gerd Hoffmann Cc: Andrei Warkentin Cc: Heinrich Schuchardt Cc: Dann Frazier Changes since v2: 1) Addressed Heinrich's comments in readme. Changes since v1: 1) Updated readme to add minimum qemu version required. 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 | 16 +- .../VirtNorFlashDeviceTreeLib.inf | 40 +++++ .../VirtNorFlashDeviceTreeLib.c | 137 ++++++++++++++++++ OvmfPkg/RiscVVirt/README.md | 49 +++++++ OvmfPkg/RiscVVirt/RiscVVirt.fdf.inc | 14 +- OvmfPkg/RiscVVirt/VarStore.fdf.inc | 12 +- 7 files changed, 251 insertions(+), 19 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