From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lf1-f53.google.com (mail-lf1-f53.google.com [209.85.167.53]) by mx.groups.io with SMTP id smtpd.web11.1393.1687987644674455433 for ; Wed, 28 Jun 2023 14:27:25 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="signature has expired" header.i=@ventanamicro.com header.s=google header.b=dtV/ATSY; spf=pass (domain: ventanamicro.com, ip: 209.85.167.53, mailfrom: tphan@ventanamicro.com) Received: by mail-lf1-f53.google.com with SMTP id 2adb3069b0e04-4f96d680399so10124e87.0 for ; Wed, 28 Jun 2023 14:27:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ventanamicro.com; s=google; t=1687987642; x=1690579642; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=ljRK8uSXm9hyN776b7KVoDBvblX0i8iEOgT/9BnQCtI=; b=dtV/ATSYK4cHRS83e6tFoZFD3+dTxLx8MQw06T6ZmjEe/XRSAM341SnVxaTLcMAMey yTNUq9CHmeuHMf6/x1wdyUSDt/0aDwCptgcZ/VBfPXUqQxvJqXTECqxwGDlUP+6xbG6A DD8cK8GGPr8cnIDL78p+bpMWS5r465lvf9F0fj5ZD3+0+C80LK1EEDw7gIJOaryx4bZl X7S+bH6MzjHLvKf0fWKPfiEqjLwYtnuUbIX14FYWWtwA4v0Sp+3DMBFR8HWECmZD1rWY HiFW8DfBHi1hR3m6toC4VqADcgCSMAdlYRFLKjt/tbedyzYLBwbjGwvG7BM4j5sIPyG1 Eopw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687987642; x=1690579642; 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=ljRK8uSXm9hyN776b7KVoDBvblX0i8iEOgT/9BnQCtI=; b=kSPbnRzJjwVoSG2lcRH9MWeE7g9wtrbZgYN3zNhUFmfT2b/KJnnbCtwIpv7iD9k+Hg 5ed/R5kE/3ucOgQOFrf7i3fu7M5XTceievKtAutAuTciHJ9N9NPih+3TA2ZYXF3KtxKj +qIOuIIRZO2Xwr3+jAE9QSxgiU7nAtg+HfPcGKs/Vop0zKJShq4/N0XvTTMpY0qh8ouf BobhAkeCE0uiZtIqK3buTucP4gLyjaDLnUPTzDbVsLMyhioLsAKIIIzzCz7Si0N3mnQY U3qW7iLEtgRmrOgtszQioFey44PX/Gw4itaqIfetb/DcIIC7GLH/n/++Vxv5x//fj7UH +DbA== X-Gm-Message-State: AC+VfDyJh0dah8huGd8BwY+tAVRTJdG6fLvLpTTdkzFG6RiAno4uz8cl tAgukOhke9E4gzRSMeciDLsl5XNYOpcqKpNG9IoE+Q== X-Google-Smtp-Source: ACHHUZ7KAP3CAw6OMtpnU4XbKGaHn1mnAALdyB/6w+z3znbtSwDz597uLzUxLPt64rxOghlWJdGp5GBkTc/3g3sUdNA= X-Received: by 2002:ac2:522f:0:b0:4fb:242:6dfa with SMTP id i15-20020ac2522f000000b004fb02426dfamr6890499lfl.57.1687987641947; Wed, 28 Jun 2023 14:27:21 -0700 (PDT) MIME-Version: 1.0 References: <20230623183934.23905-1-tphan@ventanamicro.com> <20230623183934.23905-6-tphan@ventanamicro.com> In-Reply-To: From: "Tuan Phan" Date: Wed, 28 Jun 2023 14:27:10 -0700 Message-ID: Subject: Re: [PATCH v4 5/7] OvmfPkg/RiscVVirt: Add VirtNorFlashDxe to APRIORI list To: Sunil V L Cc: devel@edk2.groups.io, michael.d.kinney@intel.com, gaoliming@byosoft.com.cn, zhiguang.liu@intel.com, git@danielschaefer.me, andrei.warkentin@intel.com, ardb+tianocore@kernel.org Content-Type: multipart/alternative; boundary="000000000000c8b53305ff373fb4" --000000000000c8b53305ff373fb4 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Jun 28, 2023 at 9:47=E2=80=AFAM Sunil V L wrote: > On Fri, Jun 23, 2023 at 11:39:32AM -0700, Tuan Phan wrote: > > Make sure VirtNorFlashDxe loaded before VariableRuntimeDxe as it > > is the backend flash driver. > > > > Signed-off-by: Tuan Phan > > --- > > OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf | 10 ++++++++++ > > 1 file changed, 10 insertions(+) > > > > diff --git a/OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf > b/OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf > > index 21e4ba67379f..9ab8eb3ba7d8 100644 > > --- a/OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf > > +++ b/OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf > > @@ -53,6 +53,16 @@ READ_STATUS =3D TRUE > > READ_LOCK_CAP =3D TRUE > > READ_LOCK_STATUS =3D TRUE > > > > +APRIORI DXE { > > + INF MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf > > + INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf > > + INF > MdeModulePkg/Universal/ReportStatusCodeRouter/RuntimeDxe/ReportStatusCode= RouterRuntimeDxe.inf > > + INF > MdeModulePkg/Universal/StatusCodeHandler/RuntimeDxe/StatusCodeHandlerRunt= imeDxe.inf > > + INF EmbeddedPkg/Drivers/FdtClientDxe/FdtClientDxe.inf > > + INF UefiCpuPkg/CpuDxeRiscV64/CpuDxeRiscV64.inf > > + INF OvmfPkg/VirtNorFlashDxe/VirtNorFlashDxe.inf > > +} > > + > Hi Tuan, > > Actually, Ard had recommended not to use APRIORI and hence we avoided > it when we upstreamed RiscVVirt. So, I am wondering whether this can be > avoided by using depex in CpuDxe on gEfiVariableArchProtocolGuid? > > Hi Sunil, Not sure what the reason behind avoiding APRIORI besides it is a workaround for broken DEPEX. BTW, what we need is to put VirtNorFlashDxe loaded before VariableRuntimeDxe which doesn't depend on any modules. I don't see any other clearer way than modifying VirNorFlashDxe as shown in the first version of this series. The CpuDxeRiscV64 in the aprioriy list as VirNorFlashDxe depends on it. Thanks, > Sunil > --000000000000c8b53305ff373fb4 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Wed, Jun 28, 2023 at 9:47=E2=80=AF= AM Sunil V L <sunilvl@ventan= amicro.com> wrote:
On Fri, Jun 23, 2023 a= t 11:39:32AM -0700, Tuan Phan wrote:
> Make sure VirtNorFlashDxe loaded before VariableRuntimeDxe as it
> is the backend flash driver.
>
> Signed-off-by: Tuan Phan <tphan@ventanamicro.com>
> ---
>=C2=A0 OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf | 10 ++++++++++
>=C2=A0 1 file changed, 10 insertions(+)
>
> diff --git a/OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf b/OvmfPkg/RiscVVirt/R= iscVVirtQemu.fdf
> index 21e4ba67379f..9ab8eb3ba7d8 100644
> --- a/OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf
> +++ b/OvmfPkg/RiscVVirt/RiscVVirtQemu.fdf
> @@ -53,6 +53,16 @@ READ_STATUS=C2=A0 =C2=A0 =C2=A0 =C2=A0 =3D TRUE
>=C2=A0 READ_LOCK_CAP=C2=A0 =C2=A0 =C2=A0 =3D TRUE
>=C2=A0 READ_LOCK_STATUS=C2=A0 =C2=A0=3D TRUE
>=C2=A0
> +APRIORI DXE {
> +=C2=A0 INF=C2=A0 MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.i= nf
> +=C2=A0 INF=C2=A0 MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
> +=C2=A0 INF=C2=A0 MdeModulePkg/Universal/ReportStatusCodeRouter/Runtim= eDxe/ReportStatusCodeRouterRuntimeDxe.inf
> +=C2=A0 INF=C2=A0 MdeModulePkg/Universal/StatusCodeHandler/RuntimeDxe/= StatusCodeHandlerRuntimeDxe.inf
> +=C2=A0 INF=C2=A0 EmbeddedPkg/Drivers/FdtClientDxe/FdtClientDxe.inf > +=C2=A0 INF=C2=A0 UefiCpuPkg/CpuDxeRiscV64/CpuDxeRiscV64.inf
> +=C2=A0 INF=C2=A0 OvmfPkg/VirtNorFlashDxe/VirtNorFlashDxe.inf
> +}
> +
Hi Tuan,

Actually, Ard had recommended not to use APRIORI and hence we avoided
it when we upstreamed RiscVVirt. So, I am wondering whether this can be
avoided by using depex in CpuDxe on gEfiVariableArchProtocolGuid?

Hi Sunil,
Not sure what the reason behind a= voiding APRIORI besides it is a workaround for broken DEPEX. BTW, what we n= eed is to put VirtNorFlashDxe=C2=A0loaded before VariableRuntimeDxe which d= oesn't depend on any modules. I don't see any other clearer way tha= n modifying VirNorFlashDxe as shown in the first version of this series.

The CpuDxeRiscV64=C2=A0in the aprioriy list as VirNo= rFlashDxe depends on it.

Thanks,
Sunil
--000000000000c8b53305ff373fb4--