From patchwork Mon Jun 13 19:29:51 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 12880144 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 13262C43334 for ; Mon, 13 Jun 2022 20:39:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235349AbiFMUjG (ORCPT ); Mon, 13 Jun 2022 16:39:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38018 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235651AbiFMUiW (ORCPT ); Mon, 13 Jun 2022 16:38:22 -0400 Received: from NAM11-BN8-obe.outbound.protection.outlook.com (mail-bn8nam11on2064.outbound.protection.outlook.com [40.107.236.64]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 505425B8BE; Mon, 13 Jun 2022 12:30:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lffT+0SiOwUqdpeaigq9eJ4bEPRoSlAX6OLr+N1AO6ieKz71r00IH6tWq/7XVJWo9Uu2nZDqsbhbdYZdzbQfBeg+5H8LA9rIiuSS8BKqWK47GgVt7bCY5opNc9xT8jHpIpJ9oyjyj7kkSI7S3SUFRgc8fWSKcDuISwIJXsd739kw3lxtpTEMkxoG0DxYSRGHAEzTJPvvy/gx+X1/NObLm8Iv9FkQwvbLw5KXxcV70HFJooFIyOZQL1wKfwEopvKDLXhF95LpNajzoRNVvJMKr0LUSwu7JdPC1RZ3OwX5OfxzXCqdWmmThXidsPDXAMo7PuqD9YSWJEMgmoO1sm5mPg== 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=z/spjDC00QYSd9p/8Tzq2Gc0e1UPeda46ywch49DRg8=; b=naPWt25BWKgqHUnaBaIrYbo6qFscSOWA0W6PeCBPESbD11QDThyG3jf5VadaCRA3yYK6SUF2WIqLfuNRVPtR//z+odqi+79Wqwgno2RvF1ioxJoEcC+Ucl/UacPpZtk1vRp1p+9jW/r5/czaEuevXCF8qNfUmbIwvcun81MvaBgDPCx5w8Y7br0csHLvI4udicovn7ALchke909cYvf2vGkJ78b2e7mjZeCP/DJLe2iWua4LelfNK9e1YYEmiHeECNiIssW3MbXRJb3BOvQ01U54ElAH7sYOHf8AS5T4MXdUJctur1LOgCabKwiuXJS/giR3xehFwp6EWfblN00y/A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=ladisch.de smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); 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=z/spjDC00QYSd9p/8Tzq2Gc0e1UPeda46ywch49DRg8=; b=tXKLPRLbxgjKGUxSbXNBOxA9nfaCegmabF6Qk72cSDhHzqiy3KSimCW9QeTJZRUp+3OJoKKXViVlaR0u94ify5Lzoi/mRjFPibzEQjqIVAUu8eApBdbdYpEj+un6Kef4Z3swzErjR7VP2aQqDnjfGA7dUXQ7nTjdZCwCHoA1BtY= Received: from MWHPR01CA0029.prod.exchangelabs.com (2603:10b6:300:101::15) by BYAPR12MB4759.namprd12.prod.outlook.com (2603:10b6:a03:9d::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.13; Mon, 13 Jun 2022 19:30:11 +0000 Received: from CO1NAM11FT010.eop-nam11.prod.protection.outlook.com (2603:10b6:300:101:cafe::5e) by MWHPR01CA0029.outlook.office365.com (2603:10b6:300:101::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.13 via Frontend Transport; Mon, 13 Jun 2022 19:30:11 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT010.mail.protection.outlook.com (10.13.175.88) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5332.12 via Frontend Transport; Mon, 13 Jun 2022 19:30:11 +0000 Received: from AUS-LX-MLIMONCI.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Mon, 13 Jun 2022 14:30:08 -0500 From: Mario Limonciello To: Clemens Ladisch , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "H. Peter Anvin" , Bjorn Helgaas , Yazen Ghannam , Mario Limonciello , Guenter Roeck , Muralidhara M K , "open list:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "open list:PCI SUBSYSTEM" CC: , , , Subject: [PATCH v3 1/6] x86/amd_nb: Add AMD Family 17h A0-AF IDs Date: Mon, 13 Jun 2022 14:29:51 -0500 Message-ID: <20220613192956.4911-2-mario.limonciello@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220613192956.4911-1-mario.limonciello@amd.com> References: <20220613192956.4911-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c45ae4fb-2984-47f9-f016-08da4d732208 X-MS-TrafficTypeDiagnostic: BYAPR12MB4759:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: /DcT1X1ykMladwLnm6CDOiMrW4MfHLW3UKnKBu36rmFEd/kCaHa5MqD3dklzEX93w+bU11RQDp8PrIyrlWFu/pkq323sNRARkY8t4yTcMAsxK0vnFrmGiQShbRenTOVpdeqkQg6yke38cicHrO4nTkvvCC5iUcS00QjqodHhymQ8xIopjBRhTIc1Oc/4lo12qC5RZxAR9aibjgg3/4oh0hey24RwwJUMJyUEbiByIA0kbxYs/UbfA5RriCzfhlZ3s0cAo2i+QH158Znk6yBfOM8PONlyyR/xnf7b9BGYnJd2nD8gLDO/93zh56V5QnpoH0cqEUu+bl5wm+n8G2E/SwGzZ2NdePUHvdyfCuMPFsuqaUE5cHUrL1HP0ga/m8dxaNhhUg+Ru8Hx//6gNEkBFVQLLo6pe2IfBUvEG6MCZ/loC2ur+wtMqLkaDfRAfJbozSlB9b67h9MjQUBWm1r5cThqIhGgtMBOMGgmqHhzVA3PP5jcGcHbC/BN8jcplfB/9hser2FlmqR8iatjwuvnpkh7yl4i2rOkCnA81BUBZmqtzmLuHa1vQiqniIH9dCqkVHNR8b7YPr9Xws+9P42Lx96BpcBfvHMvJo9pD2EXqayUHLCLWMiK6xNyXG34HX9PbTOSUDmYuCro4njsDHy7e3q070lLzWNxySmNByb3wnm985knskCpiR7OKEKuz8U1X7BM82ODH9bLCPQzwsYeEdzXghlxXdc0cLLAKkKyuKk= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230016)(4636009)(40470700004)(46966006)(36840700001)(8676002)(4326008)(6666004)(2906002)(70206006)(70586007)(7416002)(44832011)(5660300002)(26005)(40460700003)(8936002)(508600001)(7696005)(186003)(36756003)(86362001)(36860700001)(110136005)(81166007)(356005)(921005)(1076003)(47076005)(16526019)(426003)(336012)(2616005)(316002)(82310400005)(54906003)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jun 2022 19:30:11.2060 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: c45ae4fb-2984-47f9-f016-08da4d732208 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT010.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB4759 Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org Add support for SMN communication on Family 17h Model A0h. Signed-off-by: Mario Limonciello Reviewed-by: Yazen Ghannam Acked-by: Bjorn Helgaas # pci_ids.h --- arch/x86/kernel/amd_nb.c | 5 +++++ include/linux/pci_ids.h | 1 + 2 files changed, 6 insertions(+) diff --git a/arch/x86/kernel/amd_nb.c b/arch/x86/kernel/amd_nb.c index 190e0f763375..60c7bd525237 100644 --- a/arch/x86/kernel/amd_nb.c +++ b/arch/x86/kernel/amd_nb.c @@ -19,12 +19,14 @@ #define PCI_DEVICE_ID_AMD_17H_M10H_ROOT 0x15d0 #define PCI_DEVICE_ID_AMD_17H_M30H_ROOT 0x1480 #define PCI_DEVICE_ID_AMD_17H_M60H_ROOT 0x1630 +#define PCI_DEVICE_ID_AMD_17H_MA0H_ROOT 0x14b5 #define PCI_DEVICE_ID_AMD_19H_M10H_ROOT 0x14a4 #define PCI_DEVICE_ID_AMD_17H_DF_F4 0x1464 #define PCI_DEVICE_ID_AMD_17H_M10H_DF_F4 0x15ec #define PCI_DEVICE_ID_AMD_17H_M30H_DF_F4 0x1494 #define PCI_DEVICE_ID_AMD_17H_M60H_DF_F4 0x144c #define PCI_DEVICE_ID_AMD_17H_M70H_DF_F4 0x1444 +#define PCI_DEVICE_ID_AMD_17H_MA0H_DF_F4 0x1728 #define PCI_DEVICE_ID_AMD_19H_DF_F4 0x1654 #define PCI_DEVICE_ID_AMD_19H_M10H_DF_F4 0x14b1 #define PCI_DEVICE_ID_AMD_19H_M40H_ROOT 0x14b5 @@ -41,6 +43,7 @@ static const struct pci_device_id amd_root_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M10H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M30H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M60H_ROOT) }, + { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_MA0H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M10H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M40H_ROOT) }, {} @@ -61,6 +64,7 @@ static const struct pci_device_id amd_nb_misc_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M10H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M30H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M60H_DF_F3) }, + { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_MA0H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CNB17H_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M70H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_DF_F3) }, @@ -81,6 +85,7 @@ static const struct pci_device_id amd_nb_link_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M30H_DF_F4) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M60H_DF_F4) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_M70H_DF_F4) }, + { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_MA0H_DF_F4) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_DF_F4) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M10H_DF_F4) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M40H_DF_F4) }, diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 0178823ce8c2..ec1c226d13e6 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h @@ -556,6 +556,7 @@ #define PCI_DEVICE_ID_AMD_17H_M30H_DF_F3 0x1493 #define PCI_DEVICE_ID_AMD_17H_M60H_DF_F3 0x144b #define PCI_DEVICE_ID_AMD_17H_M70H_DF_F3 0x1443 +#define PCI_DEVICE_ID_AMD_17H_MA0H_DF_F3 0x1727 #define PCI_DEVICE_ID_AMD_19H_DF_F3 0x1653 #define PCI_DEVICE_ID_AMD_19H_M10H_DF_F3 0x14b0 #define PCI_DEVICE_ID_AMD_19H_M40H_DF_F3 0x167c From patchwork Mon Jun 13 19:29:52 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 12880140 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 36EEDC433EF for ; Mon, 13 Jun 2022 20:39:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231274AbiFMUjD (ORCPT ); Mon, 13 Jun 2022 16:39:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43342 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235915AbiFMUiY (ORCPT ); Mon, 13 Jun 2022 16:38:24 -0400 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2048.outbound.protection.outlook.com [40.107.243.48]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CDEFE5BD2B; Mon, 13 Jun 2022 12:30:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Old1rWKNbAFtrtlVg+jk+erSr4sEXH/asyflPKpJcL9ywWHWMUCWKjFkI1UM7oSqwUik/pseVKtXt54VrjUqb1bb6lRon1yL5x7I4q3I5d3MXRLw/DMZDeBjmpiao/uSDKxugCX/OXl5bBZGbpxDu4jksPzeLLESnDi0uTqoqHtosVkzUMhABU+GrDcpbgGdLs0W9OJK59ekpGNn+lLn7npASfaU3n+gpGA/9/Z3lQSF4Q5w8O5u+5+RUF5rJU5WZjo5okwzTaP9n2szvwS7//9FM95LKWacA4gB68RRY431Gs/Y9fj2uJSvQX28hqH0Np/SgwqDFJcKDo0CNDAM+w== 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=Ulfuzw05oiyPgZjysKx2jk0oon55GmjWqqqtDykRQLE=; b=m3n/F9WFT4UkKcFMtyTasPPgf/mjYkVRPqoPo1rc1EWhVuLpKkixt10eXDeDOonIvlBGxVpmYMVo/0BrXHLcjJIldn7JMfXx7ZFLBUfImM2rB9BJsi0aQmcuUZCYrDvk9bPfTfVlK2R5TdlhGrO4KgAL4V7ll5TrbqCUfosbZdtsP+VEJOmbKHkvmUqPiniTrLE4Lr1x2L2rVIHt6rL7ASgvj1FTHaVqvbaxvvB8UYTmF0gC2ieB83UYt/+eH/C8aOSlmovttPrYJaY9BjHP5OdYo/AEqOpgBeNlmEbipnDtZb3xyp0rocbniMJUsIXxq2lWoQYzR1Ioyqi8sGnI8g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=ladisch.de smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); 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=Ulfuzw05oiyPgZjysKx2jk0oon55GmjWqqqtDykRQLE=; b=NTcLJXr8Rgg3iJmPDIvFCXb8SmiOPdU8w4GklySUToiD5W7b3iBwD2Cu/YOwTG+i6D+0c/3wysqOcrclULlab/7xyDSKDQYE3mzXSsdnE+GSSbCF6dI/0U4aP6c24+XSx4H8AKU5O6MyK6E/8gCIKc1yLSwmFLocen3Rw8ddQQE= Received: from MWHPR01CA0031.prod.exchangelabs.com (2603:10b6:300:101::17) by CY4PR1201MB0231.namprd12.prod.outlook.com (2603:10b6:910:24::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.20; Mon, 13 Jun 2022 19:30:12 +0000 Received: from CO1NAM11FT010.eop-nam11.prod.protection.outlook.com (2603:10b6:300:101:cafe::21) by MWHPR01CA0031.outlook.office365.com (2603:10b6:300:101::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.14 via Frontend Transport; Mon, 13 Jun 2022 19:30:12 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT010.mail.protection.outlook.com (10.13.175.88) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5332.12 via Frontend Transport; Mon, 13 Jun 2022 19:30:12 +0000 Received: from AUS-LX-MLIMONCI.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Mon, 13 Jun 2022 14:30:10 -0500 From: Mario Limonciello To: Clemens Ladisch , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "H. Peter Anvin" , Bjorn Helgaas , Yazen Ghannam , Mario Limonciello , Guenter Roeck , Muralidhara M K , "open list:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "open list:PCI SUBSYSTEM" CC: , , , Subject: [PATCH v3 2/6] x86/amd_nb: Add Family 19h model 70h-7Fh IDs Date: Mon, 13 Jun 2022 14:29:52 -0500 Message-ID: <20220613192956.4911-3-mario.limonciello@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220613192956.4911-1-mario.limonciello@amd.com> References: <20220613192956.4911-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2ca3e660-e59e-487e-348d-08da4d7322b2 X-MS-TrafficTypeDiagnostic: CY4PR1201MB0231:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 4hnFGVwzabkAhW5zk+icUgYXT5W9bnHOeBwMY9HWscRKN0vS6ce5fZ9SV3AJBeFtYXkFDEahv4gbuyBekuxv+dZvK4ll2J57kO5vqBBn/HPEpw4cqshoHHX7YvzPX6KloU9/LujevQkw2DHtufND/4Xw3PZp0lIzqEjSWZrgttJowqNUnEU9he7RYR2oJ+ioNmriLB4H4L2TadUHYqJuVK+kCrCs9flvta4ocuC49gv28BZZh2GUJ6ik5RSijdYrdO28zsfJqnYPwXX5nkfSlPyQ+6K6wxuhoJAg7XYc5Lsb5QR0ashyppu1Cfsu4se9+ZGk7u378xXoEOuaTkiItquyxiuXp0z7PNaU9cEJ7mgJB2VnaxtllyZVUdf8ZL233TDYRkFAAbgQr5Eza4cT34Oec7PtWdKJEUyWm1CkLtKuvggPnyO7ytDlqsjBP1Apiise1N5hyfoIQsVN5ElEbCeNjjwwpsPz8I0WcLzY/mGBnrJQGAN8owRyFHwOBHlmEkROxAzA1ti+4i4aQM8Xju/JNUtgf0yygOXTyuShAKyeOoZ+oPAkwMbLcyKQKTLTC516S2gwDwlCw/RTlqMXwcGNTrrF8ot+kzRCwXFpTrETiUv80dcXX2HQ6jABlSuku3we/VVdYd0Pg1iSeHcXd3LMqTWd7FcjJvRli8AEY5a1mPyi6soCOMXiIPhRp5v7wmIA4KnMF4vbd3A0X2gkOc71iJ5+QRuNN3Q0/4zjFgI= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230016)(4636009)(36840700001)(40470700004)(46966006)(82310400005)(36860700001)(86362001)(26005)(356005)(316002)(921005)(40460700003)(81166007)(508600001)(44832011)(2906002)(7416002)(8936002)(5660300002)(8676002)(70206006)(70586007)(4326008)(47076005)(426003)(336012)(1076003)(16526019)(186003)(6666004)(36756003)(2616005)(110136005)(54906003)(7696005)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jun 2022 19:30:12.3153 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2ca3e660-e59e-487e-348d-08da4d7322b2 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT010.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR1201MB0231 Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org Add support for SMN communication on Family 19h Model 70h. Signed-off-by: Mario Limonciello Reviewed-by: Yazen Ghannam Acked-by: Guenter Roeck --- v2->v3: * Pick up tags * Move "ROOT" declaration to match others arch/x86/kernel/amd_nb.c | 4 ++++ include/linux/pci_ids.h | 1 + 2 files changed, 5 insertions(+) diff --git a/arch/x86/kernel/amd_nb.c b/arch/x86/kernel/amd_nb.c index 60c7bd525237..cb7a40378ed3 100644 --- a/arch/x86/kernel/amd_nb.c +++ b/arch/x86/kernel/amd_nb.c @@ -21,6 +21,7 @@ #define PCI_DEVICE_ID_AMD_17H_M60H_ROOT 0x1630 #define PCI_DEVICE_ID_AMD_17H_MA0H_ROOT 0x14b5 #define PCI_DEVICE_ID_AMD_19H_M10H_ROOT 0x14a4 +#define PCI_DEVICE_ID_AMD_19H_M70H_ROOT 0x14e8 #define PCI_DEVICE_ID_AMD_17H_DF_F4 0x1464 #define PCI_DEVICE_ID_AMD_17H_M10H_DF_F4 0x15ec #define PCI_DEVICE_ID_AMD_17H_M30H_DF_F4 0x1494 @@ -32,6 +33,7 @@ #define PCI_DEVICE_ID_AMD_19H_M40H_ROOT 0x14b5 #define PCI_DEVICE_ID_AMD_19H_M40H_DF_F4 0x167d #define PCI_DEVICE_ID_AMD_19H_M50H_DF_F4 0x166e +#define PCI_DEVICE_ID_AMD_19H_M70H_DF_F4 0x14f4 /* Protect the PCI config register pairs used for SMN. */ static DEFINE_MUTEX(smn_mutex); @@ -46,6 +48,7 @@ static const struct pci_device_id amd_root_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_MA0H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M10H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M40H_ROOT) }, + { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M70H_ROOT) }, {} }; @@ -71,6 +74,7 @@ static const struct pci_device_id amd_nb_misc_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M10H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M40H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F3) }, + { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M70H_DF_F3) }, {} }; diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index ec1c226d13e6..32a1f85ff0de 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h @@ -561,6 +561,7 @@ #define PCI_DEVICE_ID_AMD_19H_M10H_DF_F3 0x14b0 #define PCI_DEVICE_ID_AMD_19H_M40H_DF_F3 0x167c #define PCI_DEVICE_ID_AMD_19H_M50H_DF_F3 0x166d +#define PCI_DEVICE_ID_AMD_19H_M70H_DF_F3 0x14f3 #define PCI_DEVICE_ID_AMD_CNB17H_F3 0x1703 #define PCI_DEVICE_ID_AMD_LANCE 0x2000 #define PCI_DEVICE_ID_AMD_LANCE_HOME 0x2001 From patchwork Mon Jun 13 19:29:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 12880141 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 4DA50C43334 for ; Mon, 13 Jun 2022 20:39:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232846AbiFMUjE (ORCPT ); Mon, 13 Jun 2022 16:39:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43544 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242497AbiFMUi0 (ORCPT ); Mon, 13 Jun 2022 16:38:26 -0400 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (mail-bn8nam12on2084.outbound.protection.outlook.com [40.107.237.84]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5735E5BE57; Mon, 13 Jun 2022 12:30:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=OYEkoRqvqQ4vL61CXRe1QK6R4ORa746YJIbxw93lw4mllfMKkoHVHL8lyuxMa9Htl8wyJCOoUGoWctS6jW9oJGpyoVnot4KTu5wVhNNO2zuGHE3fncKAk21gdNyUxke11e9VSIoPqrxSvtlpXejOAizPstBw9oGUQGKRTvtc2cEQFBJqKIjsQwVlSJ44JTH2R6IiFBp+RenNIniz6kphPu7tMkbR5lwkjaUTYQJx4coldGua36j75X+bENG25qi5G9HqVkI0JGr1tjxoLCuFLKULZ+N8Fkyy5OocqBTDUji8wQB92DVn4p7la4HMND7vVkPuAGD3BCogHuf0uqnhbQ== 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=7IKQ8HtSuexS2DKi3KU9//b4rAAr99NK6swvTkNc+ao=; b=lBgNSBv10+heSlcUNiDGopXIp8VV8kr4HdN9pv3ChK6PXYODN1K2i3eoUi6vFoxQJCZoTgExEAG6Uu0uxn5V5uOFm3XisYvsaJYApysUJt96R5qzUnT0nI76bcpOO32HppmPc+119qIVjJXeXI5wWk1QLUjBLlhs+uAu0iye0RdBUe3snra210FYIdJrEgEACBhdm5kow3vCP2edQnYvLG0bmgpPl8GkqfdSANd6sz84Zza1C9M23x9qK+RtSiaHAlo9gcjqhQLrvvs3m6hAl2wEMayjHvkyP19RE4Z84gx4UhDr0U3wHoM3OfRjE1luqfL1+VIBLmUDLgSMk8M16A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=ladisch.de smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); 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=7IKQ8HtSuexS2DKi3KU9//b4rAAr99NK6swvTkNc+ao=; b=jzVu9v827kTSjm/C88Ru0CHoVFxYRcpGQiJvA/WTYhawn+fpLauEoLt/r09uKGlVkomF5cWZeZ/AU9OqiAOTnEg5YbEMWtTnzuEAZv20vkOZRwo2VHdQmbjW/dwL2dn7L6l4+24pJ/2rThjDkTpdFnOgEv9lgumoFGEoDX92ut0= Received: from MW4PR02CA0018.namprd02.prod.outlook.com (2603:10b6:303:16d::17) by SA0PR12MB4493.namprd12.prod.outlook.com (2603:10b6:806:72::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.13; Mon, 13 Jun 2022 19:30:18 +0000 Received: from CO1NAM11FT067.eop-nam11.prod.protection.outlook.com (2603:10b6:303:16d:cafe::9e) by MW4PR02CA0018.outlook.office365.com (2603:10b6:303:16d::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.19 via Frontend Transport; Mon, 13 Jun 2022 19:30:18 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT067.mail.protection.outlook.com (10.13.174.212) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5332.12 via Frontend Transport; Mon, 13 Jun 2022 19:30:17 +0000 Received: from AUS-LX-MLIMONCI.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Mon, 13 Jun 2022 14:30:13 -0500 From: Mario Limonciello To: Clemens Ladisch , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "H. Peter Anvin" , Bjorn Helgaas , Yazen Ghannam , Mario Limonciello , Guenter Roeck , Muralidhara M K , "open list:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "open list:PCI SUBSYSTEM" CC: , , , Subject: [PATCH v3 3/6] x86/amd_nb: Add Family 19h model 60h-6Fh IDs Date: Mon, 13 Jun 2022 14:29:53 -0500 Message-ID: <20220613192956.4911-4-mario.limonciello@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220613192956.4911-1-mario.limonciello@amd.com> References: <20220613192956.4911-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 74733680-bcb6-4a94-4c00-08da4d7325d8 X-MS-TrafficTypeDiagnostic: SA0PR12MB4493:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: oSNJTGMpxRV00fNzddUORG3h23M6+9p447XlRLoKdKzfSsdGpE7NpkLjE/4ET8rR5eH0/iImwSRORknqVn1EwtIHlCTlTN1CV9IhUCSrTqG19DpeCVCflX0fjfUNbyqoTwlA4rje6Gcy4GzPbut1/Rt5nvKpo9Bet+PQCH2Lxma59ozctqwOfasDXgSlwoHc+kYdUp7lZeeB4v8xla33xDRPiaOI2W+DCutHoPzf727xEHEo9ceTn4IVfVcJhC22SOCbh8BV3ePBbN4bVvQriWA/R4DOD+9Hh/AtK7UR0TOfTJZbx1/Hj+s+SqJOsPCPlhP5Bj2sy6eBelOCrM+qwatmrg7rp7sXQuGFTe/c6UyyRF5Qj+J+UEEmtVkrHhYz8wZqBC1ieFKRTEMq8y/LSxRIsP61ly7/1ISvpluorlqyQohJC+sHPjEbETc3mCmwcrsmYxVFClo45VEWh9jFlygTXdMk0xSVlfdMYN1FXTAkyl6LVJ0Z4UE9iwSW8Dl8oVSXHYLGggJkTjUyZsrXnBfvF7+AtXqJ0tnFee7SD+VyjgknUWgw5E2Si8Ye1kHbyS5fesXxg/00Y5mIfNEhQcYzOchb6tuNSN6k5ttScEI1mEpwsObEIhaJDHBlOO/h5Nvu3UZnw6m+d2BvaeyibZO+ex3e6wFlQxbkv2ZjH0HUOkUsQVBCbjXJTZH4kOjo3l6GaMeM92Nfbil/VTMqmntIvAXwVryICmozwJvOXwM= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230016)(4636009)(46966006)(40470700004)(36840700001)(47076005)(26005)(16526019)(426003)(36860700001)(7416002)(7696005)(2906002)(5660300002)(6666004)(44832011)(336012)(921005)(356005)(36756003)(8676002)(316002)(54906003)(110136005)(40460700003)(81166007)(508600001)(70586007)(4326008)(2616005)(8936002)(86362001)(1076003)(186003)(82310400005)(70206006)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jun 2022 19:30:17.5981 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 74733680-bcb6-4a94-4c00-08da4d7325d8 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT067.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA0PR12MB4493 Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org Add support for SMN communication on Family 19h Model 60h. Signed-off-by: Mario Limonciello Reviewed-by: Yazen Ghannam --- v2->v3: * Pick up tags * Move ROOT declaration to match others arch/x86/kernel/amd_nb.c | 4 ++++ include/linux/pci_ids.h | 1 + 2 files changed, 5 insertions(+) diff --git a/arch/x86/kernel/amd_nb.c b/arch/x86/kernel/amd_nb.c index cb7a40378ed3..4266b64631a4 100644 --- a/arch/x86/kernel/amd_nb.c +++ b/arch/x86/kernel/amd_nb.c @@ -21,6 +21,7 @@ #define PCI_DEVICE_ID_AMD_17H_M60H_ROOT 0x1630 #define PCI_DEVICE_ID_AMD_17H_MA0H_ROOT 0x14b5 #define PCI_DEVICE_ID_AMD_19H_M10H_ROOT 0x14a4 +#define PCI_DEVICE_ID_AMD_19H_M60H_ROOT 0x14d8 #define PCI_DEVICE_ID_AMD_19H_M70H_ROOT 0x14e8 #define PCI_DEVICE_ID_AMD_17H_DF_F4 0x1464 #define PCI_DEVICE_ID_AMD_17H_M10H_DF_F4 0x15ec @@ -33,6 +34,7 @@ #define PCI_DEVICE_ID_AMD_19H_M40H_ROOT 0x14b5 #define PCI_DEVICE_ID_AMD_19H_M40H_DF_F4 0x167d #define PCI_DEVICE_ID_AMD_19H_M50H_DF_F4 0x166e +#define PCI_DEVICE_ID_AMD_19H_M60H_DF_F4 0x14e4 #define PCI_DEVICE_ID_AMD_19H_M70H_DF_F4 0x14f4 /* Protect the PCI config register pairs used for SMN. */ @@ -48,6 +50,7 @@ static const struct pci_device_id amd_root_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_17H_MA0H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M10H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M40H_ROOT) }, + { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M60H_ROOT) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M70H_ROOT) }, {} }; @@ -74,6 +77,7 @@ static const struct pci_device_id amd_nb_misc_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M10H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M40H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F3) }, + { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M60H_DF_F3) }, { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M70H_DF_F3) }, {} }; diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 32a1f85ff0de..7fa460ccf7fa 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h @@ -561,6 +561,7 @@ #define PCI_DEVICE_ID_AMD_19H_M10H_DF_F3 0x14b0 #define PCI_DEVICE_ID_AMD_19H_M40H_DF_F3 0x167c #define PCI_DEVICE_ID_AMD_19H_M50H_DF_F3 0x166d +#define PCI_DEVICE_ID_AMD_19H_M60H_DF_F3 0x14e3 #define PCI_DEVICE_ID_AMD_19H_M70H_DF_F3 0x14f3 #define PCI_DEVICE_ID_AMD_CNB17H_F3 0x1703 #define PCI_DEVICE_ID_AMD_LANCE 0x2000 From patchwork Mon Jun 13 19:29:54 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 12880146 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 444D9C433EF for ; Mon, 13 Jun 2022 20:39:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237560AbiFMUjI (ORCPT ); Mon, 13 Jun 2022 16:39:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39006 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242614AbiFMUi0 (ORCPT ); Mon, 13 Jun 2022 16:38:26 -0400 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (mail-mw2nam10on2044.outbound.protection.outlook.com [40.107.94.44]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E9BAB5BD3B; Mon, 13 Jun 2022 12:30:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=M0ZHzzv6HO2OpaCSJOHqIokKrBeOI7ZBnF65ttQ+rqdTReM9sh2rlDVZCn2Y6i3DmBzGx83OvdAVhdDkKAFnOotVLn527oBTASQymk5LaNnt4tM2aalJa3C0Y6mXe+I7pb0YQI3kct3rbOQkB1OSOlNY87CiLhJSxExxKxBzaWnfLJBYDGcmsjhgKJhTlw8gnGQxGQvS9jqporJBgKtUpGjzuLQTkXVnGxBUWwyzpQB4V8i5Q683WTqzfUjYEcyPXtYhLahiI0qA5c8KXY2Yh4qtGLE8g4iN2TaGxyJ4a8kac5jStIOaTdbBg17kg63FD4PjiyV8PhynTrGdJWWSwQ== 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=Ap86ihgi4sFANbME5DoVTwCMJLnETl9X8GDDgDSVo9M=; b=GlGUUYv7dE2FwO96OaIetHPdhLaG2+OONzX8kD61HJDKg0xPjUAjXtow/36EbzoK9pxTcWBReIW9hJVs75Ywz3LuHl+GN4Hxo4XqWpEFaAtmaEbPiSLEODDRbNtSDj6Exzjxfs7MS2vrWSpKeyVv9YXq8ECjPw9FXhPK8C38HFZh0K/xauQvhyu063QLY1Bh3QCgoUxlwJjZbvEdmMeVZ+FX4SbYvDB+JRvoGsiWR/eynqDBRPrOfEXQgeetzRWB8qOFmreI8LMkc9A98Y0oxRBosrIjyAj1XI0YtU+mrLPCNpA2O0OdPZD/P7yJylzksXzT347/Z8wngrj+dyTkUw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=ladisch.de smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); 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=Ap86ihgi4sFANbME5DoVTwCMJLnETl9X8GDDgDSVo9M=; b=yuswMt6j1j+n+IsZc4P912ucz6xzPGVtdsDFfuyU9Dy1Xs6JfK2zKwNU/DDb5WBwXwkoXlnRVzzlsxcq6vb4Da3sffXrS2WFhAhG/RMFKwzD53L/Xc2bFMH4ONs/3Us8Z2f4P0xEG244p8Ko2nC5UKg+EnzpuqqH7CudmxZK/tc= Received: from MW4PR02CA0013.namprd02.prod.outlook.com (2603:10b6:303:16d::13) by BYAPR12MB3384.namprd12.prod.outlook.com (2603:10b6:a03:d8::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.17; Mon, 13 Jun 2022 19:30:18 +0000 Received: from CO1NAM11FT067.eop-nam11.prod.protection.outlook.com (2603:10b6:303:16d:cafe::d3) by MW4PR02CA0013.outlook.office365.com (2603:10b6:303:16d::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.17 via Frontend Transport; Mon, 13 Jun 2022 19:30:18 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT067.mail.protection.outlook.com (10.13.174.212) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5332.12 via Frontend Transport; Mon, 13 Jun 2022 19:30:18 +0000 Received: from AUS-LX-MLIMONCI.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Mon, 13 Jun 2022 14:30:14 -0500 From: Mario Limonciello To: Clemens Ladisch , Jean Delvare , Guenter Roeck , "open list:K10TEMP HARDWARE MONITORING DRIVER" , open list CC: , , , , , Mario Limonciello Subject: [PATCH v3 4/6] hwmon: (k10temp): Add support for family 17h models A0h-AFh Date: Mon, 13 Jun 2022 14:29:54 -0500 Message-ID: <20220613192956.4911-5-mario.limonciello@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220613192956.4911-1-mario.limonciello@amd.com> References: <20220613192956.4911-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 889f70b3-a915-44e8-dfa4-08da4d732670 X-MS-TrafficTypeDiagnostic: BYAPR12MB3384:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: cz3iI4Iyvh0NQDA4hWwTq0q5V1mb5KM/zZBV9I1XNPZMo/sJhprtBr+GYRC2iDBjsEuogNAJHqZvFA/S9qrEi92mQtF3houIAlhllHnlHDEIpfIDWFMvi9kkU+sxdhtH9VuwVeMwTWg6Kxp0HBtgdbRoXuXJkKJ9jAzh5Szxn5oxiMG3P+QiADhicv+ciqjnP69bfhWlSZTdHP/5XlZrUvT326nMVa8xRDT/QZLUJFR6TvHgWIxveBidsjsp2h3JP4Limu4Fk03MHNGKBS99Bm16jjZw0FaDLxo8ZB3oglLX+fojs7nM6wUm9xTWDfncsu8ClYjMc6dXtt2kVnHHBxbfi8ujzCiy/PcFs+by7yDZ39GVQzahQIcOnv7EdyizUc5hu8LP1IyCMqFinlWm9190VtJLoZnB2oKGjt50HSn2AtL0N/tJkeY7ti2Fy1P3RL1hwvg4JNmemYrUwEjCD/Gl0fh9wfiYmoajoZqKeVQCQ1CIp36Z+0SForKwPI/SWIwoXHCSh3W+rn8INXzmlTdW+ABYDVjkYCt7NvqesLAlmQxNBEwt9GqEYDGqf8mUGo16uZDprTy4QyqQQGl78cSb3rHCU8NBlg7Su7uNqB0xL9ajCNWBYKH2GEc+eXBKxP6xD3DkE/xoqgq662UjoEQOLLWeaveBA5tVx6T2/3V3SCulkh9RR46vz1KBegSmAlWiiFu5k9/zc+LVL5HNrQ== X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230016)(4636009)(40470700004)(46966006)(36840700001)(81166007)(426003)(186003)(86362001)(16526019)(26005)(336012)(6666004)(47076005)(110136005)(54906003)(356005)(36860700001)(82310400005)(7696005)(8676002)(316002)(70586007)(36756003)(4326008)(70206006)(508600001)(44832011)(5660300002)(40460700003)(2616005)(1076003)(8936002)(2906002)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jun 2022 19:30:18.5980 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 889f70b3-a915-44e8-dfa4-08da4d732670 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT067.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB3384 Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org Add the support for CCD offsets used on family 17h models A0h-AFh. Signed-off-by: Mario Limonciello Acked-by: Guenter Roeck --- drivers/hwmon/k10temp.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/hwmon/k10temp.c b/drivers/hwmon/k10temp.c index 4e239bd75b1d..5f831e74bc51 100644 --- a/drivers/hwmon/k10temp.c +++ b/drivers/hwmon/k10temp.c @@ -428,6 +428,10 @@ static int k10temp_probe(struct pci_dev *pdev, const struct pci_device_id *id) data->ccd_offset = 0x154; k10temp_get_ccd_support(pdev, data, 8); break; + case 0xa0 ... 0xaf: + data->ccd_offset = 0x300; + k10temp_get_ccd_support(pdev, data, 8); + break; } } else if (boot_cpu_data.x86 == 0x19) { data->temp_adjust_mask = ZEN_CUR_TEMP_RANGE_SEL_MASK; @@ -489,6 +493,7 @@ static const struct pci_device_id k10temp_id_table[] = { { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_17H_M30H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_17H_M60H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_17H_M70H_DF_F3) }, + { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_17H_MA0H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M10H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M40H_DF_F3) }, From patchwork Mon Jun 13 19:29:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 12880143 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 69869CCA481 for ; Mon, 13 Jun 2022 20:39:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234922AbiFMUjF (ORCPT ); Mon, 13 Jun 2022 16:39:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43520 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243052AbiFMUi1 (ORCPT ); Mon, 13 Jun 2022 16:38:27 -0400 Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2080.outbound.protection.outlook.com [40.107.244.80]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0A4EB5BE68; Mon, 13 Jun 2022 12:30:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=S5lUxtVdMuJJGHYMBYOiOi6RLslAdNUmW4iALP9qRhtjr1xMpeom9dayeYG3pwQWtl3bryN0ydOGOJkVKEY3fOP1qR+ukBHIAgZ1lrtVTl5gboCn+Mlm0qkCtuONbWbgR52ohv2ulaT0teVbA6nmHRmxq5AJpNh+8BllQODA2BodVH960Xswpa8YOhESPijlRw9gzgGP1BQGWl8MFLQk9n3c+Y+RwWyUA1sknLAOvQNC5pdZx8v3EozptZMApJ4rlUTPk4kXJrFD8Q3/V46AxVFHzedLcbBeW5WI/kCdlrJmr3BH1DgAE73JIYPoGo8zsAtj44Xyxbm+W3A5qRMYdw== 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=PLHJHTH5OQrFcX/JuuUMBpW69SLYm5ZgbDw4u1xvGyQ=; b=XCPoOjRAb2Ljo2M7V3OULkLe5kZPpwMC8zf1QNnIHJlgJfthYHLmEq3PxTrgTp1v7EvWNgla0fWyvXVCkVLDbj+KRDMKozRQA/Ur5qfmTqofItZkumNX4NRcu8c/tvAU5M0bQHG5NYFCWDmurDSuRudwIgTush17TEaCcCPb/51I6GP6PwGqytZO9kzmqU4V3nVkZNgQnaH75zezVG94VMrtfppUUQpqRwZweHZLWjPGoQI+vjnBCIK0/ohNK9A4NnhcB9sCMcw9FXEr07IPSaTlYSVp5pjUJlPwc+yW2IkLwWhe/hToab61MqQifV4+9P1J7BGMgqEK8hpxmJzs/w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=ladisch.de smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); 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=PLHJHTH5OQrFcX/JuuUMBpW69SLYm5ZgbDw4u1xvGyQ=; b=oozHYCbJqTxFWhnQ3lAEXwniUUR9lkzHK2B2fwwn56k92BRaHxT3Y/cL72tR6BnYr+Vx1uhiexDQ6P0nP9uFyXJpAhWW4y1RpMkHjCiScZTftd6XyYDHL0YIxWk6T9YhnIQSBpshE9+Kp9JaN70TwyBDzFfv1eItmAm1h5HvHZQ= Received: from MW4PR02CA0015.namprd02.prod.outlook.com (2603:10b6:303:16d::6) by DM6PR12MB3068.namprd12.prod.outlook.com (2603:10b6:5:3e::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.17; Mon, 13 Jun 2022 19:30:19 +0000 Received: from CO1NAM11FT067.eop-nam11.prod.protection.outlook.com (2603:10b6:303:16d:cafe::e4) by MW4PR02CA0015.outlook.office365.com (2603:10b6:303:16d::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.16 via Frontend Transport; Mon, 13 Jun 2022 19:30:19 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT067.mail.protection.outlook.com (10.13.174.212) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5332.12 via Frontend Transport; Mon, 13 Jun 2022 19:30:19 +0000 Received: from AUS-LX-MLIMONCI.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Mon, 13 Jun 2022 14:30:15 -0500 From: Mario Limonciello To: Clemens Ladisch , Jean Delvare , Guenter Roeck , "open list:K10TEMP HARDWARE MONITORING DRIVER" , open list CC: , , , , , Mario Limonciello Subject: [PATCH v3 5/6] hwmon: (k10temp): Add support for family 19h models 70h-7Fh Date: Mon, 13 Jun 2022 14:29:55 -0500 Message-ID: <20220613192956.4911-6-mario.limonciello@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220613192956.4911-1-mario.limonciello@amd.com> References: <20220613192956.4911-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5471c8ad-79f0-44a3-9e37-08da4d7326d2 X-MS-TrafficTypeDiagnostic: DM6PR12MB3068:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 4SyDEjflxV+I1R2yezU64o4OOLnF8ww6/MKv72BV3FbD/7aKSgXdohaP8ZR1pSEadBIGnDvbwIQAi/Gtq5UAwBixYC4QGBng9rMPvSKsOGtRZYscXbwxD/dNNGJs8Yx8VPnnx84J80G8ov6pO6TgKJadxUbkNYSY1B4paNUgv2DzlTlfNK2F1hkF9VBtZB976pTnG3Py6KG+eqCHUKzW0GcNkfIrMu08LnTdEE0Pf8jPGhq9SrXpkwNF4MdVoSQC2bSwu3Pl+I6EjzUVvg+IE1tJhp75YSIKZHbGxDkaszlxOGmz8/6dy5liyKL1hS8+Afhe0t2rzS/rFn8RHlwTrVzrWNvLsU+GgOu9F3NnByYgJX7Gy9XkQpT/L0H+qS34A1hV1emXfEHZx8yisWx7gL/6E0pJLO/OeU5blCPT1r1jO7xGtApD/Jn3emZBvTV2ZaGFHHgmIJz74qjP/oKyp/uIyq16/GQumHXMSd86YB/wO0TOJ4CNne/nxs7WOznqL0Q/FGgMC4QlGKFnVvf4UsbbiXoCRVFqCUkmyoNeMq7cOe7IwkbrvyT/01SYmWvTV4sHPPMPHAQRUp7/UgGyEWDtOfr4xGbhscCOVxBTcf5mAnhAIJjjQN7pCt2ANWLheRjEXUM3H50U0DNiNirJ7MC2HGBcK4g+Sov1NFfN4YaDFdAFrmhysUJxySoQI37y7a82YIkytVkYZc+bQRvD9w== X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230016)(4636009)(46966006)(40470700004)(36840700001)(2906002)(508600001)(82310400005)(8676002)(36860700001)(54906003)(110136005)(316002)(40460700003)(86362001)(26005)(70206006)(6666004)(70586007)(7696005)(4326008)(81166007)(36756003)(186003)(16526019)(2616005)(426003)(1076003)(336012)(47076005)(8936002)(5660300002)(356005)(44832011)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jun 2022 19:30:19.2386 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5471c8ad-79f0-44a3-9e37-08da4d7326d2 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT067.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB3068 Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org Add the support for CCD offsets used on family 19h models 70h-7Fh. Signed-off-by: Mario Limonciello Acked-by: Guenter Roeck --- drivers/hwmon/k10temp.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/hwmon/k10temp.c b/drivers/hwmon/k10temp.c index 5f831e74bc51..5f37e2e7833e 100644 --- a/drivers/hwmon/k10temp.c +++ b/drivers/hwmon/k10temp.c @@ -449,6 +449,10 @@ static int k10temp_probe(struct pci_dev *pdev, const struct pci_device_id *id) data->ccd_offset = 0x300; k10temp_get_ccd_support(pdev, data, 8); break; + case 0x70 ... 0x7f: + data->ccd_offset = 0x308; + k10temp_get_ccd_support(pdev, data, 8); + break; case 0x10 ... 0x1f: case 0xa0 ... 0xaf: data->ccd_offset = 0x300; @@ -498,6 +502,7 @@ static const struct pci_device_id k10temp_id_table[] = { { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M10H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M40H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F3) }, + { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M70H_DF_F3) }, { PCI_VDEVICE(HYGON, PCI_DEVICE_ID_AMD_17H_DF_F3) }, {} }; From patchwork Mon Jun 13 19:29:56 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 12880142 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 25567C433EF for ; Mon, 13 Jun 2022 20:39:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234045AbiFMUjF (ORCPT ); Mon, 13 Jun 2022 16:39:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43604 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243072AbiFMUi1 (ORCPT ); Mon, 13 Jun 2022 16:38:27 -0400 Received: from NAM02-BN1-obe.outbound.protection.outlook.com (mail-bn1nam07on2072.outbound.protection.outlook.com [40.107.212.72]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 05AF95BE6D; Mon, 13 Jun 2022 12:30:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bFFUtJ67MniHxbq7ZJHIUnhwXmshY+yaw0I7i7vKFn9Ly72UgOBkWmwlCvO86hlLusVZNQMdEfJfuLY5sPXB76ETesCS6pdoJdvF1lz5WxBjmSU5Ucc4WkLN5m9rGob6fherSjYZY4JZdeamz/u328/ICeviZBJRlS5o4rnhycXruledkKY9/ZJ/IfMlIg49jKwD/NDv37f6rLeydc0QYigkFlAlsB1EiIw/rcc63SV+cipqsO948QPQafPmw86WrKCTa1BdfJAusF1LqcEnb5UhRghFiHGPcCNGAlTXy2gTjF4qB3S5cDe85TcaEQOSWI3d1lDTceR0sGBf1iDGXg== 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=/wGQeRE9dB5xVd4zPTqfHRq6QH/Rc6K/GXAjfa6toZI=; b=SyTnrUVte3nOPgASRkND+p6cSgcQf96k55EMSYF7Hmhalpl3KeuPRivEmLBQRWopmsg17Z4jDWfy4fBitsTrW5W9W707p0+KhXUZQW3S5KdGJrihS5QF8j8s3oqE+FnX+AgHs7P/h9bB3WoAI6pCUhZJQNPGEUT2QKBUp9ONrLqd/WK4+1Yx1Ju+leSvv+ybdiSabkLQn59jb1lUmkLKIdXUf3xoY2hmfKOx3e3ec7XbNAxdR8EniKEjh+HcosIoo1yGUKwqr4xldThNadVmcMhHjE5RjIs88cMuESIrxvDtUeL4X9qOmqkqUxuZkfRG9Euk7bAhlLDfxpXSJ8h3ng== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=ladisch.de smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); 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=/wGQeRE9dB5xVd4zPTqfHRq6QH/Rc6K/GXAjfa6toZI=; b=w9/0OTh+ZLeCJdRBWeE+wfhAW38XMHrQsjuB9XQWkcqHYXi5XmWHg494pBsuEUMGTpudBGqJTCCcCPa42nY0F1si7ed7C5osdtZoT29jP1Nx0L9pghb+YL3HKL07OCeKMColoPBwhzXoBiReKxZi0Ht/nleJfRdmwVk0nd60GQk= Received: from MW4PR02CA0016.namprd02.prod.outlook.com (2603:10b6:303:16d::22) by BYAPR12MB4741.namprd12.prod.outlook.com (2603:10b6:a03:a2::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.13; Mon, 13 Jun 2022 19:30:20 +0000 Received: from CO1NAM11FT067.eop-nam11.prod.protection.outlook.com (2603:10b6:303:16d:cafe::80) by MW4PR02CA0016.outlook.office365.com (2603:10b6:303:16d::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.20 via Frontend Transport; Mon, 13 Jun 2022 19:30:20 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT067.mail.protection.outlook.com (10.13.174.212) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5332.12 via Frontend Transport; Mon, 13 Jun 2022 19:30:20 +0000 Received: from AUS-LX-MLIMONCI.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Mon, 13 Jun 2022 14:30:15 -0500 From: Mario Limonciello To: Clemens Ladisch , Jean Delvare , Guenter Roeck , "open list:K10TEMP HARDWARE MONITORING DRIVER" , open list CC: , , , , , Mario Limonciello Subject: [PATCH v3 6/6] hwmon: (k10temp): Add support for family 19h models 60h-6Fh Date: Mon, 13 Jun 2022 14:29:56 -0500 Message-ID: <20220613192956.4911-7-mario.limonciello@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220613192956.4911-1-mario.limonciello@amd.com> References: <20220613192956.4911-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3eb995cb-f0f9-41e1-942c-08da4d73276d X-MS-TrafficTypeDiagnostic: BYAPR12MB4741:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: zi9VVGhA/aYUsTYPxKK2RPOYisSNhuDEeCE+baxqc6e+3ZpSuo3AVgvq1utwvRpFyktd03v3llOWsS4zgvv0Gdtphn/y8GQQvZ48D/mcj3aLlCYY2riTPJqETlLoi9HUf7WXyKWrDxm/KEHIipgq5+nHw3ffUtz1Ozs1TquqfLQlUp4gxoRF4hDMO8n2PSRJYJIxUXdm7S7HAPgFt3o3cTpDWMC6R3sG8kUXXftQGEGuqjjq5x2Ku5loFR941Exfy7vKTL6NctZpVKGbhkEnzEe4W9hx4btZD2/6Rr2r4Pm8aB6N1JfjmH4DjTHZT8frjBDtIptIatbgijlKftXIjjeGq2/Cp96ODf77oxYl4zAYsyfDYWDn04P3kYCljKy/N0dqzviSMhXZGMVHy3kcrvcQIRIb+mAhvA/frtoEjZPJXeLgV05KVtLnSKvrKZLR23LSeEoA0utXBn0XHdBQ0LFfFUzvZN4DXl+v4OJXjIzyK91W/16jgIiwB8i4e8kWcrNpaaKnsP+1fhkN/WqhV5o2zyI2xOMrmRx8Yp4Q2E6ymOIW5xxjA1977BeP7KVbR3d6i525sDHWgQ17t+cFpOzXCgmOcNGbXv4FQr7uPHGk/XyEJVo8Bv+htJKuvy7uZZbn8CTYsc7GFxAfyakweNMahGVeoZdE7WliCYxlxCRHv9audHk8ZWlv9gitYCUj82Y+Lkdz3Sirs4jlCM/ZKA== X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230016)(4636009)(36840700001)(40470700004)(46966006)(36860700001)(54906003)(316002)(36756003)(110136005)(81166007)(16526019)(356005)(426003)(82310400005)(2616005)(186003)(336012)(1076003)(508600001)(44832011)(47076005)(6666004)(8676002)(4326008)(70206006)(70586007)(5660300002)(7696005)(26005)(40460700003)(2906002)(8936002)(86362001)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jun 2022 19:30:20.2542 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3eb995cb-f0f9-41e1-942c-08da4d73276d X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT067.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB4741 Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org Add the support for CCD offsets used on family 19h models 60h-6Fh. Signed-off-by: Mario Limonciello Acked-by: Guenter Roeck --- drivers/hwmon/k10temp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/hwmon/k10temp.c b/drivers/hwmon/k10temp.c index 5f37e2e7833e..5a9d47a229e4 100644 --- a/drivers/hwmon/k10temp.c +++ b/drivers/hwmon/k10temp.c @@ -449,6 +449,7 @@ static int k10temp_probe(struct pci_dev *pdev, const struct pci_device_id *id) data->ccd_offset = 0x300; k10temp_get_ccd_support(pdev, data, 8); break; + case 0x60 ... 0x6f: case 0x70 ... 0x7f: data->ccd_offset = 0x308; k10temp_get_ccd_support(pdev, data, 8); @@ -502,6 +503,7 @@ static const struct pci_device_id k10temp_id_table[] = { { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M10H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M40H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F3) }, + { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M60H_DF_F3) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M70H_DF_F3) }, { PCI_VDEVICE(HYGON, PCI_DEVICE_ID_AMD_17H_DF_F3) }, {}