Source
323
323
if (!data)
324
324
return -ENOMEM;
325
325
326
326
data->pdev = pdev;
327
327
328
328
if (boot_cpu_data.x86 == 0x15 &&
329
329
((boot_cpu_data.x86_model & 0xf0) == 0x60 ||
330
330
(boot_cpu_data.x86_model & 0xf0) == 0x70)) {
331
331
data->read_htcreg = read_htcreg_nb_f15;
332
332
data->read_tempreg = read_tempreg_nb_f15;
333
-
} else if (boot_cpu_data.x86 == 0x17) {
333
+
} else if (boot_cpu_data.x86 == 0x17 || boot_cpu_data.x86 == 0x18) {
334
334
data->temp_adjust_mask = 0x80000;
335
335
data->read_tempreg = read_tempreg_nb_f17;
336
336
data->show_tdie = true;
337
337
} else {
338
338
data->read_htcreg = read_htcreg_pci;
339
339
data->read_tempreg = read_tempreg_pci;
340
340
}
341
341
342
342
for (i = 0; i < ARRAY_SIZE(tctl_offset_table); i++) {
343
343
const struct tctl_offset *entry = &tctl_offset_table[i];
360
360
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_CNB17H_F3) },
361
361
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_NB_F3) },
362
362
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M10H_F3) },
363
363
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M30H_NB_F3) },
364
364
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M60H_NB_F3) },
365
365
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M70H_NB_F3) },
366
366
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_16H_NB_F3) },
367
367
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_16H_M30H_NB_F3) },
368
368
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_17H_DF_F3) },
369
369
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_17H_M10H_DF_F3) },
370
+
{ PCI_VDEVICE(HYGON, PCI_DEVICE_ID_AMD_17H_DF_F3) },
370
371
{}
371
372
};
372
373
MODULE_DEVICE_TABLE(pci, k10temp_id_table);
373
374
374
375
static struct pci_driver k10temp_driver = {
375
376
.name = "k10temp",
376
377
.id_table = k10temp_id_table,
377
378
.probe = k10temp_probe,
378
379
};
379
380