Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D18BBC6FA9D for ; Wed, 1 Mar 2023 15:31:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230318AbjCAPb1 (ORCPT ); Wed, 1 Mar 2023 10:31:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53370 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229891AbjCAPb0 (ORCPT ); Wed, 1 Mar 2023 10:31:26 -0500 Received: from NAM02-DM3-obe.outbound.protection.outlook.com (mail-dm3nam02on2047.outbound.protection.outlook.com [40.107.95.47]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 94ADC42BD3; Wed, 1 Mar 2023 07:31:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IortEY3UGlD6IWnv1VVwDFtrCaGGfIr7MhGKehh1SwNK34ReRYMwY2Svn+ZScTOqB2JfoBn0ndKM0LpLnXLSNCcmoMtqfCzwQGUutn9F+u+NHF1wEBEweXTrw4snFrXgCa6+da6Emsrqc8b5kiHGhXyRCSUPPChu9UVIYINNU7llyvYYBU1lqZ2ZvywgNmL+LW8+NHy/Li6LWzxNZzY1KwsLIuVZ2cmyHsybSIeQOX+vTc7J5JRFQJLsYQNubKVTmhItKI3FCyAl1QMFyeC2/jdidfyskSFRHPNMKR4B2F0VGZzgNm09jQ4b7Mbst8dawSJxFFrrz+WR9g3YVT8qBA== 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=tCgITldxH85lTmFRR0DXpctZfqmv0jvh34t5wy2kd/Q=; b=OLrCxIaUsDiRBIqfziXzw0Jl6pXW+ItE1eSlbF/DiYw7Llk2//7bLH2nGuuCiM0ej+u3tVBpoBzrtGp7fK8MWSwbYUcJqZXq3Fl8GLn3bSg0ghKiFvJqXUVw12wT3tEXOAY9bXrJeJIO56tpJhzM2g5mlZjkotaF4PwO7/Z4PFJZ2jmb/fRoQAkNAq9cWsOHNx1tR9vIVoGvs/ZD7X3TwDgK8l2CliAn5uuX+xahyBHnBW4SkWDx2Dw8E8z82usyvOxP6LRFQo958qlCHFGClvMvro/86QESlx+2FV/bFDHrW+T3+7r6hZanSgwAL3Dv4jThB8b+jkTpI4lVvme8cw== 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=tCgITldxH85lTmFRR0DXpctZfqmv0jvh34t5wy2kd/Q=; b=zfi1JKxpsuxH+n3MdcwNxlLc/Na7ko/aTa1OFM0dksDuBDr4tGtqL349u1uUPiby+OI0zGLtWbW81kzjiqkxXFF0uplxYdS7gWrZCqKqt0laUwSoyeOl4C6n+jamLIEE4nIrrlTYf03D0a88BZw1pzOZtcwrPTbOAQlu0fWFdb8= Received: from MN0PR12MB6101.namprd12.prod.outlook.com (2603:10b6:208:3cb::10) by MN2PR12MB4048.namprd12.prod.outlook.com (2603:10b6:208:1d5::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6156.18; Wed, 1 Mar 2023 15:31:21 +0000 Received: from MN0PR12MB6101.namprd12.prod.outlook.com ([fe80::a4e:62dd:d463:5614]) by MN0PR12MB6101.namprd12.prod.outlook.com ([fe80::a4e:62dd:d463:5614%7]) with mapi id 15.20.6156.018; Wed, 1 Mar 2023 15:31:21 +0000 From: "Limonciello, Mario" To: Hans de Goede , "S-k, Shyam-sundar" CC: Mark Gross , "platform-driver-x86@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: RE: [PATCH 1/2] platform/x86/amd: pmc: Add a helper for checking minimum SMU version Thread-Topic: [PATCH 1/2] platform/x86/amd: pmc: Add a helper for checking minimum SMU version Thread-Index: AQHZTE+38ckCb6quDUqXBktiSELovq7mDEYAgAAAKIA= Date: Wed, 1 Mar 2023 15:31:21 +0000 Message-ID: References: <20230301150821.9791-1-mario.limonciello@amd.com> <846d6f46-07ab-4d4a-5623-417a469c3d0b@redhat.com> In-Reply-To: <846d6f46-07ab-4d4a-5623-417a469c3d0b@redhat.com> Accept-Language: en-US Content-Language: en-US X-Mentions: Shyam-sundar.S-k@amd.com X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_Enabled=true; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_SetDate=2023-03-01T15:31:19Z; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_Method=Privileged; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_Name=Public-AIP 2.0; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_ActionId=270e0803-737a-464e-97bb-e52ec36807ec; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_ContentBits=1 msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_enabled: true msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_setdate: 2023-03-01T15:31:19Z msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_method: Privileged msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_name: Public-AIP 2.0 msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_siteid: 3dd8961f-e488-4e60-8e11-a82d994e183d msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_actionid: 05fdc8ce-48a4-406c-93c6-6f0b09cc418f msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_contentbits: 0 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: MN0PR12MB6101:EE_|MN2PR12MB4048:EE_ x-ms-office365-filtering-correlation-id: 8cb41336-3893-41f8-b845-08db1a6a0250 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: h1wc1wqqFrBpKqkvMqBessCQhzR8aRNgjcEeAB8hCB99uhsNx0+6jIJ6pd3yrzw3/5/pd2JudV3rNNhc/gF7EvplfrZhFFRCSBrnZ9MRWTkvxgOOKLRqcFiuRZO7KzJ/W1JESjqgA2SHMaq/xTpbAWwwCyyyjRyguV3RcSEMRONLsiLWEuGgmLmcZaJYcSwkivBov/7LuQgdo5CupP+VUVsfSUp/jGP/2GfUZgmOCzcbLF87+z7+QksL//gS31Ml+8gB1H7Q7W3OL99RF0p8NXn2VQVECFHEfIrdmHYTuBwLzp1pwlvTVNxQcjwvXjDoQOh47h+cS5GGTJwQu61gXyCryCjgoccWb9mgnvoLeEGondd1tz4HK8yJnfAt3FBH2jPZ2xnLlWZjydEo+ehTZ7Y0agCIGcMhlwUhjLrhKlYj/8iiElTCVZczSnMOonPduaOi28HLyS5XIBNpZD8ZvyMvpD3H5IcNEDz7TyPws/S7ZwtQBYkQavAi7PzpDPnfxrd0Vzb1YkGSAlLJKRUGg0PEg0I7ww2pMMOMNp9TrIbIkyxvjvj4BusX5UpFYQHCt97N5/ye5Roa1YEpvJBQBiIazDb4rZM8z97OZRjzFxSgidJCV6cNxRWpweOpxLnB7624tAuZhxlgPa/yeZCjz89fMxGG3WUxuN6LqRHWR6bD5ZYJF9ez76hFzKGiB3ttrzLx9AQ/dMoeyP0kb9j0Tg== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MN0PR12MB6101.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(4636009)(376002)(136003)(366004)(396003)(346002)(39860400002)(451199018)(5660300002)(33656002)(8936002)(86362001)(52536014)(55016003)(83380400001)(478600001)(7696005)(186003)(71200400001)(9686003)(53546011)(6506007)(26005)(66476007)(66556008)(66946007)(66446008)(76116006)(4326008)(38100700002)(54906003)(64756008)(41300700001)(38070700005)(8676002)(110136005)(6636002)(122000001)(316002)(2906002);DIR:OUT;SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?utf-8?B?STkzdHloWHllNlh6SUtmR1BNNnZUYWF1Z1B1U2tOT0RyMmQrMHp4a0RSZk9G?= =?utf-8?B?cVdMODJsaWIxT3J5b2V3OEFWb1I1Q1lTUzgwajRpYlQ0cFRacldWUTB1VVpq?= =?utf-8?B?TVpxK3F0RGlBSW9GUUdCMThsWFVaQ2RwVXdVRFNDYVJYT2cxaEsrQjlITHdW?= =?utf-8?B?OHlDZmlNQWV3RktqNHhxazZwM0dyN1Y0ZFVFejQvZHJ1TTV4Q0RQbmp6bWxZ?= =?utf-8?B?Y3U0OFArdTBudHVqNEtheG9vbTNmLzRWdll4VFk2d0J1dnJwZHk4UUNEMlBv?= =?utf-8?B?ZHdHblo2QVc0R1hEUXlPUGsxTjRYcnJydTErM3QvM2tVakNtRVVOU09RNmxy?= =?utf-8?B?SnhvQXlwMjBRcnpJQWwveS9sbmR6R3BMenhrWk9pZmJJOGdqd1hoOW1PNlUr?= =?utf-8?B?d283aE1WSkZGMmhBRFFJSnB6eTkzZjBuQVd2THRDVFNFaDFMdnMzczc4dkRm?= =?utf-8?B?QjlEd2F4N2EvN2lXT3RlOTgxMUk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Z0FVUUJ0dkt0VURSM3h2RTJtTmtBWFRUWkFBWDBGREpM?= =?utf-8?B?dHB3MHNoVGJlcnhrSzc1bWdoakVHeXV4aGY4L2RFUzI0L0pQOVBkbWZFZ2RN?= =?utf-8?B?Y29JdTRVR2NrRXRRVTJodG9VWlZ6REl4UGZFVVlUc0VscUlVbG0vTGg5YVA3?= =?utf-8?B?ZmNhaS8xODFWbnFZWlcvdkUxMEQydkNIYVh3b2h1bVV4bktjV200Y2ZxQmhO?= =?utf-8?B?ekRSVDE1cTFWRGE5ZE9jNTBqTUl2LzVQeWx5STFSdjNQb3UzOWUxWCthSVZM?= =?utf-8?B?ZXVENjJTeVMvbUtmdGV6MHZKcFdIaWI2M3ZBUThQbjhITzdQajg5RDZEdUww?= =?utf-8?B?bkJ4czIrazNXajNPdXROcW8rT3FGZXZRREQrQ3Flb1dPRDFBOUlJbG5mRlZB?= =?utf-8?B?L3huam1ucTdHdks2Zzg1d0JnbWdPVGlGU1ZSS2JBOU5BYnZNUUJ0VHpCWklr?= =?utf-8?B?QmF0ZE9SSTVQOU5hQUphOVljOVcyMzJub01RY0JzMU5tdnZjWkszTnFBWDFi?= =?utf-8?B?SmdsNzNxRnI4UzJDUWYxOVVPOU1OT2NGMHlrek5MbnNpV0QvNzBZRlhaMCtk?= =?utf-8?B?VEF4U2N2TE1rYXRXMmx6NHFBVk9jR2M0aWI5Qmx1V3hSWlF3WnhHQitpZEdC?= =?utf-8?B?QUY0aXpNR2c4bzBuV1dZVjF0YS92RXJFbFozM2ptZUJUditLd1hjMCs2bWFr?= =?utf-8?Q?iR44=3D?= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MN0PR12MB6101.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8cb41336-3893-41f8-b845-08db1a6a0250 X-MS-Exchange-CrossTenant-originalarrivaltime: 01 Mar 2023 15:31:21.0600 (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: 23guxBT8Y7VBOBaNuZprv1b+Ls0VRfGAP/hW5SX06MpwSlqP7XObJeFzCe9mNAA1cjCiCaBeHQNVrPBtHV2n5A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB4048 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org W1B1YmxpY10NCg0KDQoNCj4gLS0tLS1PcmlnaW5hbCBNZXNzYWdlLS0tLS0NCj4gRnJvbTogSGFu cyBkZSBHb2VkZSA8aGRlZ29lZGVAcmVkaGF0LmNvbT4NCj4gU2VudDogV2VkbmVzZGF5LCBNYXJj aCAxLCAyMDIzIDA5OjI4DQo+IFRvOiBMaW1vbmNpZWxsbywgTWFyaW8gPE1hcmlvLkxpbW9uY2ll bGxvQGFtZC5jb20+OyBTLWssIFNoeWFtLXN1bmRhcg0KPiA8U2h5YW0tc3VuZGFyLlMta0BhbWQu Y29tPg0KPiBDYzogTWFyayBHcm9zcyA8bWFya2dyb3NzQGtlcm5lbC5vcmc+OyBwbGF0Zm9ybS1k cml2ZXItDQo+IHg4NkB2Z2VyLmtlcm5lbC5vcmc7IGxpbnV4LWtlcm5lbEB2Z2VyLmtlcm5lbC5v cmcNCj4gU3ViamVjdDogUmU6IFtQQVRDSCAxLzJdIHBsYXRmb3JtL3g4Ni9hbWQ6IHBtYzogQWRk IGEgaGVscGVyIGZvciBjaGVja2luZw0KPiBtaW5pbXVtIFNNVSB2ZXJzaW9uDQo+IA0KPiBIaSwN Cj4gDQo+IE9uIDMvMS8yMyAxNjowOCwgTWFyaW8gTGltb25jaWVsbG8gd3JvdGU6DQo+ID4gSW4g YSBmZXcgbG9jYXRpb25zIHRoZXJlIGlz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