Skip to contentSkip to conversation

arm: mach-k3: Move TI keys out of board folder

PATCH In review Nishanth Menon 5 participants 10 messages Nov 4, 2023 – Nov 22, 2023

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

v2 cover arm: mach-k3: Move TI keys out of board folder

Hi,

V2 of the series broadening the scope a bit more here.

Changes in V2:
* Drop the override from verdin binman files since the default depends on k3-binman.dtsi
* Move the TI dummy keys out to arch as well (new patch)

V1: https://lore.kernel.org/all/[email protected]/

Nishanth Menon (2):
arm: mach-k3: Move K3 degenerate keys out of board folder
arm: mach-k3: Move TI dummy keys out of board folder

 arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi         | 8 --------
 arch/arm/dts/k3-binman.dtsi                               | 4 ++--
 {board/ti => arch/arm/mach-k3}/keys/custMpk.crt           | 0
 {board/ti => arch/arm/mach-k3}/keys/custMpk.key           | 0
 {board/ti => arch/arm/mach-k3}/keys/custMpk.pem           | 0
 {board/ti => arch/arm/mach-k3}/keys/ti-degenerate-key.pem | 0
 6 files changed, 2 insertions(+), 10 deletions(-)
 rename {board/ti => arch/arm/mach-k3}/keys/custMpk.crt (100%)
 rename {board/ti => arch/arm/mach-k3}/keys/custMpk.key (100%)
 rename {board/ti => arch/arm/mach-k3}/keys/custMpk.pem (100%)
 rename {board/ti => arch/arm/mach-k3}/keys/ti-degenerate-key.pem (100%)
Signature · 1 line
2.40.0
#1 lore raw

PATCH v2 1/2 arm: mach-k3: Move K3 degenerate keys out of board folder

This file is common for all of K3, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

---
Changes from V1:
* Dropped the override from verdin dtsi

V1: https://lore.kernel.org/all/[email protected]/

 arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi         | 4 ----
 arch/arm/dts/k3-binman.dtsi                               | 2 +-
 {board/ti => arch/arm/mach-k3}/keys/ti-degenerate-key.pem | 0
 3 files changed, 1 insertion(+), 5 deletions(-)
 rename {board/ti => arch/arm/mach-k3}/keys/ti-degenerate-key.pem (100%)
arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi +0 -4
index b489d8afbe36..ea22bfb9bad6 100644
@@ -9,10 +9,6 @@
 	filename = "../../ti/keys/custMpk.pem";
 };
 
-&dkey_pem {
-	filename = "../../ti/keys/ti-degenerate-key.pem";
-};
-
 #ifdef CONFIG_TARGET_VERDIN_AM62_R5
 
 &binman {
arch/arm/dts/k3-binman.dtsi +1 -1
index 0212d44ee3b2..b941726e6246 100644
@@ -20,7 +20,7 @@
 	ti-degenerate-key {
 		filename = "ti-degenerate-key.pem";
 		dkey_pem: blob-ext {
-			filename = "../keys/ti-degenerate-key.pem";
+			filename = "arch/arm/mach-k3/keys/ti-degenerate-key.pem";
 		};
 	};
 };
arch/arm/mach-k3/keys/ti-degenerate-key.pem renamed from board/ti/keys/ti-degenerate-key.pem +0 -0
similarity index 100%
rename from board/ti/keys/ti-degenerate-key.pem
rename to arch/arm/mach-k3/keys/ti-degenerate-key.pem
Signature · 1 line
2.40.0
Reviewed-by on v2 1/2
#2 lore raw

Re: [PATCH V2 1/2] arm: mach-k3: Move K3 degenerate keys out of board folder

Quoted 8 lines · Nishanth Menon

This file is common for all of K3, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

Francesco

Reviewed-by on v2 1/2
#3 lore raw

Re: [PATCH V2 1/2] arm: mach-k3: Move K3 degenerate keys out of board folder

In reply to Nishanth Menon
Quoted 9 lines · Nishanth Menon

This file is common for all of K3, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

---

Quoted 43 lines

Changes from V1:
* Dropped the override from verdin dtsi

V1: https://lore.kernel.org/all/[email protected]/

  arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi         | 4 ----
  arch/arm/dts/k3-binman.dtsi                               | 2 +-
  {board/ti => arch/arm/mach-k3}/keys/ti-degenerate-key.pem | 0
  3 files changed, 1 insertion(+), 5 deletions(-)

rename {board/ti => arch/arm/mach-k3}/keys/ti-degenerate-key.pem (100%)

arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi +0 -4
index b489d8afbe36..ea22bfb9bad6 100644
@@ -9,10 +9,6 @@
  	filename = "../../ti/keys/custMpk.pem";
  };
 
-&dkey_pem {
-	filename = "../../ti/keys/ti-degenerate-key.pem";
-};
-
  #ifdef CONFIG_TARGET_VERDIN_AM62_R5
 
  &binman {
arch/arm/dts/k3-binman.dtsi +1 -1
index 0212d44ee3b2..b941726e6246 100644
@@ -20,7 +20,7 @@
  	ti-degenerate-key {
  		filename = "ti-degenerate-key.pem";
  		dkey_pem: blob-ext {
-			filename = "../keys/ti-degenerate-key.pem";
+			filename = "arch/arm/mach-k3/keys/ti-degenerate-key.pem";
  		};
  	};
  };
arch/arm/mach-k3/keys/ti-degenerate-key.pem renamed from board/ti/keys/ti-degenerate-key.pem +0 -0
similarity index 100%
rename from board/ti/keys/ti-degenerate-key.pem
rename to arch/arm/mach-k3/keys/ti-degenerate-key.pem
#4 lore raw

Re: [PATCH V2 1/2] arm: mach-k3: Move K3 degenerate keys out of board folder

In reply to Nishanth Menon
Quoted 10 lines · Nishanth Menon

This file is common for all of K3, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

Applied to u-boot/next, thanks!

Signature · 1 line
Tom
#5 lore raw

PATCH v2 2/2 arm: mach-k3: Move TI dummy keys out of board folder

In reply to Nishanth Menon

This file is used to emulate customer keys on TI development board ecosystems, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

---
New patch in series.

 arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi | 4 ----
 arch/arm/dts/k3-binman.dtsi                       | 2 +-
 {board/ti => arch/arm/mach-k3}/keys/custMpk.crt   | 0
 {board/ti => arch/arm/mach-k3}/keys/custMpk.key   | 0
 {board/ti => arch/arm/mach-k3}/keys/custMpk.pem   | 0
 5 files changed, 1 insertion(+), 5 deletions(-)
 rename {board/ti => arch/arm/mach-k3}/keys/custMpk.crt (100%)
 rename {board/ti => arch/arm/mach-k3}/keys/custMpk.key (100%)
 rename {board/ti => arch/arm/mach-k3}/keys/custMpk.pem (100%)
arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi +0 -4
index ea22bfb9bad6..58fde95adf67 100644
@@ -5,10 +5,6 @@
 
 #include "k3-binman.dtsi"
 
-&custmpk_pem {
-	filename = "../../ti/keys/custMpk.pem";
-};
-
 #ifdef CONFIG_TARGET_VERDIN_AM62_R5
 
 &binman {
arch/arm/dts/k3-binman.dtsi +1 -1
index b941726e6246..8d4b0b2454f6 100644
@@ -13,7 +13,7 @@
 	custMpk {
 		filename = "custMpk.pem";
 		custmpk_pem: blob-ext {
-			filename = "../keys/custMpk.pem";
+			filename = "arch/arm/mach-k3/keys/custMpk.pem";
 		};
 	};
 
arch/arm/mach-k3/keys/custMpk.crt renamed from board/ti/keys/custMpk.crt +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.crt
rename to arch/arm/mach-k3/keys/custMpk.crt
arch/arm/mach-k3/keys/custMpk.key renamed from board/ti/keys/custMpk.key +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.key
rename to arch/arm/mach-k3/keys/custMpk.key
arch/arm/mach-k3/keys/custMpk.pem renamed from board/ti/keys/custMpk.pem +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.pem
rename to arch/arm/mach-k3/keys/custMpk.pem
Signature · 1 line
2.40.0
Reviewed-by on v2 2/2
#6 lore raw

Re: [PATCH V2 2/2] arm: mach-k3: Move TI dummy keys out of board folder

Quoted 8 lines · Nishanth Menon

This file is used to emulate customer keys on TI development board ecosystems, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

#7 lore raw

Re: [PATCH V2 2/2] arm: mach-k3: Move TI dummy keys out of board folder

In reply to Nishanth Menon
Quoted 9 lines · Nishanth Menon

This file is used to emulate customer keys on TI development board ecosystems, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

---

Moving custMpk.pem looks good. But I don't know how .crt and .key are actually used right now, I'd guess they already get pulled in during FIT signing using relative paths so this might be okay.

Good to get an ACK from +Manorit to be sure though.

Andrew

Quoted 52 lines

New patch in series.

  arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi | 4 ----
  arch/arm/dts/k3-binman.dtsi                       | 2 +-
  {board/ti => arch/arm/mach-k3}/keys/custMpk.crt   | 0
  {board/ti => arch/arm/mach-k3}/keys/custMpk.key   | 0
  {board/ti => arch/arm/mach-k3}/keys/custMpk.pem   | 0
  5 files changed, 1 insertion(+), 5 deletions(-)

rename {board/ti => arch/arm/mach-k3}/keys/custMpk.crt (100%) rename {board/ti => arch/arm/mach-k3}/keys/custMpk.key (100%) rename {board/ti => arch/arm/mach-k3}/keys/custMpk.pem (100%)

arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi +0 -4
index ea22bfb9bad6..58fde95adf67 100644
@@ -5,10 +5,6 @@
 
  #include "k3-binman.dtsi"
 
-&custmpk_pem {
-	filename = "../../ti/keys/custMpk.pem";
-};
-
  #ifdef CONFIG_TARGET_VERDIN_AM62_R5
 
  &binman {
arch/arm/dts/k3-binman.dtsi +1 -1
index b941726e6246..8d4b0b2454f6 100644
@@ -13,7 +13,7 @@
  	custMpk {
  		filename = "custMpk.pem";
  		custmpk_pem: blob-ext {
-			filename = "../keys/custMpk.pem";
+			filename = "arch/arm/mach-k3/keys/custMpk.pem";
  		};
  	};
 
arch/arm/mach-k3/keys/custMpk.crt renamed from board/ti/keys/custMpk.crt +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.crt
rename to arch/arm/mach-k3/keys/custMpk.crt
arch/arm/mach-k3/keys/custMpk.key renamed from board/ti/keys/custMpk.key +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.key
rename to arch/arm/mach-k3/keys/custMpk.key
arch/arm/mach-k3/keys/custMpk.pem renamed from board/ti/keys/custMpk.pem +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.pem
rename to arch/arm/mach-k3/keys/custMpk.pem
#8 lore raw

Re: [PATCH V2 2/2] arm: mach-k3: Move TI dummy keys out of board folder

Quoted 8 lines · Andrew Davis
Quoted 7 lines · Nishanth Menon

This file is used to emulate customer keys on TI development board ecosystems, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

Quoted 9 lines
Quoted 2 lines

---

Moving custMpk.pem looks good. But I don't know how .crt and .key are actually used right now, I'd guess they already get pulled in during FIT signing using relative paths so this might be okay.

Good to get an ACK from +Manorit to be sure though.

I think the current yocto builds are not using the keys so should be okay. I wasn't able to get the u-boot keys and ended up using the keys in core-secdev. Might be a future action to actually use these keys, they currently just help in Upstream and people don't have to go to core-secdev for getting these.

Regards,
Manorit

Quoted 50 lines

Andrew

Quoted 48 lines

New patch in series.

  arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi | 4 ----
  arch/arm/dts/k3-binman.dtsi                       | 2 +-
  {board/ti => arch/arm/mach-k3}/keys/custMpk.crt   | 0
  {board/ti => arch/arm/mach-k3}/keys/custMpk.key   | 0
  {board/ti => arch/arm/mach-k3}/keys/custMpk.pem   | 0
  5 files changed, 1 insertion(+), 5 deletions(-)

rename {board/ti => arch/arm/mach-k3}/keys/custMpk.crt (100%) rename {board/ti => arch/arm/mach-k3}/keys/custMpk.key (100%) rename {board/ti => arch/arm/mach-k3}/keys/custMpk.pem (100%)

arch/arm/dts/k3-am625-verdin-wifi-dev-binman.dtsi +0 -4
index ea22bfb9bad6..58fde95adf67 100644
@@ -5,10 +5,6 @@
  #include "k3-binman.dtsi"
-&custmpk_pem {
-	filename = "../../ti/keys/custMpk.pem";
-};
-
  #ifdef CONFIG_TARGET_VERDIN_AM62_R5
  &binman {
arch/arm/dts/k3-binman.dtsi +1 -1
index b941726e6246..8d4b0b2454f6 100644
@@ -13,7 +13,7 @@
  	custMpk {
  		filename = "custMpk.pem";
  		custmpk_pem: blob-ext {
-			filename = "../keys/custMpk.pem";
+			filename = "arch/arm/mach-k3/keys/custMpk.pem";
  		};
  	};
arch/arm/mach-k3/keys/custMpk.crt renamed from board/ti/keys/custMpk.crt +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.crt
rename to arch/arm/mach-k3/keys/custMpk.crt
arch/arm/mach-k3/keys/custMpk.key renamed from board/ti/keys/custMpk.key +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.key
rename to arch/arm/mach-k3/keys/custMpk.key
arch/arm/mach-k3/keys/custMpk.pem renamed from board/ti/keys/custMpk.pem +0 -0
similarity index 100%
rename from board/ti/keys/custMpk.pem
rename to arch/arm/mach-k3/keys/custMpk.pem
#9 lore raw

Re: [PATCH V2 2/2] arm: mach-k3: Move TI dummy keys out of board folder

In reply to Nishanth Menon
Quoted 10 lines · Nishanth Menon

This file is used to emulate customer keys on TI development board ecosystems, move it out of board/ directory and into mach-k3. And change the relative paths to absolute paths in the binman paths.

While at it, drop the reference in verdin-binman file which is redundant.

Applied to u-boot/next, thanks!

Signature · 1 line
Tom