From nobody Mon Feb 9 20:30:37 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+94906+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+94906+1787277+3901457@groups.io ARC-Seal: i=1; a=rsa-sha256; t=1665396752; cv=none; d=zohomail.com; s=zohoarc; b=EpeAsB5qBRJgvMBcUrjrcuB/zsuKnGi0Ywm2ZElqDdqRcAaCBMbbvdFZTwi3tAat2M7fAoEQ22pN8x7q2TfHbICIciwlf8HQUuteUsoy+Aw77+x/U02C5xpcRKIlTMcl97scYX96nuSnkRSeJ804ZCnDlRQtOFKS3vCIoGC9Fyo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1665396752; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=6TaKHxI+aLXq1KjKyVhWdWNeFznvE0/gYRQa+PqSUes=; b=N2CkYyXMk8rhjrU5F5dw+2urnC6KJP/0XqEVJv/rW6q8WO5jeJUrfD/IRmropSOrVXnuCG4vdBCbrTwsFPrLHorns2JHnPOYvTJuLFuJrR+mJK+FNFkL6XazzEBXXstk9BPKU77T7yOrycvb1oU6dNgmWLEL5YIsSgxdHzrZV0E= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+94906+1787277+3901457@groups.io Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1665396752006626.8809413746714; Mon, 10 Oct 2022 03:12:32 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id AgaWYY1788612xwj47guoddU; Mon, 10 Oct 2022 03:12:30 -0700 X-Received: from mail-pl1-f176.google.com (mail-pl1-f176.google.com [209.85.214.176]) by mx.groups.io with SMTP id smtpd.web11.4506.1665396750096840700 for ; Mon, 10 Oct 2022 03:12:30 -0700 X-Received: by mail-pl1-f176.google.com with SMTP id l4so9953494plb.8 for ; Mon, 10 Oct 2022 03:12:30 -0700 (PDT) X-Gm-Message-State: mX0ea38naAHJZqHcJzSAxNBZx1787277AA= X-Google-Smtp-Source: AMsMyM4X62R5JA8QaODQ0S3iGwH81/4H4yHZ1MuoAGZsl8s0R66nXI8hc2V5kzu8pOWBAouRcehCbQ== X-Received: by 2002:a17:90a:f2c3:b0:20b:b75f:2f9e with SMTP id gt3-20020a17090af2c300b0020bb75f2f9emr17256845pjb.43.1665396749460; Mon, 10 Oct 2022 03:12:29 -0700 (PDT) X-Received: from localhost.localdomain ([49.206.13.138]) by smtp.gmail.com with ESMTPSA id h17-20020a170902f55100b001788ccecbf5sm6302138plf.31.2022.10.10.03.12.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Oct 2022 03:12:29 -0700 (PDT) From: "Sunil V L" To: devel@edk2.groups.io Cc: Ard Biesheuvel , Jiewen Yao , Jordan Justen , Gerd Hoffmann , Rebecca Cran , Peter Grehan Subject: [edk2-devel] [edk2-staging/RiscV64QemuVirt PATCH 07/29] OvmfPkg/ResetSystemLib: Refactor to allow other architectures. Date: Mon, 10 Oct 2022 15:41:40 +0530 Message-Id: <20221010101202.1146624-8-sunilvl@ventanamicro.com> In-Reply-To: <20221010101202.1146624-1-sunilvl@ventanamicro.com> References: <20221010101202.1146624-1-sunilvl@ventanamicro.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,sunilvl@ventanamicro.com Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1665396750; bh=CpeysVM/kA3qbeqsuIsNcvsdro+0UNcjKlYHGPJD3ZY=; h=Cc:Date:From:Reply-To:Subject:To; b=wVF2yrc2Wa/1eI7pkK0ynUw2RS7xevhNGNJd3qc8IQnsHX/7UfmKY62SY1CypMFpZGg wsd2kO+zT+KZnzT8evnmlENo2RWzBxVLrnMNB+Z1FzmbOJ7jK5nZNunOSOohhBYoZOYOq jpUr7DHlsAt9CX5vatDSPOKV2Ge5HOpYR7U= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1665396753162100001 Content-Type: text/plain; charset="utf-8" REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D4076 Currently, the ResetSystemLib library supports only X86 architecture. Refactor it to allow adding other CPU architectures like RISC-V. Cc: Ard Biesheuvel Cc: Jiewen Yao Cc: Jordan Justen Cc: Gerd Hoffmann Cc: Rebecca Cran Cc: Peter Grehan Signed-off-by: Sunil V L --- OvmfPkg/Library/ResetSystemLib/BaseResetSystemLib.inf | 6 +++--- OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibBhyve.inf | 4 ++-- .../Library/ResetSystemLib/BaseResetSystemLibMicrovm.inf | 2 +- OvmfPkg/Library/ResetSystemLib/DxeResetSystemLib.inf | 6 +++--- .../ResetSystemLib/{ =3D> Ia32_X64}/BaseResetShutdown.c | 0 .../ResetSystemLib/{ =3D> Ia32_X64}/BaseResetShutdownBhyve.c | 0 .../ResetSystemLib/{ =3D> Ia32_X64}/DxeResetShutdown.c | 0 .../{ =3D> Ia32_X64}/DxeResetSystemLibMicrovm.c | 0 .../Library/ResetSystemLib/{ =3D> Ia32_X64}/ResetSystemLib.c | 0 .../ResetSystemLib/{ =3D> Ia32_X64}/ResetSystemLibMicrovm.c | 0 10 files changed, 9 insertions(+), 9 deletions(-) rename OvmfPkg/Library/ResetSystemLib/{ =3D> Ia32_X64}/BaseResetShutdown.c= (100%) rename OvmfPkg/Library/ResetSystemLib/{ =3D> Ia32_X64}/BaseResetShutdownBh= yve.c (100%) rename OvmfPkg/Library/ResetSystemLib/{ =3D> Ia32_X64}/DxeResetShutdown.c = (100%) rename OvmfPkg/Library/ResetSystemLib/{ =3D> Ia32_X64}/DxeResetSystemLibMi= crovm.c (100%) rename OvmfPkg/Library/ResetSystemLib/{ =3D> Ia32_X64}/ResetSystemLib.c (1= 00%) rename OvmfPkg/Library/ResetSystemLib/{ =3D> Ia32_X64}/ResetSystemLibMicro= vm.c (100%) diff --git a/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLib.inf b/OvmfPk= g/Library/ResetSystemLib/BaseResetSystemLib.inf index 35d317f1e0b3..4397f90a24dd 100644 --- a/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLib.inf +++ b/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLib.inf @@ -21,9 +21,9 @@ [Defines] # VALID_ARCHITECTURES =3D IA32 X64 # =20 -[Sources] - BaseResetShutdown.c - ResetSystemLib.c +[Sources.IA32, Sources.X64] + Ia32_X64/BaseResetShutdown.c + Ia32_X64/ResetSystemLib.c =20 [Packages] MdeModulePkg/MdeModulePkg.dec diff --git a/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibBhyve.inf b/O= vmfPkg/Library/ResetSystemLib/BaseResetSystemLibBhyve.inf index 74124aed38e8..3e52a9e3d7f9 100644 --- a/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibBhyve.inf +++ b/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibBhyve.inf @@ -25,8 +25,8 @@ [Defines] # =20 [Sources] - BaseResetShutdownBhyve.c - ResetSystemLib.c + Ia32_X64/BaseResetShutdownBhyve.c + Ia32_X64/ResetSystemLib.c =20 [Packages] MdeModulePkg/MdeModulePkg.dec diff --git a/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibMicrovm.inf b= /OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibMicrovm.inf index 564b1d3022a6..c66720771d82 100644 --- a/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibMicrovm.inf +++ b/OvmfPkg/Library/ResetSystemLib/BaseResetSystemLibMicrovm.inf @@ -23,7 +23,7 @@ [Defines] # =20 [Sources] - ResetSystemLibMicrovm.c + Ia32_X64/ResetSystemLibMicrovm.c =20 [Packages] MdeModulePkg/MdeModulePkg.dec diff --git a/OvmfPkg/Library/ResetSystemLib/DxeResetSystemLib.inf b/OvmfPkg= /Library/ResetSystemLib/DxeResetSystemLib.inf index a9b4ce90000a..79478453d7cb 100644 --- a/OvmfPkg/Library/ResetSystemLib/DxeResetSystemLib.inf +++ b/OvmfPkg/Library/ResetSystemLib/DxeResetSystemLib.inf @@ -23,9 +23,9 @@ [Defines] # VALID_ARCHITECTURES =3D IA32 X64 # =20 -[Sources] - DxeResetShutdown.c - ResetSystemLib.c +[Sources.IA32, Sources.X64] + Ia32_X64/DxeResetShutdown.c + Ia32_X64/ResetSystemLib.c =20 [Packages] MdeModulePkg/MdeModulePkg.dec diff --git a/OvmfPkg/Library/ResetSystemLib/BaseResetShutdown.c b/OvmfPkg/L= ibrary/ResetSystemLib/Ia32_X64/BaseResetShutdown.c similarity index 100% rename from OvmfPkg/Library/ResetSystemLib/BaseResetShutdown.c rename to OvmfPkg/Library/ResetSystemLib/Ia32_X64/BaseResetShutdown.c diff --git a/OvmfPkg/Library/ResetSystemLib/BaseResetShutdownBhyve.c b/Ovmf= Pkg/Library/ResetSystemLib/Ia32_X64/BaseResetShutdownBhyve.c similarity index 100% rename from OvmfPkg/Library/ResetSystemLib/BaseResetShutdownBhyve.c rename to OvmfPkg/Library/ResetSystemLib/Ia32_X64/BaseResetShutdownBhyve.c diff --git a/OvmfPkg/Library/ResetSystemLib/DxeResetShutdown.c b/OvmfPkg/Li= brary/ResetSystemLib/Ia32_X64/DxeResetShutdown.c similarity index 100% rename from OvmfPkg/Library/ResetSystemLib/DxeResetShutdown.c rename to OvmfPkg/Library/ResetSystemLib/Ia32_X64/DxeResetShutdown.c diff --git a/OvmfPkg/Library/ResetSystemLib/DxeResetSystemLibMicrovm.c b/Ov= mfPkg/Library/ResetSystemLib/Ia32_X64/DxeResetSystemLibMicrovm.c similarity index 100% rename from OvmfPkg/Library/ResetSystemLib/DxeResetSystemLibMicrovm.c rename to OvmfPkg/Library/ResetSystemLib/Ia32_X64/DxeResetSystemLibMicrovm.c diff --git a/OvmfPkg/Library/ResetSystemLib/ResetSystemLib.c b/OvmfPkg/Libr= ary/ResetSystemLib/Ia32_X64/ResetSystemLib.c similarity index 100% rename from OvmfPkg/Library/ResetSystemLib/ResetSystemLib.c rename to OvmfPkg/Library/ResetSystemLib/Ia32_X64/ResetSystemLib.c diff --git a/OvmfPkg/Library/ResetSystemLib/ResetSystemLibMicrovm.c b/OvmfP= kg/Library/ResetSystemLib/Ia32_X64/ResetSystemLibMicrovm.c similarity index 100% rename from OvmfPkg/Library/ResetSystemLib/ResetSystemLibMicrovm.c rename to OvmfPkg/Library/ResetSystemLib/Ia32_X64/ResetSystemLibMicrovm.c --=20 2.25.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#94906): https://edk2.groups.io/g/devel/message/94906 Mute This Topic: https://groups.io/mt/94233005/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-