lkml.org 
[lkml]   [2024]   [Apr]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v3 50/74] x86/cpu/vfm: Update drivers/hwmon/peci/cputemp.c
Date
New CPU #defines encode vendor and family as well as model.

Signed-off-by: Tony Luck <tony.luck@intel.com>
---
drivers/hwmon/peci/cputemp.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/hwmon/peci/cputemp.c b/drivers/hwmon/peci/cputemp.c
index a812c15948d9..28cec5c318d4 100644
--- a/drivers/hwmon/peci/cputemp.c
+++ b/drivers/hwmon/peci/cputemp.c
@@ -11,6 +11,7 @@
#include <linux/peci-cpu.h>
#include <linux/units.h>

+#include <asm/cpu_device_id.h>
#include "common.h"

#define CORE_NUMS_MAX 64
@@ -361,9 +362,9 @@ static int init_core_mask(struct peci_cputemp *priv)

/* Get the RESOLVED_CORES register value */
switch (peci_dev->info.model) {
- case INTEL_FAM6_ICELAKE_X:
- case INTEL_FAM6_ICELAKE_D:
- case INTEL_FAM6_SAPPHIRERAPIDS_X:
+ case VFM_MODEL(INTEL_ICELAKE_X):
+ case VFM_MODEL(INTEL_ICELAKE_D):
+ case VFM_MODEL(INTEL_SAPPHIRERAPIDS_X):
ret = peci_ep_pci_local_read(peci_dev, 0, reg->bus, reg->dev,
reg->func, reg->offset + 4, &data);
if (ret)
--
2.44.0

\
 
 \ /
  Last update: 2024-04-16 23:31    [W:0.397 / U:0.144 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site