From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id B33EED811F1 for ; Tue, 27 Feb 2024 15:52:39 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=2kXh2r6Duzv72b3Fn96B882IY9Sp59Mh15zG5w00Wks=; c=relaxed/simple; d=groups.io; h=ARC-Seal:ARC-Message-Signature:ARC-Authentication-Results:Message-ID:Date:User-Agent:Subject:To:Cc:References:From:Autocrypt:In-Reply-To:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Language:Content-Type:Content-Transfer-Encoding; s=20140610; t=1709049158; v=1; b=G899AexYoXkXDIbr5T8t0ETlLKPkPujN+uwxP7m14zasqnkybiyrM+/SBd0BNRHwpi1pdELi Nlq42zV0rr/WRFgiFH6YtSdACswVXOcRouEq2vz2l4VeVhCNRGUdWl01z9nAa7XQB0Tvzs63Gft KUflKqfTPnnKsz+A53+fiayI= X-Received: by 127.0.0.2 with SMTP id MhJJYY7687511xP5stHucWt3; Tue, 27 Feb 2024 07:52:38 -0800 X-Received: from NAM12-DM6-obe.outbound.protection.outlook.com (NAM12-DM6-obe.outbound.protection.outlook.com [40.107.243.82]) by mx.groups.io with SMTP id smtpd.web11.15564.1709049157562641703 for ; Tue, 27 Feb 2024 07:52:37 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=gJI2vxTHvLXrfAbBLWQZtTY/rn3+eUvY+1QU3hGYmpchR5X5EEakt18+EP6Y80yEE31jeogBg6o8JvP3ADv4f4HBb6XcB1/JKIXAjnpEi9ye2xY0I1bCWoWA/XXApdvxkm4U9qnYb/pz6xViBrb+3DLuTRuxIQACKIO6kD3LbIhPQ9N0CHvaJSUyYCViyBw4bN92YRYk4HQcLja2QKt6C1muoDWS7+5MjExJ/rpQhYB2SkqFmqaXlZxsLXhHxVxYC1JO/F1D3xSy25dgXZijCxqUGHQnAeAmd/bxYsUaWYqmaZI511SNq4uT84BGv0yC8u9eQsLp0ge+GCOmuucaHA== 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=jrCR904d/vQZ3P1xtDGyi7fmadXvsVGoNSk/6LL59E0=; b=fzchfxCrUJT/Kn8eMxcguX6bzv/R/gyQr7PIKssZIVeEdZaO3yTKg/X7VPoIa4gPmsitATKSW3drF04Ja3hInN8sSEavD18fRARroVS+EMo3Euh72n1lhOvqqzNlz76kO1VRD2KTvJQL0dvaJdRGWg4tb1nHEAez6xpRiTEHEsSDF3YNNePjg1tkj65AEafzP6m7FsVSEkTsWnUOP3Idi4ZVQDdd0nZCttDs66o/FYfjZGpg3heslhuUUtBvlfWAR0ROD6EecRMgCRt4I4eG8oca6f+ynbzat745PkzvGzIYDkGziZhFUl9E/N7ua4JG+GJfTCGgLmq3PkKUq2z47A== 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 X-Received: from BL1PR12MB5732.namprd12.prod.outlook.com (2603:10b6:208:387::17) by DS0PR12MB7875.namprd12.prod.outlook.com (2603:10b6:8:14d::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7316.33; Tue, 27 Feb 2024 15:52:33 +0000 X-Received: from BL1PR12MB5732.namprd12.prod.outlook.com ([fe80::4c26:40af:e1fd:849e]) by BL1PR12MB5732.namprd12.prod.outlook.com ([fe80::4c26:40af:e1fd:849e%7]) with mapi id 15.20.7316.035; Tue, 27 Feb 2024 15:52:32 +0000 Message-ID: Date: Tue, 27 Feb 2024 09:52:30 -0600 User-Agent: Mozilla Thunderbird Subject: Re: [edk2-devel] [PATCH v2 07/23] MdePkg: Avoid hardcoded value for number of Page State Change entries To: Gerd Hoffmann Cc: devel@edk2.groups.io, Ard Biesheuvel , Erdem Aktas , Jiewen Yao , Laszlo Ersek , Liming Gao , Michael D Kinney , Min Xu , Zhiguang Liu , Rahul Kumar , Ray Ni , Michael Roth References: <01099a06092b17a9866d813d22ea46a006dde3f7.1708623001.git.thomas.lendacky@amd.com> From: "Lendacky, Thomas via groups.io" Autocrypt: addr=thomas.lendacky@amd.com; keydata= xsFNBFaNZYkBEADxg5OW/ajpUG7zgnUQPsMqWPjeAxtu4YH3lCUjWWcbUgc2qDGAijsLTFv1 kEbaJdblwYs28z3chM7QkfCGMSM29JWR1fSwPH18WyAA84YtxfPD8bfb1Exwo0CRw1RLRScn 6aJhsZJFLKyVeaPO1eequEsFQurRhLyAfgaH9iazmOVZZmxsGiNRJkQv4YnM2rZYi+4vWnxN 1ebHf4S1puN0xzQsULhG3rUyV2uIsqBFtlxZ8/r9MwOJ2mvyTXHzHdJBViOalZAUo7VFt3Fb aNkR5OR65eTL0ViQiRgFfPDBgkFCSlaxZvc7qSOcrhol160bK87qn0SbYLfplwiXZY/b/+ez 0zBtIt+uhZJ38HnOLWdda/8kuLX3qhGL5aNz1AeqcE5TW4D8v9ndYeAXFhQI7kbOhr0ruUpA udREH98EmVJsADuq0RBcIEkojnme4wVDoFt1EG93YOnqMuif76YGEl3iv9tYcESEeLNruDN6 LDbE8blkR3151tdg8IkgREJ+dK+q0p9UsGfdd+H7pni6Jjcxz8mjKCx6wAuzvArA0Ciq+Scg hfIgoiYQegZjh2vF2lCUzWWatXJoy7IzeAB5LDl/E9vz72cVD8CwQZoEx4PCsHslVpW6A/6U NRAz6ShU77jkoYoI4hoGC7qZcwy84mmJqRygFnb8dOjHI1KxqQARAQABzSZUb20gTGVuZGFj a3kgPHRob21hcy5sZW5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r9adirnDw1Wruafmyxnn5W3rhJy06etmP0pzL6frN y46PmDPicLjX/srgemvLtHoeVRplL9ATAkmQ7yxXc6wBSwf1BYs9gAiwXbU1vMod0AXXRBym 0qhojoaSdRP5XTShfvOYdDozraaKx5Wx8X+oZvvjbbHhHGPL2seq97fp3nZ9h8TIQXRhO+aY vFkWitqCJg== In-Reply-To: X-ClientProxiedBy: SN6PR05CA0015.namprd05.prod.outlook.com (2603:10b6:805:de::28) To BL1PR12MB5732.namprd12.prod.outlook.com (2603:10b6:208:387::17) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BL1PR12MB5732:EE_|DS0PR12MB7875:EE_ X-MS-Office365-Filtering-Correlation-Id: ca28b40a-3673-443d-fe1c-08dc37ac1c39 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Message-Info: TlHAEQKXh5UHcgs9lIdaZw2YeFeUZWiPcGe7JqAE+uOhaQUqc0kRDAjYaknqQnxyTUssm9EmCaBlxzDiDUdjMedomwH5KnYNOoQgokd1f1UOetG+jj2iidPFH528a6wtIyvzXhQ63D3Z9TJ0mL9YUYml8r2mIIIHNCCgF1YU0Izm9hZL9mwszAJadQEE3LhsMFafuJZqexL63hQamrNln7fe/9210YChTNfUpjZr6gblBihcq2LutvdZZV3cnwGSrFYrPaBr8ARRZVlAkipebhRWCgaOMo4PwlpaBqHmya0GXt7zN8ohcwhx6UNsQjVWvwSU4+IVMHwTiUSNXH7/vRI5UYY2xgd+Tgsvw+K6sr8T5yVcioAPl6TnwEtg8oBW55mXcnQW6+P20VNczp7Xzv+pQP8Brh7h46F0i6X7RzrNpmaKdh3ggLaG21kuEu0pTI928QSzIQxHOGqj0ps/mdSoBbSPtpCGlRWX4v03IN5t14XKJxgXdDD4+vYtQLlS+dTWeSEyYjWVmMIuxTylGIIO0KIMUMap2XdDVKvN/vSVEVn4+CW5lNdEuI7UR524hCMZybWol8lFhJBgAc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8?B?MTN4bVVMWjM5ZTY3RnNkOWk3a2NBd0N0cytXQkxzSEF4dk1zOCs0eXpsRWNO?= =?utf-8?B?WGRnVjBJck5DRUYwUklRTXBqT3U1ZVA1ZElSZ3lnQXg0bkVraGJOWGFORGxu?= =?utf-8?B?V0l1cnRiS0U5ZmUrVUJTMDl5czFDSjJDNFoyZlF6VjkrdC9qeGFVOHlWa0s5?= =?utf-8?B?WnRWMXYvWGxPWFNjcmtkeUdURGJwZE9Vd29aeUtXNzRnS0NPUkJuUGxzMkhr?= =?utf-8?B?VFp5ejFhK0g5Q1hTR0VpU3Nzc1JQSTZ6Wkc5NU9ydmhaTjViMXMvaTNBWGlh?= =?utf-8?B?TVZZOGcvT3hPMXVBdXlFdWVTdU92OGpUUjRFS2RLV2ZMWjhDS0RkNGxTS3M2?= =?utf-8?B?YUFDdEIybTlBdUFNN3dTekdlNU05RmNWMWNIWmRoS1ZhUmMxcjVJMjhRYm1u?= =?utf-8?Q?jMB++pPGATLUGSl1ewiqaG4J6?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: ca28b40a-3673-443d-fe1c-08dc37ac1c39 X-MS-Exchange-CrossTenant-AuthSource: BL1PR12MB5732.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Feb 2024 15:52:32.8790 (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: aQOHwKJDjeMJnK4BRS4YkEvTMYv2R9ctt9qhXMF46cpIYHUJJe5ix1u9sJ1VQsQ6xWoQimDNK61tCHGLDgqNMw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR12MB7875 Precedence: Bulk 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,thomas.lendacky@amd.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: KDSc5z1c6DPihmU0Tt6WBVt4x7686176AA= Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=G899AexY; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io; dmarc=pass (policy=none) header.from=groups.io; arc=reject ("signature check failed: fail, {[1] = sig:microsoft.com:reject}") On 2/27/24 04:18, Gerd Hoffmann wrote: > On Thu, Feb 22, 2024 at 11:29:46AM -0600, Tom Lendacky wrote: >> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D4654 >> >> The SNP_PAGE_STATE_MAX_ENTRY is based on the number of entries that can >> fit in the GHCB shared buffer. As a result, the SNP_PAGE_STATE_CHANGE_IN= FO >> structure maps the full GHCB shared buffer based on the shared buffer si= ze >> being 2032 bytes. >> >> Instead of using a hardcoded value for SNP_PAGE_STATE_MAX_ENTRY, use a >> build calculated value. Since the SNP_PAGE_STATE_CHANGE_INFO is used as = a >> mapping, eliminate the hardcoded array size so that the structure can be >> used based on any size buffer. >> >> Signed-off-by: Tom Lendacky >> --- >> MdePkg/Include/Register/Amd/Ghcb.h | 7 ++++--- >> 1 file changed, 4 insertions(+), 3 deletions(-) >> >> diff --git a/MdePkg/Include/Register/Amd/Ghcb.h b/MdePkg/Include/Registe= r/Amd/Ghcb.h >> index 432d67e3e223..0cdc00627472 100644 >> --- a/MdePkg/Include/Register/Amd/Ghcb.h >> +++ b/MdePkg/Include/Register/Amd/Ghcb.h >> @@ -197,13 +197,14 @@ typedef struct { >> UINT32 Reserved; >> } SNP_PAGE_STATE_HEADER; >> =20 >> -#define SNP_PAGE_STATE_MAX_ENTRY 253 >> - >> typedef struct { >> SNP_PAGE_STATE_HEADER Header; >> - SNP_PAGE_STATE_ENTRY Entry[SNP_PAGE_STATE_MAX_ENTRY]; >> + SNP_PAGE_STATE_ENTRY Entry[]; >> } SNP_PAGE_STATE_CHANGE_INFO; >=20 > Good. >=20 >> +#define SNP_PAGE_STATE_MAX_ENTRY \ >> + ((sizeof (((GHCB *)0)->SharedBuffer) - sizeof (SNP_PAGE_STATE_HEADER)= ) / sizeof (SNP_PAGE_STATE_ENTRY)) >=20 > Can be dropped I think, after applying patch #6 BaseMemEncryptSevLib > does not use SNP_PAGE_STATE_MAX_ENTRY any more. It gets used again in patch #9 for the exit optimization support. Thanks, Tom >=20 > take care, > Gerd >=20 -=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 (#116050): https://edk2.groups.io/g/devel/message/116050 Mute This Topic: https://groups.io/mt/104512946/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-