View | Details | Raw Unified | Return to bug 284010
Collapse All | Expand All

(-)b/sys/dev/amdsmn/amdsmn.c (-1 / +2 lines)
Lines 60-66 Link Here
60
#define	PCI_DEVICE_ID_AMD_17H_M60H_ROOT		0x1630	/* Also F19H M50H */
60
#define	PCI_DEVICE_ID_AMD_17H_M60H_ROOT		0x1630	/* Also F19H M50H */
61
#define	PCI_DEVICE_ID_AMD_19H_M10H_ROOT		0x14a4
61
#define	PCI_DEVICE_ID_AMD_19H_M10H_ROOT		0x14a4
62
#define	PCI_DEVICE_ID_AMD_19H_M40H_ROOT		0x14b5
62
#define	PCI_DEVICE_ID_AMD_19H_M40H_ROOT		0x14b5
63
#define	PCI_DEVICE_ID_AMD_19H_M60H_ROOT		0x14d8
63
#define	PCI_DEVICE_ID_AMD_19H_M60H_ROOT		0x14d8	/* Also F1AH M40H */
64
#define	PCI_DEVICE_ID_AMD_19H_M70H_ROOT		0x14e8
64
#define	PCI_DEVICE_ID_AMD_19H_M70H_ROOT		0x14e8
65
65
66
struct pciid;
66
struct pciid;
Lines 211-216 amdsmn_probe(device_t dev) Link Here
211
	case 0x15:
211
	case 0x15:
212
	case 0x17:
212
	case 0x17:
213
	case 0x19:
213
	case 0x19:
214
	case 0x1a:
214
		break;
215
		break;
215
	default:
216
	default:
216
		return (ENXIO);
217
		return (ENXIO);
(-)b/sys/dev/amdtemp/amdtemp.c (-1 / +26 lines)
Lines 115-121 struct amdtemp_softc { Link Here
115
#define	DEVICEID_AMD_HOSTB17H_M60H_ROOT	0x1630	/* Also F19H M50H */
115
#define	DEVICEID_AMD_HOSTB17H_M60H_ROOT	0x1630	/* Also F19H M50H */
116
#define	DEVICEID_AMD_HOSTB19H_M10H_ROOT	0x14a4
116
#define	DEVICEID_AMD_HOSTB19H_M10H_ROOT	0x14a4
117
#define	DEVICEID_AMD_HOSTB19H_M40H_ROOT	0x14b5
117
#define	DEVICEID_AMD_HOSTB19H_M40H_ROOT	0x14b5
118
#define	DEVICEID_AMD_HOSTB19H_M60H_ROOT	0x14d8
118
#define	DEVICEID_AMD_HOSTB19H_M60H_ROOT	0x14d8	/* Also F1AH M40H */
119
#define	DEVICEID_AMD_HOSTB19H_M70H_ROOT	0x14e8
119
#define	DEVICEID_AMD_HOSTB19H_M70H_ROOT	0x14e8
120
120
121
static const struct amdtemp_product {
121
static const struct amdtemp_product {
Lines 317-322 amdtemp_probe(device_t dev) Link Here
317
	case 0x16:
317
	case 0x16:
318
	case 0x17:
318
	case 0x17:
319
	case 0x19:
319
	case 0x19:
320
	case 0x1a:
320
		break;
321
		break;
321
	default:
322
	default:
322
		return (ENXIO);
323
		return (ENXIO);
Lines 476-481 amdtemp_attach(device_t dev) Link Here
476
		break;
477
		break;
477
	case 0x17:
478
	case 0x17:
478
	case 0x19:
479
	case 0x19:
480
	case 0x1a:
479
		sc->sc_ntemps = 1;
481
		sc->sc_ntemps = 1;
480
		sc->sc_gettemp = amdtemp_gettemp17h;
482
		sc->sc_gettemp = amdtemp_gettemp17h;
481
		needsmn = true;
483
		needsmn = true;
Lines 539-544 amdtemp_attach(device_t dev) Link Here
539
		amdtemp_probe_ccd_sensors17h(dev, model);
541
		amdtemp_probe_ccd_sensors17h(dev, model);
540
	else if (family == 0x19)
542
	else if (family == 0x19)
541
		amdtemp_probe_ccd_sensors19h(dev, model);
543
		amdtemp_probe_ccd_sensors19h(dev, model);
544
	else if (family == 0x1a)
545
		amdtemp_probe_ccd_sensors1ah(dev, model);
542
	else if (sc->sc_ntemps > 1) {
546
	else if (sc->sc_ntemps > 1) {
543
		SYSCTL_ADD_PROC(sysctlctx,
547
		SYSCTL_ADD_PROC(sysctlctx,
544
		    SYSCTL_CHILDREN(sysctlnode),
548
		    SYSCTL_CHILDREN(sysctlnode),
Lines 892-894 amdtemp_probe_ccd_sensors19h(device_t dev, uint32_t model) Link Here
892
896
893
	amdtemp_probe_ccd_sensors(dev, maxreg);
897
	amdtemp_probe_ccd_sensors(dev, maxreg);
894
}
898
}
899
900
static void
901
amdtemp_probe_ccd_sensors1ah(device_t dev, uint32_t model)
902
{
903
	struct amdtemp_softc *sc = device_get_softc(dev);
904
	uint32_t maxreg;
905
906
	switch (model) {
907
	case 0x40 ... 0x4f: /* Zen5 Ryzen "Granite Ridge" */
908
		sc->sc_temp_base = AMDTEMP_ZEN4_CCD_TMP_BASE;
909
		maxreg = 8;
910
		_Static_assert((int)NUM_CCDS >= 8, "");
911
		break;
912
	default:
913
		device_printf(dev,
914
		    "Unrecognized Family 1ah Model: %02xh\n", model);
915
		return;
916
	}
917
918
	amdtemp_probe_ccd_sensors(dev, maxreg);
919
}

Return to bug 284010