* [PATCH 0/3] k10temp/amd_nb: Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh
@ 2021-11-08 21:51 Babu Moger
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
` (2 more replies)
0 siblings, 3 replies; 11+ messages in thread
From: Babu Moger @ 2021-11-08 21:51 UTC (permalink / raw)
To: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas
Cc: linux-kernel, linux-hwmon, linux-pci, babu.moger
This series updates k10temp and amd_nb drivers to support AMD Family 19h
Models 10h-1Fh and A0h-AF CPUs.
---
Babu Moger (2):
hwmon: (k10temp) Remove unused definitions
hwmon: (k10temp) Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh
Yazen Ghannam (1):
x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs
arch/x86/kernel/amd_nb.c | 5 +++++
drivers/hwmon/k10temp.c | 23 +++--------------------
include/linux/pci_ids.h | 1 +
3 files changed, 9 insertions(+), 20 deletions(-)
--
^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs
2021-11-08 21:51 [PATCH 0/3] k10temp/amd_nb: Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
@ 2021-11-08 21:51 ` Babu Moger
2021-11-09 0:10 ` Krzysztof Wilczyński
` (3 more replies)
2021-11-08 21:51 ` [PATCH 2/3] hwmon: (k10temp) Remove unused definitions Babu Moger
2021-11-08 21:51 ` [PATCH 3/3] hwmon: (k10temp) Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
2 siblings, 4 replies; 11+ messages in thread
From: Babu Moger @ 2021-11-08 21:51 UTC (permalink / raw)
To: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas
Cc: linux-kernel, linux-hwmon, linux-pci, babu.moger
From: Yazen Ghannam <yazen.ghannam@amd.com>
Add the new PCI Device IDs to support new generation of AMD 19h family of
processors.
Signed-off-by: Yazen Ghannam <yazen.ghannam@amd.com>
Signed-off-by: Babu Moger <babu.moger@amd.com>
---
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 c92c9c774c0e..f3e885f3dd0f 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_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_19H_DF_F4 0x1654
+#define PCI_DEVICE_ID_AMD_19H_M10H_DF_F4 0x14b1
#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
@@ -39,6 +41,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_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_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) },
+ { 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) },
{}
@@ -78,6 +82,7 @@ static const struct pci_device_id amd_nb_link_ids[] = {
{ 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_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) },
{ PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F4) },
{ PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CNB17H_F4) },
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
index 011f2f1ea5bb..b5248f27910e 100644
--- a/include/linux/pci_ids.h
+++ b/include/linux/pci_ids.h
@@ -555,6 +555,7 @@
#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_19H_DF_F3 0x1653
+#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_CNB17H_F3 0x1703
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 2/3] hwmon: (k10temp) Remove unused definitions
2021-11-08 21:51 [PATCH 0/3] k10temp/amd_nb: Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
@ 2021-11-08 21:51 ` Babu Moger
2021-11-09 20:29 ` Guenter Roeck
2021-11-08 21:51 ` [PATCH 3/3] hwmon: (k10temp) Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
2 siblings, 1 reply; 11+ messages in thread
From: Babu Moger @ 2021-11-08 21:51 UTC (permalink / raw)
To: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas
Cc: linux-kernel, linux-hwmon, linux-pci, babu.moger
Usage of these definitions were removed after the commit 0a4e668b5d52
("hwmon: (k10temp) Remove support for displaying voltage and current on Zen CPUs").
So, cleanup them up.
Signed-off-by: Babu Moger <babu.moger@amd.com>
---
drivers/hwmon/k10temp.c | 20 --------------------
1 file changed, 20 deletions(-)
diff --git a/drivers/hwmon/k10temp.c b/drivers/hwmon/k10temp.c
index 3618a924e78e..662bad7ed0a2 100644
--- a/drivers/hwmon/k10temp.c
+++ b/drivers/hwmon/k10temp.c
@@ -76,26 +76,6 @@ static DEFINE_MUTEX(nb_smu_ind_mutex);
#define ZEN_CUR_TEMP_SHIFT 21
#define ZEN_CUR_TEMP_RANGE_SEL_MASK BIT(19)
-#define ZEN_SVI_BASE 0x0005A000
-
-/* F17h thermal registers through SMN */
-#define F17H_M01H_SVI_TEL_PLANE0 (ZEN_SVI_BASE + 0xc)
-#define F17H_M01H_SVI_TEL_PLANE1 (ZEN_SVI_BASE + 0x10)
-#define F17H_M31H_SVI_TEL_PLANE0 (ZEN_SVI_BASE + 0x14)
-#define F17H_M31H_SVI_TEL_PLANE1 (ZEN_SVI_BASE + 0x10)
-
-#define F17H_M01H_CFACTOR_ICORE 1000000 /* 1A / LSB */
-#define F17H_M01H_CFACTOR_ISOC 250000 /* 0.25A / LSB */
-#define F17H_M31H_CFACTOR_ICORE 1000000 /* 1A / LSB */
-#define F17H_M31H_CFACTOR_ISOC 310000 /* 0.31A / LSB */
-
-/* F19h thermal registers through SMN */
-#define F19H_M01_SVI_TEL_PLANE0 (ZEN_SVI_BASE + 0x14)
-#define F19H_M01_SVI_TEL_PLANE1 (ZEN_SVI_BASE + 0x10)
-
-#define F19H_M01H_CFACTOR_ICORE 1000000 /* 1A / LSB */
-#define F19H_M01H_CFACTOR_ISOC 310000 /* 0.31A / LSB */
-
struct k10temp_data {
struct pci_dev *pdev;
void (*read_htcreg)(struct pci_dev *pdev, u32 *regval);
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 3/3] hwmon: (k10temp) Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh
2021-11-08 21:51 [PATCH 0/3] k10temp/amd_nb: Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
2021-11-08 21:51 ` [PATCH 2/3] hwmon: (k10temp) Remove unused definitions Babu Moger
@ 2021-11-08 21:51 ` Babu Moger
2021-11-09 20:30 ` Guenter Roeck
2 siblings, 1 reply; 11+ messages in thread
From: Babu Moger @ 2021-11-08 21:51 UTC (permalink / raw)
To: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas
Cc: linux-kernel, linux-hwmon, linux-pci, babu.moger
Add thermal info support for AMD Family 19h Models 10h-1Fh and A0h-AFh.
Thermal info is supported via a new PCI device ID at offset 0x300h.
Signed-off-by: Babu Moger <babu.moger@amd.com>
---
drivers/hwmon/k10temp.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/hwmon/k10temp.c b/drivers/hwmon/k10temp.c
index 662bad7ed0a2..880990fa4795 100644
--- a/drivers/hwmon/k10temp.c
+++ b/drivers/hwmon/k10temp.c
@@ -433,7 +433,9 @@ 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 0x10 ... 0x1f:
case 0x40 ... 0x4f: /* Yellow Carp */
+ case 0xa0 ... 0xaf:
data->ccd_offset = 0x300;
k10temp_get_ccd_support(pdev, data, 8);
break;
@@ -477,6 +479,7 @@ static const struct pci_device_id k10temp_id_table[] = {
{ 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_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) },
{ PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F3) },
{ PCI_VDEVICE(HYGON, PCI_DEVICE_ID_AMD_17H_DF_F3) },
^ permalink raw reply related [flat|nested] 11+ messages in thread
* Re: [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
@ 2021-11-09 0:10 ` Krzysztof Wilczyński
2021-11-09 14:59 ` Babu Moger
2021-11-09 9:22 ` Borislav Petkov
` (2 subsequent siblings)
3 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Wilczyński @ 2021-11-09 0:10 UTC (permalink / raw)
To: Babu Moger
Cc: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas, linux-kernel, linux-hwmon, linux-pci
Hello!
> Add the new PCI Device IDs to support new generation of AMD 19h family of
> processors.
This commit message matches the spirit of past additions very well, as per:
commit b3f79ae45904 ("x86/amd_nb: Add Family 19h PCI IDs")
Admittedly, it would be nice to know what platform and/or generations of
AMD family of CPUs this is for. Unless this is somewhat confidential and
in which case it would be fair enough.
For the following PCI related changes:
[...]
> --- a/include/linux/pci_ids.h
> +++ b/include/linux/pci_ids.h
> @@ -555,6 +555,7 @@
> #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_19H_DF_F3 0x1653
> +#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_CNB17H_F3 0x1703
Acked-by: Krzysztof Wilczyński <kw@linux.com>
Krzysztof
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
2021-11-09 0:10 ` Krzysztof Wilczyński
@ 2021-11-09 9:22 ` Borislav Petkov
2021-11-09 15:36 ` Bjorn Helgaas
2021-11-09 20:28 ` Guenter Roeck
3 siblings, 0 replies; 11+ messages in thread
From: Borislav Petkov @ 2021-11-09 9:22 UTC (permalink / raw)
To: Babu Moger
Cc: tglx, mingo, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas, linux-kernel, linux-hwmon, linux-pci
On Mon, Nov 08, 2021 at 03:51:21PM -0600, Babu Moger wrote:
> From: Yazen Ghannam <yazen.ghannam@amd.com>
>
> Add the new PCI Device IDs to support new generation of AMD 19h family of
> processors.
>
> Signed-off-by: Yazen Ghannam <yazen.ghannam@amd.com>
> Signed-off-by: Babu Moger <babu.moger@amd.com>
> ---
> arch/x86/kernel/amd_nb.c | 5 +++++
> include/linux/pci_ids.h | 1 +
> 2 files changed, 6 insertions(+)
Acked-by: Borislav Petkov <bp@suse.de>
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs
2021-11-09 0:10 ` Krzysztof Wilczyński
@ 2021-11-09 14:59 ` Babu Moger
0 siblings, 0 replies; 11+ messages in thread
From: Babu Moger @ 2021-11-09 14:59 UTC (permalink / raw)
To: Krzysztof Wilczyński
Cc: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas, linux-kernel, linux-hwmon, linux-pci
Hi Krzysztof,
On 11/8/21 6:10 PM, Krzysztof Wilczyński wrote:
> Hello!
>
>> Add the new PCI Device IDs to support new generation of AMD 19h family of
>> processors.
> This commit message matches the spirit of past additions very well, as per:
>
> commit b3f79ae45904 ("x86/amd_nb: Add Family 19h PCI IDs")
>
> Admittedly, it would be nice to know what platform and/or generations of
> AMD family of CPUs this is for. Unless this is somewhat confidential and
> in which case it would be fair enough.
Yea. It is kind of confidential to spell out the platform at this point.
>
> For the following PCI related changes:
>
> [...]
>> --- a/include/linux/pci_ids.h
>> +++ b/include/linux/pci_ids.h
>> @@ -555,6 +555,7 @@
>> #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_19H_DF_F3 0x1653
>> +#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_CNB17H_F3 0x1703
> Acked-by: Krzysztof Wilczyński <kw@linux.com>
> Thanks
> Babu Moger
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
2021-11-09 0:10 ` Krzysztof Wilczyński
2021-11-09 9:22 ` Borislav Petkov
@ 2021-11-09 15:36 ` Bjorn Helgaas
2021-11-09 20:28 ` Guenter Roeck
3 siblings, 0 replies; 11+ messages in thread
From: Bjorn Helgaas @ 2021-11-09 15:36 UTC (permalink / raw)
To: Babu Moger
Cc: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare, linux,
bhelgaas, linux-kernel, linux-hwmon, linux-pci
On Mon, Nov 08, 2021 at 03:51:21PM -0600, Babu Moger wrote:
> From: Yazen Ghannam <yazen.ghannam@amd.com>
>
> Add the new PCI Device IDs to support new generation of AMD 19h family of
> processors.
>
> Signed-off-by: Yazen Ghannam <yazen.ghannam@amd.com>
> Signed-off-by: Babu Moger <babu.moger@amd.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com> # 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 c92c9c774c0e..f3e885f3dd0f 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_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_19H_DF_F4 0x1654
> +#define PCI_DEVICE_ID_AMD_19H_M10H_DF_F4 0x14b1
> #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
> @@ -39,6 +41,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_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_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) },
> + { 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) },
> {}
> @@ -78,6 +82,7 @@ static const struct pci_device_id amd_nb_link_ids[] = {
> { 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_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) },
> { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F4) },
> { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CNB17H_F4) },
> diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
> index 011f2f1ea5bb..b5248f27910e 100644
> --- a/include/linux/pci_ids.h
> +++ b/include/linux/pci_ids.h
> @@ -555,6 +555,7 @@
> #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_19H_DF_F3 0x1653
> +#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_CNB17H_F3 0x1703
>
>
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
` (2 preceding siblings ...)
2021-11-09 15:36 ` Bjorn Helgaas
@ 2021-11-09 20:28 ` Guenter Roeck
3 siblings, 0 replies; 11+ messages in thread
From: Guenter Roeck @ 2021-11-09 20:28 UTC (permalink / raw)
To: Babu Moger
Cc: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare,
bhelgaas, linux-kernel, linux-hwmon, linux-pci
On Mon, Nov 08, 2021 at 03:51:21PM -0600, Babu Moger wrote:
> From: Yazen Ghannam <yazen.ghannam@amd.com>
>
> Add the new PCI Device IDs to support new generation of AMD 19h family of
> processors.
>
> Signed-off-by: Yazen Ghannam <yazen.ghannam@amd.com>
> Signed-off-by: Babu Moger <babu.moger@amd.com>
> Acked-by: Krzysztof Wilczyński <kw@linux.com>
> Acked-by: Borislav Petkov <bp@suse.de>
> Acked-by: Bjorn Helgaas <bhelgaas@google.com> # pci_ids.h
Applied to hwmon-next.
Thanks,
Guenter
> ---
> 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 c92c9c774c0e..f3e885f3dd0f 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_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_19H_DF_F4 0x1654
> +#define PCI_DEVICE_ID_AMD_19H_M10H_DF_F4 0x14b1
> #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
> @@ -39,6 +41,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_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_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) },
> + { 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) },
> {}
> @@ -78,6 +82,7 @@ static const struct pci_device_id amd_nb_link_ids[] = {
> { 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_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) },
> { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F4) },
> { PCI_DEVICE(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CNB17H_F4) },
> diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
> index 011f2f1ea5bb..b5248f27910e 100644
> --- a/include/linux/pci_ids.h
> +++ b/include/linux/pci_ids.h
> @@ -555,6 +555,7 @@
> #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_19H_DF_F3 0x1653
> +#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_CNB17H_F3 0x1703
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 2/3] hwmon: (k10temp) Remove unused definitions
2021-11-08 21:51 ` [PATCH 2/3] hwmon: (k10temp) Remove unused definitions Babu Moger
@ 2021-11-09 20:29 ` Guenter Roeck
0 siblings, 0 replies; 11+ messages in thread
From: Guenter Roeck @ 2021-11-09 20:29 UTC (permalink / raw)
To: Babu Moger
Cc: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare,
bhelgaas, linux-kernel, linux-hwmon, linux-pci
On Mon, Nov 08, 2021 at 03:51:27PM -0600, Babu Moger wrote:
> Usage of these definitions were removed after the commit 0a4e668b5d52
> ("hwmon: (k10temp) Remove support for displaying voltage and current on Zen CPUs").
> So, cleanup them up.
>
> Signed-off-by: Babu Moger <babu.moger@amd.com>
Applied to hwmon-next.
Thanks,
Guenter
> ---
> drivers/hwmon/k10temp.c | 20 --------------------
> 1 file changed, 20 deletions(-)
>
> diff --git a/drivers/hwmon/k10temp.c b/drivers/hwmon/k10temp.c
> index 3618a924e78e..662bad7ed0a2 100644
> --- a/drivers/hwmon/k10temp.c
> +++ b/drivers/hwmon/k10temp.c
> @@ -76,26 +76,6 @@ static DEFINE_MUTEX(nb_smu_ind_mutex);
> #define ZEN_CUR_TEMP_SHIFT 21
> #define ZEN_CUR_TEMP_RANGE_SEL_MASK BIT(19)
>
> -#define ZEN_SVI_BASE 0x0005A000
> -
> -/* F17h thermal registers through SMN */
> -#define F17H_M01H_SVI_TEL_PLANE0 (ZEN_SVI_BASE + 0xc)
> -#define F17H_M01H_SVI_TEL_PLANE1 (ZEN_SVI_BASE + 0x10)
> -#define F17H_M31H_SVI_TEL_PLANE0 (ZEN_SVI_BASE + 0x14)
> -#define F17H_M31H_SVI_TEL_PLANE1 (ZEN_SVI_BASE + 0x10)
> -
> -#define F17H_M01H_CFACTOR_ICORE 1000000 /* 1A / LSB */
> -#define F17H_M01H_CFACTOR_ISOC 250000 /* 0.25A / LSB */
> -#define F17H_M31H_CFACTOR_ICORE 1000000 /* 1A / LSB */
> -#define F17H_M31H_CFACTOR_ISOC 310000 /* 0.31A / LSB */
> -
> -/* F19h thermal registers through SMN */
> -#define F19H_M01_SVI_TEL_PLANE0 (ZEN_SVI_BASE + 0x14)
> -#define F19H_M01_SVI_TEL_PLANE1 (ZEN_SVI_BASE + 0x10)
> -
> -#define F19H_M01H_CFACTOR_ICORE 1000000 /* 1A / LSB */
> -#define F19H_M01H_CFACTOR_ISOC 310000 /* 0.31A / LSB */
> -
> struct k10temp_data {
> struct pci_dev *pdev;
> void (*read_htcreg)(struct pci_dev *pdev, u32 *regval);
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 3/3] hwmon: (k10temp) Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh
2021-11-08 21:51 ` [PATCH 3/3] hwmon: (k10temp) Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
@ 2021-11-09 20:30 ` Guenter Roeck
0 siblings, 0 replies; 11+ messages in thread
From: Guenter Roeck @ 2021-11-09 20:30 UTC (permalink / raw)
To: Babu Moger
Cc: tglx, mingo, bp, dave.hansen, x86, hpa, clemens, jdelvare,
bhelgaas, linux-kernel, linux-hwmon, linux-pci
On Mon, Nov 08, 2021 at 03:51:34PM -0600, Babu Moger wrote:
> Add thermal info support for AMD Family 19h Models 10h-1Fh and A0h-AFh.
> Thermal info is supported via a new PCI device ID at offset 0x300h.
>
> Signed-off-by: Babu Moger <babu.moger@amd.com>
Applied to hwmon-next.
Thanks,
Guenter
> ---
> drivers/hwmon/k10temp.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/drivers/hwmon/k10temp.c b/drivers/hwmon/k10temp.c
> index 662bad7ed0a2..880990fa4795 100644
> --- a/drivers/hwmon/k10temp.c
> +++ b/drivers/hwmon/k10temp.c
> @@ -433,7 +433,9 @@ 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 0x10 ... 0x1f:
> case 0x40 ... 0x4f: /* Yellow Carp */
> + case 0xa0 ... 0xaf:
> data->ccd_offset = 0x300;
> k10temp_get_ccd_support(pdev, data, 8);
> break;
> @@ -477,6 +479,7 @@ static const struct pci_device_id k10temp_id_table[] = {
> { 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_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) },
> { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_19H_M50H_DF_F3) },
> { PCI_VDEVICE(HYGON, PCI_DEVICE_ID_AMD_17H_DF_F3) },
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2021-11-09 20:30 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-08 21:51 [PATCH 0/3] k10temp/amd_nb: Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
2021-11-08 21:51 ` [PATCH 1/3] x86/amd_nb: Add AMD Family 19h Models (10h-1Fh) and (A0h-AFh) PCI IDs Babu Moger
2021-11-09 0:10 ` Krzysztof Wilczyński
2021-11-09 14:59 ` Babu Moger
2021-11-09 9:22 ` Borislav Petkov
2021-11-09 15:36 ` Bjorn Helgaas
2021-11-09 20:28 ` Guenter Roeck
2021-11-08 21:51 ` [PATCH 2/3] hwmon: (k10temp) Remove unused definitions Babu Moger
2021-11-09 20:29 ` Guenter Roeck
2021-11-08 21:51 ` [PATCH 3/3] hwmon: (k10temp) Add support for AMD Family 19h Models 10h-1Fh and A0h-AFh Babu Moger
2021-11-09 20:30 ` Guenter Roeck
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.