Skip to contentSkip to conversation

mach-snapdragon: Allow other board vendors apart from Qcom

PATCH Superseded Sumit Garg 2 participants 2 messages Apr 11, 2024

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Sumit Garg

author
#0 lore raw

PATCH 1/1 mach-snapdragon: Allow other board vendors apart from Qcom

Qcom SoCs derived boards can come from various OEMs/ODMs and not just Qcom itself. So allow CONFIG_SYS_VENDOR to be set correctly corressponding to the actual board vendor.

---
 arch/arm/mach-snapdragon/Kconfig  | 15 +++++++++------
 configs/dragonboard410c_defconfig |  1 +
 configs/dragonboard820c_defconfig |  1 +
 3 files changed, 11 insertions(+), 6 deletions(-)
arch/arm/mach-snapdragon/Kconfig +9 -6
index 96e44e2c549..4615a140d0d 100644
@@ -4,7 +4,11 @@ config SYS_SOC
 	default "snapdragon"
 
 config SYS_VENDOR
-	default "qualcomm"
+	string "Snapdragon board vendor"
+	help
+	  Allows to specify vendor for the Snapdragon SoCs based boards.
+	  Based on this option board/<CONFIG_SYS_VENDOR>/<CONFIG_SYS_BOARD>
+	  will be used as the custom board directory.
 
 config SYS_MALLOC_F_LEN
 	default 0x2000
@@ -19,12 +23,11 @@ config LNX_KRNL_IMG_TEXT_OFFSET_BASE
 	default 0x80000000
 
 config SYS_BOARD
-	string "Qualcomm custom board"
+	string "Snapdragon SoCs based board"
 	help
-	  The Dragonboard 410c and 820c have additional board init
-	  code that isn't shared with other Qualcomm boards.
-	  Based on this option board/qualcomm/<CONFIG_SYS_BOARD> will
-	  be used.
+	  Allows to specify the Snapdragon SoCs based board name.
+	  Based on this option board/<CONFIG_SYS_VENDOR>/<CONFIG_SYS_BOARD>
+	  will be used as the custom board directory.
 
 config SYS_CONFIG_NAME
 	string "Board configuration name"
configs/dragonboard410c_defconfig +1 -0
index 260a8349d3b..3b6f50307a3 100644
@@ -1,4 +1,5 @@
 CONFIG_ARM=y
+CONFIG_SYS_VENDOR="qualcomm"
 CONFIG_SYS_BOARD="dragonboard410c"
 CONFIG_COUNTER_FREQUENCY=19000000
 CONFIG_ENABLE_ARM_SOC_BOOT0_HOOK=y
configs/dragonboard820c_defconfig +1 -0
index ebc80eb2a46..a795497ef5d 100644
@@ -1,4 +1,5 @@
 CONFIG_ARM=y
+CONFIG_SYS_VENDOR="qualcomm"
 CONFIG_SYS_BOARD="dragonboard820c"
 CONFIG_COUNTER_FREQUENCY=19000000
 CONFIG_ARCH_SNAPDRAGON=y
Signature · 1 line
2.34.1
Reviewed-by on v1 1/1
#1 lore raw

Hi Sumit,

Quoted 17 lines · Sumit Garg

Qcom SoCs derived boards can come from various OEMs/ODMs and not just Qcom itself. So allow CONFIG_SYS_VENDOR to be set correctly corressponding to the actual board vendor.

---
  arch/arm/mach-snapdragon/Kconfig  | 15 +++++++++------
  configs/dragonboard410c_defconfig |  1 +
  configs/dragonboard820c_defconfig |  1 +
  3 files changed, 11 insertions(+), 6 deletions(-)
arch/arm/mach-snapdragon/Kconfig +0 -0
index 96e44e2c549..4615a140d0d 100644

arch/arm/mach-snapdragon/Kconfig config SYS_SOC · line 7

Quoted 4 lines
arch/arm/mach-snapdragon/Kconfig +0 -1
@@ -4,7 +4,11 @@ config SYS_SOC
  	default "snapdragon"
 
  config SYS_VENDOR
-	default "qualcomm"

Can you keep the default rather than adding it to the defconfig?

With that

Quoted 45 lines
arch/arm/mach-snapdragon/Kconfig +9 -5
+	string "Snapdragon board vendor"
+	help
+	  Allows to specify vendor for the Snapdragon SoCs based boards.
+	  Based on this option board/<CONFIG_SYS_VENDOR>/<CONFIG_SYS_BOARD>
+	  will be used as the custom board directory.
 
  config SYS_MALLOC_F_LEN
  	default 0x2000
@@ -19,12 +23,11 @@ config LNX_KRNL_IMG_TEXT_OFFSET_BASE
  	default 0x80000000
 
  config SYS_BOARD
-	string "Qualcomm custom board"
+	string "Snapdragon SoCs based board"
  	help
-	  The Dragonboard 410c and 820c have additional board init
-	  code that isn't shared with other Qualcomm boards.
-	  Based on this option board/qualcomm/<CONFIG_SYS_BOARD> will
-	  be used.
+	  Allows to specify the Snapdragon SoCs based board name.
+	  Based on this option board/<CONFIG_SYS_VENDOR>/<CONFIG_SYS_BOARD>
+	  will be used as the custom board directory.
 
  config SYS_CONFIG_NAME
  	string "Board configuration name"
configs/dragonboard410c_defconfig +1 -0
index 260a8349d3b..3b6f50307a3 100644
@@ -1,4 +1,5 @@
  CONFIG_ARM=y
+CONFIG_SYS_VENDOR="qualcomm"
  CONFIG_SYS_BOARD="dragonboard410c"
  CONFIG_COUNTER_FREQUENCY=19000000
  CONFIG_ENABLE_ARM_SOC_BOOT0_HOOK=y
configs/dragonboard820c_defconfig +1 -0
index ebc80eb2a46..a795497ef5d 100644
@@ -1,4 +1,5 @@
  CONFIG_ARM=y
+CONFIG_SYS_VENDOR="qualcomm"
  CONFIG_SYS_BOARD="dragonboard820c"
  CONFIG_COUNTER_FREQUENCY=19000000
  CONFIG_ARCH_SNAPDRAGON=y
Signature · 1 line
// Caleb (they/them)