All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] soc/tegra: fuse: Support Tegra210B01 Speedos
@ 2026-07-28  1:57 ` Aaron Kling
  0 siblings, 0 replies; 7+ messages in thread
From: Aaron Kling via B4 Relay @ 2026-07-28  1:57 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter
  Cc: linux-tegra, linux-kernel, Aaron Kling, Alex Frid

This series adds support for the b01 fuse revision, then adds speedo
support for known Tegra210B01 sku's.

Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
---
Changes in v2:
- Update patch 1 commit messag to be more descriptive
- Update patch 1 to set unknown revision in the major revision B code
  path if minor revision is not 1.
- Add based-on tags to patch 2
- Link to v1: https://lore.kernel.org/r/20260717-t210b01-speedo-v1-0-f04a8bd4d997@gmail.com

---
Aaron Kling (2):
      soc/tegra: fuse: Support revision B01
      soc/tegra: fuse: speedo-tegra210: Support revision B01

 drivers/soc/tegra/fuse/fuse-tegra.c      |  1 +
 drivers/soc/tegra/fuse/speedo-tegra210.c | 22 ++++++++++++--
 drivers/soc/tegra/fuse/tegra-apbmisc.c   | 51 +++++++++++++++++++-------------
 include/soc/tegra/fuse.h                 |  1 +
 4 files changed, 53 insertions(+), 22 deletions(-)
---
base-commit: 1a1757b76427f6201bfe0bf1bea9f7574f332a93
change-id: 20260714-t210b01-speedo-07f8cd3b3aa3

Best regards,
-- 
Aaron Kling <webgeek1234@gmail.com>



^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH v2 0/2] soc/tegra: fuse: Support Tegra210B01 Speedos
@ 2026-07-28  1:57 ` Aaron Kling
  0 siblings, 0 replies; 7+ messages in thread
From: Aaron Kling @ 2026-07-28  1:57 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter
  Cc: linux-tegra, linux-kernel, Aaron Kling, Alex Frid

This series adds support for the b01 fuse revision, then adds speedo
support for known Tegra210B01 sku's.

Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
---
Changes in v2:
- Update patch 1 commit messag to be more descriptive
- Update patch 1 to set unknown revision in the major revision B code
  path if minor revision is not 1.
- Add based-on tags to patch 2
- Link to v1: https://lore.kernel.org/r/20260717-t210b01-speedo-v1-0-f04a8bd4d997@gmail.com

---
Aaron Kling (2):
      soc/tegra: fuse: Support revision B01
      soc/tegra: fuse: speedo-tegra210: Support revision B01

 drivers/soc/tegra/fuse/fuse-tegra.c      |  1 +
 drivers/soc/tegra/fuse/speedo-tegra210.c | 22 ++++++++++++--
 drivers/soc/tegra/fuse/tegra-apbmisc.c   | 51 +++++++++++++++++++-------------
 include/soc/tegra/fuse.h                 |  1 +
 4 files changed, 53 insertions(+), 22 deletions(-)
---
base-commit: 1a1757b76427f6201bfe0bf1bea9f7574f332a93
change-id: 20260714-t210b01-speedo-07f8cd3b3aa3

Best regards,
-- 
Aaron Kling <webgeek1234@gmail.com>


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH v2 1/2] soc/tegra: fuse: Support revision B01
  2026-07-28  1:57 ` Aaron Kling
@ 2026-07-28  1:57   ` Aaron Kling
  -1 siblings, 0 replies; 7+ messages in thread
From: Aaron Kling via B4 Relay @ 2026-07-28  1:57 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter; +Cc: linux-tegra, linux-kernel, Aaron Kling

From: Aaron Kling <webgeek1234@gmail.com>

Previously, all supported SoCs only used the A major revision. The
Tegra210B01 SoC incremented the major revision. Add support for this.

Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
---
 drivers/soc/tegra/fuse/fuse-tegra.c    |  1 +
 drivers/soc/tegra/fuse/tegra-apbmisc.c | 51 +++++++++++++++++++++-------------
 include/soc/tegra/fuse.h               |  1 +
 3 files changed, 33 insertions(+), 20 deletions(-)

diff --git a/drivers/soc/tegra/fuse/fuse-tegra.c b/drivers/soc/tegra/fuse/fuse-tegra.c
index 78b054d43a422..a37642dc92c61 100644
--- a/drivers/soc/tegra/fuse/fuse-tegra.c
+++ b/drivers/soc/tegra/fuse/fuse-tegra.c
@@ -34,6 +34,7 @@ static const char *tegra_revision_name[TEGRA_REVISION_MAX] = {
 	[TEGRA_REVISION_A03]     = "A03",
 	[TEGRA_REVISION_A03p]    = "A03 prime",
 	[TEGRA_REVISION_A04]     = "A04",
+	[TEGRA_REVISION_B01]     = "B01",
 };
 
 static const char *tegra_platform_name[TEGRA_PLATFORM_MAX] = {
diff --git a/drivers/soc/tegra/fuse/tegra-apbmisc.c b/drivers/soc/tegra/fuse/tegra-apbmisc.c
index 6af69ccaa295c..a4fb0ecd15cf3 100644
--- a/drivers/soc/tegra/fuse/tegra-apbmisc.c
+++ b/drivers/soc/tegra/fuse/tegra-apbmisc.c
@@ -167,30 +167,41 @@ static const struct of_device_id apbmisc_match[] __initconst = {
 
 void __init tegra_init_revision(void)
 {
-	u8 chip_id, minor_rev;
+	u8 chip_id, major_rev, minor_rev;
 
 	chip_id = tegra_get_chip_id();
+	major_rev = tegra_get_major_rev();
 	minor_rev = tegra_get_minor_rev();
 
-	switch (minor_rev) {
-	case 1:
-		tegra_sku_info.revision = TEGRA_REVISION_A01;
-		break;
-	case 2:
-		tegra_sku_info.revision = TEGRA_REVISION_A02;
-		break;
-	case 3:
-		if (chip_id == TEGRA20 && (tegra_fuse_read_spare(18) ||
-					   tegra_fuse_read_spare(19)))
-			tegra_sku_info.revision = TEGRA_REVISION_A03p;
-		else
-			tegra_sku_info.revision = TEGRA_REVISION_A03;
-		break;
-	case 4:
-		tegra_sku_info.revision = TEGRA_REVISION_A04;
-		break;
-	default:
-		tegra_sku_info.revision = TEGRA_REVISION_UNKNOWN;
+	if (major_rev > 1) {
+		switch (minor_rev) {
+		case 1:
+			tegra_sku_info.revision = TEGRA_REVISION_B01;
+			break;
+		default:
+			tegra_sku_info.revision = TEGRA_REVISION_UNKNOWN;
+		}
+	} else {
+		switch (minor_rev) {
+		case 1:
+			tegra_sku_info.revision = TEGRA_REVISION_A01;
+			break;
+		case 2:
+			tegra_sku_info.revision = TEGRA_REVISION_A02;
+			break;
+		case 3:
+			if (chip_id == TEGRA20 && (tegra_fuse_read_spare(18) ||
+						   tegra_fuse_read_spare(19)))
+				tegra_sku_info.revision = TEGRA_REVISION_A03p;
+			else
+				tegra_sku_info.revision = TEGRA_REVISION_A03;
+			break;
+		case 4:
+			tegra_sku_info.revision = TEGRA_REVISION_A04;
+			break;
+		default:
+			tegra_sku_info.revision = TEGRA_REVISION_UNKNOWN;
+		}
 	}
 
 	tegra_sku_info.sku_id = tegra_fuse_read_early(FUSE_SKU_INFO);
diff --git a/include/soc/tegra/fuse.h b/include/soc/tegra/fuse.h
index 8f421b9f7585c..30db79f7f17fd 100644
--- a/include/soc/tegra/fuse.h
+++ b/include/soc/tegra/fuse.h
@@ -33,6 +33,7 @@ enum tegra_revision {
 	TEGRA_REVISION_A03,
 	TEGRA_REVISION_A03p,
 	TEGRA_REVISION_A04,
+	TEGRA_REVISION_B01,
 	TEGRA_REVISION_MAX,
 };
 

-- 
2.54.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH v2 1/2] soc/tegra: fuse: Support revision B01
@ 2026-07-28  1:57   ` Aaron Kling
  0 siblings, 0 replies; 7+ messages in thread
From: Aaron Kling @ 2026-07-28  1:57 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter; +Cc: linux-tegra, linux-kernel, Aaron Kling

Previously, all supported SoCs only used the A major revision. The
Tegra210B01 SoC incremented the major revision. Add support for this.

Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
---
 drivers/soc/tegra/fuse/fuse-tegra.c    |  1 +
 drivers/soc/tegra/fuse/tegra-apbmisc.c | 51 +++++++++++++++++++++-------------
 include/soc/tegra/fuse.h               |  1 +
 3 files changed, 33 insertions(+), 20 deletions(-)

diff --git a/drivers/soc/tegra/fuse/fuse-tegra.c b/drivers/soc/tegra/fuse/fuse-tegra.c
index 78b054d43a422..a37642dc92c61 100644
--- a/drivers/soc/tegra/fuse/fuse-tegra.c
+++ b/drivers/soc/tegra/fuse/fuse-tegra.c
@@ -34,6 +34,7 @@ static const char *tegra_revision_name[TEGRA_REVISION_MAX] = {
 	[TEGRA_REVISION_A03]     = "A03",
 	[TEGRA_REVISION_A03p]    = "A03 prime",
 	[TEGRA_REVISION_A04]     = "A04",
+	[TEGRA_REVISION_B01]     = "B01",
 };
 
 static const char *tegra_platform_name[TEGRA_PLATFORM_MAX] = {
diff --git a/drivers/soc/tegra/fuse/tegra-apbmisc.c b/drivers/soc/tegra/fuse/tegra-apbmisc.c
index 6af69ccaa295c..a4fb0ecd15cf3 100644
--- a/drivers/soc/tegra/fuse/tegra-apbmisc.c
+++ b/drivers/soc/tegra/fuse/tegra-apbmisc.c
@@ -167,30 +167,41 @@ static const struct of_device_id apbmisc_match[] __initconst = {
 
 void __init tegra_init_revision(void)
 {
-	u8 chip_id, minor_rev;
+	u8 chip_id, major_rev, minor_rev;
 
 	chip_id = tegra_get_chip_id();
+	major_rev = tegra_get_major_rev();
 	minor_rev = tegra_get_minor_rev();
 
-	switch (minor_rev) {
-	case 1:
-		tegra_sku_info.revision = TEGRA_REVISION_A01;
-		break;
-	case 2:
-		tegra_sku_info.revision = TEGRA_REVISION_A02;
-		break;
-	case 3:
-		if (chip_id == TEGRA20 && (tegra_fuse_read_spare(18) ||
-					   tegra_fuse_read_spare(19)))
-			tegra_sku_info.revision = TEGRA_REVISION_A03p;
-		else
-			tegra_sku_info.revision = TEGRA_REVISION_A03;
-		break;
-	case 4:
-		tegra_sku_info.revision = TEGRA_REVISION_A04;
-		break;
-	default:
-		tegra_sku_info.revision = TEGRA_REVISION_UNKNOWN;
+	if (major_rev > 1) {
+		switch (minor_rev) {
+		case 1:
+			tegra_sku_info.revision = TEGRA_REVISION_B01;
+			break;
+		default:
+			tegra_sku_info.revision = TEGRA_REVISION_UNKNOWN;
+		}
+	} else {
+		switch (minor_rev) {
+		case 1:
+			tegra_sku_info.revision = TEGRA_REVISION_A01;
+			break;
+		case 2:
+			tegra_sku_info.revision = TEGRA_REVISION_A02;
+			break;
+		case 3:
+			if (chip_id == TEGRA20 && (tegra_fuse_read_spare(18) ||
+						   tegra_fuse_read_spare(19)))
+				tegra_sku_info.revision = TEGRA_REVISION_A03p;
+			else
+				tegra_sku_info.revision = TEGRA_REVISION_A03;
+			break;
+		case 4:
+			tegra_sku_info.revision = TEGRA_REVISION_A04;
+			break;
+		default:
+			tegra_sku_info.revision = TEGRA_REVISION_UNKNOWN;
+		}
 	}
 
 	tegra_sku_info.sku_id = tegra_fuse_read_early(FUSE_SKU_INFO);
diff --git a/include/soc/tegra/fuse.h b/include/soc/tegra/fuse.h
index 8f421b9f7585c..30db79f7f17fd 100644
--- a/include/soc/tegra/fuse.h
+++ b/include/soc/tegra/fuse.h
@@ -33,6 +33,7 @@ enum tegra_revision {
 	TEGRA_REVISION_A03,
 	TEGRA_REVISION_A03p,
 	TEGRA_REVISION_A04,
+	TEGRA_REVISION_B01,
 	TEGRA_REVISION_MAX,
 };
 

-- 
2.54.0


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH v2 2/2] soc/tegra: fuse: speedo-tegra210: Support revision B01
  2026-07-28  1:57 ` Aaron Kling
@ 2026-07-28  1:57   ` Aaron Kling
  -1 siblings, 0 replies; 7+ messages in thread
From: Aaron Kling via B4 Relay @ 2026-07-28  1:57 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter
  Cc: linux-tegra, linux-kernel, Aaron Kling, Alex Frid

From: Aaron Kling <webgeek1234@gmail.com>

Tegra210B01 has a separate set of skus and speedo tables

Based-on: https://gitlab.com/nvidia/nv-tegra/linux-5.10/-/commit/8555ef4988d3b39d91791794825c354b3c9377ba
Based-on-patch-by: Alex Frid <afrid@nvidia.com>
Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
---
 drivers/soc/tegra/fuse/speedo-tegra210.c | 22 ++++++++++++++++++++--
 1 file changed, 20 insertions(+), 2 deletions(-)

diff --git a/drivers/soc/tegra/fuse/speedo-tegra210.c b/drivers/soc/tegra/fuse/speedo-tegra210.c
index 06c2bcbee5734..699751f4bd0c0 100644
--- a/drivers/soc/tegra/fuse/speedo-tegra210.c
+++ b/drivers/soc/tegra/fuse/speedo-tegra210.c
@@ -65,7 +65,25 @@ static void __init rev_sku_to_speedo_ids(struct tegra_sku_info *sku_info,
 	sku_info->gpu_speedo_id = 0;
 	*threshold = THRESHOLD_INDEX_0;
 
-	if (sku_info->revision >= TEGRA_REVISION_A02) {
+	if (sku_info->revision >= TEGRA_REVISION_B01) {
+		sku_info->gpu_speedo_id = 1;
+
+		switch (sku) {
+		case 0x00: /* Engineering SKU */
+		case 0x01: /* Engineering SKU */
+		case 0x83:
+			break;
+
+		case 0x87:
+			sku_info->cpu_speedo_id = 3;
+			break;
+
+		default:
+			pr_err("Tegra210B01: unknown SKU %#04x\n", sku);
+			/* Using the default for the error case */
+			break;
+		}
+	} else if (sku_info->revision >= TEGRA_REVISION_A02) {
 		switch (sku) {
 		case 0x00: /* Engineering SKU */
 		case 0x01: /* Engineering SKU */
@@ -154,7 +172,7 @@ void __init tegra210_init_speedo_data(struct tegra_sku_info *sku_info)
 	speedo_revision = get_speedo_revision();
 	pr_info("Speedo Revision %u\n", speedo_revision);
 
-	if (speedo_revision >= 3) {
+	if (sku_info->revision == TEGRA_REVISION_B01 || speedo_revision >= 3) {
 		sku_info->cpu_speedo_value = cpu_speedo[0];
 		sku_info->gpu_speedo_value = cpu_speedo[2];
 		sku_info->soc_speedo_value = soc_speedo[0];

-- 
2.54.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH v2 2/2] soc/tegra: fuse: speedo-tegra210: Support revision B01
@ 2026-07-28  1:57   ` Aaron Kling
  0 siblings, 0 replies; 7+ messages in thread
From: Aaron Kling @ 2026-07-28  1:57 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter
  Cc: linux-tegra, linux-kernel, Aaron Kling, Alex Frid

Tegra210B01 has a separate set of skus and speedo tables

Based-on: https://gitlab.com/nvidia/nv-tegra/linux-5.10/-/commit/8555ef4988d3b39d91791794825c354b3c9377ba
Based-on-patch-by: Alex Frid <afrid@nvidia.com>
Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
---
 drivers/soc/tegra/fuse/speedo-tegra210.c | 22 ++++++++++++++++++++--
 1 file changed, 20 insertions(+), 2 deletions(-)

diff --git a/drivers/soc/tegra/fuse/speedo-tegra210.c b/drivers/soc/tegra/fuse/speedo-tegra210.c
index 06c2bcbee5734..699751f4bd0c0 100644
--- a/drivers/soc/tegra/fuse/speedo-tegra210.c
+++ b/drivers/soc/tegra/fuse/speedo-tegra210.c
@@ -65,7 +65,25 @@ static void __init rev_sku_to_speedo_ids(struct tegra_sku_info *sku_info,
 	sku_info->gpu_speedo_id = 0;
 	*threshold = THRESHOLD_INDEX_0;
 
-	if (sku_info->revision >= TEGRA_REVISION_A02) {
+	if (sku_info->revision >= TEGRA_REVISION_B01) {
+		sku_info->gpu_speedo_id = 1;
+
+		switch (sku) {
+		case 0x00: /* Engineering SKU */
+		case 0x01: /* Engineering SKU */
+		case 0x83:
+			break;
+
+		case 0x87:
+			sku_info->cpu_speedo_id = 3;
+			break;
+
+		default:
+			pr_err("Tegra210B01: unknown SKU %#04x\n", sku);
+			/* Using the default for the error case */
+			break;
+		}
+	} else if (sku_info->revision >= TEGRA_REVISION_A02) {
 		switch (sku) {
 		case 0x00: /* Engineering SKU */
 		case 0x01: /* Engineering SKU */
@@ -154,7 +172,7 @@ void __init tegra210_init_speedo_data(struct tegra_sku_info *sku_info)
 	speedo_revision = get_speedo_revision();
 	pr_info("Speedo Revision %u\n", speedo_revision);
 
-	if (speedo_revision >= 3) {
+	if (sku_info->revision == TEGRA_REVISION_B01 || speedo_revision >= 3) {
 		sku_info->cpu_speedo_value = cpu_speedo[0];
 		sku_info->gpu_speedo_value = cpu_speedo[2];
 		sku_info->soc_speedo_value = soc_speedo[0];

-- 
2.54.0


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH v2 0/2] soc/tegra: fuse: Support Tegra210B01 Speedos
  2026-07-28  1:57 ` Aaron Kling
                   ` (2 preceding siblings ...)
  (?)
@ 2026-07-28 12:19 ` Mikko Perttunen
  -1 siblings, 0 replies; 7+ messages in thread
From: Mikko Perttunen @ 2026-07-28 12:19 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter, webgeek1234
  Cc: linux-tegra, linux-kernel, Aaron Kling, Alex Frid

On Tuesday, July 28, 2026 10:57 AM Aaron Kling via B4 Relay wrote:
> This series adds support for the b01 fuse revision, then adds speedo
> support for known Tegra210B01 sku's.
> 
> Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
> ---
> Changes in v2:
> - Update patch 1 commit messag to be more descriptive
> - Update patch 1 to set unknown revision in the major revision B code
>   path if minor revision is not 1.
> - Add based-on tags to patch 2
> - Link to v1: https://lore.kernel.org/r/20260717-t210b01-speedo-v1-0-f04a8bd4d997@gmail.com
> 
> ---
> Aaron Kling (2):
>       soc/tegra: fuse: Support revision B01
>       soc/tegra: fuse: speedo-tegra210: Support revision B01
> 
>  drivers/soc/tegra/fuse/fuse-tegra.c      |  1 +
>  drivers/soc/tegra/fuse/speedo-tegra210.c | 22 ++++++++++++--
>  drivers/soc/tegra/fuse/tegra-apbmisc.c   | 51 +++++++++++++++++++-------------
>  include/soc/tegra/fuse.h                 |  1 +
>  4 files changed, 53 insertions(+), 22 deletions(-)
> ---
> base-commit: 1a1757b76427f6201bfe0bf1bea9f7574f332a93
> change-id: 20260714-t210b01-speedo-07f8cd3b3aa3
> 
> Best regards,
> -- 
> Aaron Kling <webgeek1234@gmail.com>
> 
> 
> 

Series

Reviewed-by: Mikko Perttunen <mperttunen@nvidia.com>




^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-07-28 12:19 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-28  1:57 [PATCH v2 0/2] soc/tegra: fuse: Support Tegra210B01 Speedos Aaron Kling via B4 Relay
2026-07-28  1:57 ` Aaron Kling
2026-07-28  1:57 ` [PATCH v2 1/2] soc/tegra: fuse: Support revision B01 Aaron Kling via B4 Relay
2026-07-28  1:57   ` Aaron Kling
2026-07-28  1:57 ` [PATCH v2 2/2] soc/tegra: fuse: speedo-tegra210: " Aaron Kling via B4 Relay
2026-07-28  1:57   ` Aaron Kling
2026-07-28 12:19 ` [PATCH v2 0/2] soc/tegra: fuse: Support Tegra210B01 Speedos Mikko Perttunen

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.