From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM02-SN1-obe.outbound.protection.outlook.com (NAM02-SN1-obe.outbound.protection.outlook.com [40.107.96.75]) by mx.groups.io with SMTP id smtpd.web12.39747.1666006019159256775 for ; Mon, 17 Oct 2022 04:26:59 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@amd.com header.s=selector1 header.b=stgcXoKm; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.107.96.75, mailfrom: abner.chang@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=c7K0QGP99I8rghHAgsRI4kBRDClBLvWdberUhway1O//jZGK7Ow8mPTMds6pukntXdLiomnfdPNbXfD6oPgIQ1qnLRBFDY/prxHSvRIy/oyVO6oDJsyOtqQ+HjhnYfXLQsiJhm4CLYDeqqmpUsbMDrcGN2I+yAhEkC/vGic0CfV3vguQZu+tBaoCePARt5W4kRZ6z42Kjd84FYU6pzrSnT004htrz2GZiR5WUI+kjxsqTNloMuyd6lyFyYNK0T97WVxT29K1LYk7MKY+Wn2CS77TdTSU7NsgaE0z0dvCAPDqfmcrZIxq3AeppKPBMB1JJC2Kgay9blneS6P/GLfHoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=9iwER/+A8hOVGlsncOrizAiP159/iYz6IAJQlqCWm8k=; b=k3C58HTu6McdK+e4APlnlXVaAGimQ/GF+RpPxg3YYCtsDkJnc4mty0mVOMoqOKlce6219rf47B1Acbgr3qn4qP21UtFc9VR9mwqHGfQtp6Vvk8aiHmiKhj2xmemm7/7bZWDiCdCffVAtx9bnqrE6oK/Myw0JO0yo7X0c+7hIFNa6yOirGWuIzk9UnjYFcFRkotlwQ2Hc6iQ1P+r+GO90XgMgN3+pydplX2oZGieL40Ht2ys+9P+6ijOf+4D9RdXCX4ekVIRZ75SfT6PrWHbPH6gO/XQdBUWEM9RrJlcgKgUI1tKb6/6m8aujaV2G9+fKp9Nqvg/l4hfA+BHjfnn/eA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=9iwER/+A8hOVGlsncOrizAiP159/iYz6IAJQlqCWm8k=; b=stgcXoKm4yYpptX+mI5FZUe0thoyf785CAVOtAbPBArjIH/MMLEqgNE1fWZMDoQaM2ilTkdXQG/OPA39YWOuFYWL0D6aAitGKaRpAaRL91ykBIiN2aW2R0kiC1HlVeXlK8ZKDBbMw41xik8UjmkUV974rFI+3PVJ2y3VBU6BloU= Received: from MN2PR12MB3966.namprd12.prod.outlook.com (2603:10b6:208:165::18) by SN7PR12MB7345.namprd12.prod.outlook.com (2603:10b6:806:298::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5723.26; Mon, 17 Oct 2022 11:26:56 +0000 Received: from MN2PR12MB3966.namprd12.prod.outlook.com ([fe80::2eab:b851:827c:1d88]) by MN2PR12MB3966.namprd12.prod.outlook.com ([fe80::2eab:b851:827c:1d88%3]) with mapi id 15.20.5723.033; Mon, 17 Oct 2022 11:26:56 +0000 From: "Chang, Abner" To: Sunil V L CC: "devel@edk2.groups.io" , Ard Biesheuvel , Jiewen Yao , Jordan Justen , Gerd Hoffmann , "Singh, Brijesh" , Erdem Aktas , James Bottomley , Min Xu , "Lendacky, Thomas" , Daniel Schaefer Subject: Re: [edk2-devel] [edk2-staging/RiscV64QemuVirt PATCH V4 10/34] OvmfPkg/Sec: Add RISC-V support Thread-Topic: [edk2-devel] [edk2-staging/RiscV64QemuVirt PATCH V4 10/34] OvmfPkg/Sec: Add RISC-V support Thread-Index: AQHY3+z9gH9eEatOzk2KHOKFja6LAK4PmCswgAJwpwCAAGwYwA== Date: Mon, 17 Oct 2022 11:26:56 +0000 Message-ID: References: <20221014164836.1513036-1-sunilvl@ventanamicro.com> <20221014164836.1513036-11-sunilvl@ventanamicro.com> In-Reply-To: Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Enabled=true; MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_SetDate=2022-10-17T11:26:53Z; MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Method=Standard; MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Name=General; MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_ActionId=3102a142-93ed-436b-b3d6-d2eeb09ac534; MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_ContentBits=1 authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: MN2PR12MB3966:EE_|SN7PR12MB7345:EE_ x-ms-office365-filtering-correlation-id: 4282639a-7f6d-4411-6b5e-08dab0327fd6 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: 0jy+vsLEYQAvNcQWsGzuS3o/8Tsj8xNr5XUiIVSy5uioUJ9fAEbybzUczK8fy6V4lOs0OxNMlt9V6ZTvFA7hFvMpUn2T6v+V8304aG+28DnwQt8rG21ybVhdNguhOlolQrzBa8ZEOfRsmqDQYXe/M598qFrFPA90JXGOLW8Ze1oYjrPPngKF5Ai9RViGQ+BQFmU9t02/ablnnxXV0j64eZNNubBUPXkdSCNidK4xUtCkaJg4+0XDu9xkIdA07v5n8i1Cm7crNtC1iL4SS3Wfthv+IY/lITMaKdEC830BXAd0RPtQizDkDOvc3BScH7/jSjZmEDtvPus58nu/FAEdTyLtpZupgJQGt7uBxD6BM8EcVPK3ojLIEMROA+ku363yHFalu+DSTzu9+gRaSFSK97yqKn5z7+fLh0uA01kgYsxXCEChOyG1V46Mhe1UYHSjecDZxSK3nR40ICvQema0pj46gVb+P0gKSeEFHSvfVltpBmv6klffq6pcxTQi+ZMpUH2dgje/jQYSPJ5GSlh5MCOPPr7n0GouKrxUp9qSe9E0EIvv/w//m70UdlOcSrbjW23LJXCMnAKhKe1/NJ6z1ibsKvQyFzir4VXp0zAU0vnffZ5YgOiycAzSKT1+kSz5SgXuqacwByS0nUT3Nqq5Liny9Zdx8+LybmzikpsuTTYbt53DX8X4FRV2sb184VYH3oheBnsdVXQGnFdPxZNUAup6RrdfOmnw15YvmRxxTG+lMbtoYcd9UbYwAcgGh2q7HEPlC/ViVhGD43W5G45IlQ== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MN2PR12MB3966.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(4636009)(39860400002)(346002)(366004)(396003)(376002)(136003)(451199015)(66899015)(6916009)(7416002)(66556008)(54906003)(66446008)(8676002)(66476007)(76116006)(64756008)(316002)(478600001)(9686003)(7696005)(6506007)(4326008)(41300700001)(26005)(52536014)(53546011)(186003)(71200400001)(2906002)(5660300002)(8936002)(38070700005)(83380400001)(38100700002)(66946007)(55016003)(122000001)(86362001)(33656002);DIR:OUT;SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?CAlOiqZIo8ge3l5dxegA3QognTBpq49OV2eYBtyHpvumYc6X9XvcfvARn8VB?= =?us-ascii?Q?PyegrDXkn4MjEI/zccPjwQatq/QDoZrTLtw679HqQCoclQUNhepYLMK4t9Cz?= =?us-ascii?Q?WplHoZuRUzeRDn3mnwgSDiMHss/hNw3SoSoZCnXTijCjgPr5NhzWsnpAdLNn?= =?us-ascii?Q?quOkv5RYZN6KEOE3SghiMQkXyWvrDDmawgJCBDXR1xnPCk6wCTPe8uhPaHWw?= =?us-ascii?Q?gKVVY7KEoMxc0Z27aAb09vSphgG6L3nh4ILVRU7S7wZxNS8wTL2kMy7pL9JY?= =?us-ascii?Q?4wLJ8zFBQA4h8HwBfxtTLcPLnE2SrcWFIBH3kCNsY9IQPgjlYDMeaErmpr9+?= =?us-ascii?Q?5Zl6Pj1tny2UuoYe9KmPj2gz43hN2T7Qk5s69gdziQpKvlMMTBKBekgG7hC2?= =?us-ascii?Q?wpGJ41cdcMOaDxdzkdcmFoMRYHwQJjA2KiHEjECrYbVz8pkoxqYoSfYgCXWf?= =?us-ascii?Q?8r5AbnHqEJ08x/aply++3tUrr9l09iUbp88kZ5TE76iaMoNggvxRVp5XGi92?= =?us-ascii?Q?82AC0/TeyFatafSqVnt1iYWe7+C43qh8HU0TxDYlgik+DnWABE1HR8vdhCGX?= =?us-ascii?Q?6N/hsLRt2MYpJMXS9ZWK7j1KfjjHDLhRNiukvFmRDLpKIu4DB1iffxfZ11Uw?= =?us-ascii?Q?GOjUepWgcW5HcY4i4Pc1p9vJPlxsOZI76XPkfc+grTY0XW0DF7jghEDifOe1?= =?us-ascii?Q?pSZgUsOBPkElb8YTwENGR3X3rCGN/ml+MJTl6lQwO/xNzkymGImd77hSGscP?= =?us-ascii?Q?ej3vJclriRiOPs9hsH5W5pXX6BMboyrv9RY/b1JdsQcNjn8JhtFjOFR3sA6y?= =?us-ascii?Q?1hTVu/qs272uGipbxKNkla3tILujVu9UbpAKafa7mTanumDu6hkdHaI016gi?= =?us-ascii?Q?PR8AH6H0lYngxSnVJj1uepNCA0TY5eYKCyOx2KlSqn6fanZSPakQLiOL2oH8?= =?us-ascii?Q?X3BfyKiyyM7XlhsdCEOn5xyeFI49Eja0Akv9BYyy8YFn0WjN3Cv2KRW/XIYp?= =?us-ascii?Q?xG8lH6u+I0l0GPEZaWZE+kIdrcr0zP8EhbhpXsFTRfxYUHhCHGLjwy0rAzz8?= =?us-ascii?Q?w11OxGJt1TsgyNQBlmnVT+E/rH6E83i440oPN3vjCHC5T7x+u6FIs7V0mQ1w?= =?us-ascii?Q?L+WWjuyHexpckekSBwxllgVsVBAtvg1yMra4ekupcEuIwcBqfog0vfN9JqdD?= =?us-ascii?Q?Sm5okudcQmFiraZZgnvtp6OlGOin1sfvy9Wn2zQBXaFkUDBn/0qKtF5etc0u?= =?us-ascii?Q?QrbGi7l4faD1z59Gg/FbBbxx+txsLa7fOezVYY1mobb/EJy53MJ7wVbo8jQp?= =?us-ascii?Q?MNtGLZSkVYJ7hd1qf4iCiYIV6vOGAlP8xh3IznPEo8UZIvtB1/0ZHCIYLYc4?= =?us-ascii?Q?eE0LQ7/ahAdOBnhG6dWU6RYipIgJgw9h7MoWTRbKStRkdPXIZDN5SINQKrE6?= =?us-ascii?Q?Vcphs+vofOZi6F4GwfwoA8wK85TkeDoHYlZiarmXV8Ud9z+iAiSkrMIM9y6c?= =?us-ascii?Q?CxQEZNCeQvrDKoxBV5CmwK3Sp3oU6nv4l8zfBPq7brnxOQ6AyjBIcYYTmtzj?= =?us-ascii?Q?fsk1lgGFVmR8Q0uOu0XZUU3VIRardI/XnA5gpmTf?= MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MN2PR12MB3966.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4282639a-7f6d-4411-6b5e-08dab0327fd6 X-MS-Exchange-CrossTenant-originalarrivaltime: 17 Oct 2022 11:26:56.5646 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: FonVmNMwhNfa/jXxHdi27mBOmsKkZ/XkkuM2g1cGyFAeiIaKVrUl8sxpf6k2gDVFczyHWj3n2M+uKGO0zcCxww== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB7345 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable [AMD Official Use Only - General] > -----Original Message----- > From: Sunil V L > Sent: Monday, October 17, 2022 12:53 PM > To: Chang, Abner > Cc: devel@edk2.groups.io; Ard Biesheuvel ; > Jiewen Yao ; Jordan Justen > ; Gerd Hoffmann ; Singh, > Brijesh ; Erdem Aktas ; > James Bottomley ; Min Xu ; > Lendacky, Thomas ; Daniel Schaefer > > Subject: Re: [edk2-devel] [edk2-staging/RiscV64QemuVirt PATCH V4 10/34] > OvmfPkg/Sec: Add RISC-V support >=20 > Caution: This message originated from an External Source. Use proper > caution when opening attachments, clicking links, or responding. >=20 >=20 > On Sat, Oct 15, 2022 at 03:50:02PM +0000, Chang, Abner wrote: > > [AMD Official Use Only - General] > > > > Hi Sunil, this is my comment for both 9/34 and 10/34. > > The original RISC-V SecCore implementation can be used by RiscVVirt and > the RISC-V platforms under edk2-platform. So my plan back to half year ag= o > was to have SecCore under UefiCpuPkg, that would be Riscv64SecCore > because current the SecCore under UeficpuPkg is hard to be leveraged. Wit= h > this, one RISC-V SecCore driver can be used by RiscVVirt and RISC-V > platforms. Of course we have to move some Pcds to under PCD Riscv64 arch > section in UEfiCpuPkg.dec. Even through having PcdRiscVDbtFvBase(Size) fo= r > Riscv64 in UefiCpuPkg.dec makes sense to me because Device Tree is part o= f > RISC-V processor initialization. > > Could you please take some time having this change? I think that is doa= ble > and also an ideal implementation for RISC-V. > > > Hi Abner, >=20 > Having SEC as part of SecCoreNative in UefiCpuPkg was my original proposa= l > when I had sent the RFC series to discuss in the design meeting. But if y= ou > remember, Mike provided 2 major feedbacks in the meeting which made me > to move to OvmfPkg. >=20 > 1) We should not add FDF related PCD variables in common packges like > UefiCpuPkg/MdeModulePkg. OvmfPkg is the only package (ofcourse > ArmVirtPkg also currently) which is an exception to this since it actuall= y has > platform implementation useful for CI coverage. >=20 > 2) Avoid new circular dependencies. We will have to use EmbeddedPkg in > UefiCpuPkg/MdeModulePkg for FDT if we use SecCore in UefiCpuPkg. Ok, this is convincing. Thanks. Abner >=20 > It made sense to me and OvmfPkg already had the required PCD variables > and modules. Also, qemu virt can support different features (boot from fl= ash > vs memory, number of flash devices etc) compared to real platforms. > So, it will be hard to use the same design for both virt machine and real > platforms. The original SecCore in edk2-platforms can be continued to be > used by real platforms. Like Ray suggested, I plan to look at MinPlatform= Pkg > design for real platforms in edk2-platforms repo which will make the desi= gn > flexible. >=20 > Thanks > Sunil >=20 > > Thanks > > Abner