Restructured all vendors' Kconfig files to no longer source the boards'
Kconfigs from within the choice/endchoice block. This makes it possible to
define user visible board specific options. Moved all vendor names and PCI
ids to the vendors' Kconfigs. Now all options in each file depend on the same
symbol, so replaced all "depends on"s with a single "if". Sorted boards
(sort -d), cleaned whitespace.
This patch also introduces a dummy option BOARD_SPECIFIC_OPTIONS, which is
always "y" and never used. It it simply needed to have something to attach
the boards' "select" statements to.
Signed-off-by: Jens Rottmann <JRottmann@LiPPERTEmbedded.de>
Acked-by: Stefan Reinauer <stepan@coresystems.de>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5754 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
diff --git a/src/mainboard/via/Kconfig b/src/mainboard/via/Kconfig
index 8f2d0db..f272247 100644
--- a/src/mainboard/via/Kconfig
+++ b/src/mainboard/via/Kconfig
@@ -1,14 +1,39 @@
+if VENDOR_VIA
+
choice
prompt "Mainboard model"
- depends on VENDOR_VIA
+
+config BOARD_VIA_EPIA
+ bool "EPIA"
+config BOARD_VIA_EPIA_CN
+ bool "EPIA-CN"
+config BOARD_VIA_EPIA_M700
+ bool "EPIA-M700"
+config BOARD_VIA_EPIA_M
+ bool "EPIA-M"
+config BOARD_VIA_EPIA_N
+ bool "EPIA-N"
+config BOARD_VIA_PC2500E
+ bool "pc2500e"
+config BOARD_VIA_VT8454C
+ bool "VT8454c"
+
+endchoice
source "src/mainboard/via/epia/Kconfig"
source "src/mainboard/via/epia-cn/Kconfig"
-source "src/mainboard/via/epia-m/Kconfig"
source "src/mainboard/via/epia-m700/Kconfig"
+source "src/mainboard/via/epia-m/Kconfig"
source "src/mainboard/via/epia-n/Kconfig"
source "src/mainboard/via/pc2500e/Kconfig"
source "src/mainboard/via/vt8454c/Kconfig"
-endchoice
+config MAINBOARD_VENDOR
+ string
+ default "VIA"
+config MAINBOARD_PCI_SUBSYSTEM_VENDOR_ID
+ hex
+ default 0x1019
+
+endif # VENDOR_VIA
diff --git a/src/mainboard/via/epia-cn/Kconfig b/src/mainboard/via/epia-cn/Kconfig
index 2066321..a228c3d 100644
--- a/src/mainboard/via/epia-cn/Kconfig
+++ b/src/mainboard/via/epia-cn/Kconfig
@@ -1,5 +1,7 @@
-config BOARD_VIA_EPIA_CN
- bool "EPIA-CN"
+if BOARD_VIA_EPIA_CN
+
+config BOARD_SPECIFIC_OPTIONS # dummy
+ def_bool y
select ARCH_X86
select CPU_VIA_C7
select NORTHBRIDGE_VIA_CN700
@@ -12,19 +14,17 @@
config MAINBOARD_DIR
string
default via/epia-cn
- depends on BOARD_VIA_EPIA_CN
config MAINBOARD_PART_NUMBER
string
default "EPIA-CN"
- depends on BOARD_VIA_EPIA_CN
config RAMBASE
hex
default 0x4000
- depends on BOARD_VIA_EPIA_CN
config IRQ_SLOT_COUNT
int
default 9
- depends on BOARD_VIA_EPIA_CN
+
+endif # BOARD_VIA_EPIA_CN
diff --git a/src/mainboard/via/epia-m/Kconfig b/src/mainboard/via/epia-m/Kconfig
index b424a9d..bf7f13d 100644
--- a/src/mainboard/via/epia-m/Kconfig
+++ b/src/mainboard/via/epia-m/Kconfig
@@ -1,5 +1,7 @@
-config BOARD_VIA_EPIA_M
- bool "EPIA-M"
+if BOARD_VIA_EPIA_M
+
+config BOARD_SPECIFIC_OPTIONS # dummy
+ def_bool y
select ARCH_X86
select CPU_VIA_C3
select NORTHBRIDGE_VIA_VT8623
@@ -16,15 +18,13 @@
config MAINBOARD_DIR
string
default via/epia-m
- depends on BOARD_VIA_EPIA_M
config MAINBOARD_PART_NUMBER
string
default "EPIA-M"
- depends on BOARD_VIA_EPIA_M
config IRQ_SLOT_COUNT
int
default 5
- depends on BOARD_VIA_EPIA_M
+endif # BOARD_VIA_EPIA_M
diff --git a/src/mainboard/via/epia-m700/Kconfig b/src/mainboard/via/epia-m700/Kconfig
index 1756426..43a36ce 100644
--- a/src/mainboard/via/epia-m700/Kconfig
+++ b/src/mainboard/via/epia-m700/Kconfig
@@ -1,5 +1,7 @@
-config BOARD_VIA_EPIA_M700
- bool "EPIA-M700"
+if BOARD_VIA_EPIA_M700
+
+config BOARD_SPECIFIC_OPTIONS # dummy
+ def_bool y
select ARCH_X86
select CPU_VIA_C7
select NORTHBRIDGE_VIA_VX800
@@ -12,19 +14,17 @@
config MAINBOARD_DIR
string
default via/epia-m700
- depends on BOARD_VIA_EPIA_M700
config MAINBOARD_PART_NUMBER
string
default "EPIA-M700"
- depends on BOARD_VIA_EPIA_M700
config RAMBASE
hex
default 0x4000
- depends on BOARD_VIA_EPIA_M700
config IRQ_SLOT_COUNT
int
default 13
- depends on BOARD_VIA_EPIA_M700
+
+endif # BOARD_VIA_EPIA_M700
diff --git a/src/mainboard/via/epia-n/Kconfig b/src/mainboard/via/epia-n/Kconfig
index 1356b7a..6b7a896 100644
--- a/src/mainboard/via/epia-n/Kconfig
+++ b/src/mainboard/via/epia-n/Kconfig
@@ -1,5 +1,7 @@
-config BOARD_VIA_EPIA_N
- bool "EPIA-N"
+if BOARD_VIA_EPIA_N
+
+config BOARD_SPECIFIC_OPTIONS # dummy
+ def_bool y
select ARCH_X86
select CPU_VIA_C3
select NORTHBRIDGE_VIA_CN400
@@ -17,20 +19,17 @@
config MAINBOARD_DIR
string
default via/epia-n
- depends on BOARD_VIA_EPIA_N
config MAINBOARD_PART_NUMBER
string
default "EPIA-N"
- depends on BOARD_VIA_EPIA_N
config RAMBASE
hex
default 0x4000
- depends on BOARD_VIA_EPIA_N
config IRQ_SLOT_COUNT
int
default 7
- depends on BOARD_VIA_EPIA_N
+endif # BOARD_VIA_EPIA_N
diff --git a/src/mainboard/via/epia/Kconfig b/src/mainboard/via/epia/Kconfig
index 05a9735..e4fa3b8 100644
--- a/src/mainboard/via/epia/Kconfig
+++ b/src/mainboard/via/epia/Kconfig
@@ -1,5 +1,7 @@
-config BOARD_VIA_EPIA
- bool "EPIA"
+if BOARD_VIA_EPIA
+
+config BOARD_SPECIFIC_OPTIONS # dummy
+ def_bool y
select ARCH_X86
select CPU_VIA_C3
select NORTHBRIDGE_VIA_VT8601
@@ -13,19 +15,17 @@
config MAINBOARD_DIR
string
default via/epia
- depends on BOARD_VIA_EPIA
config MAINBOARD_PART_NUMBER
string
default "EPIA"
- depends on BOARD_VIA_EPIA
config RAMBASE
hex
default 0x4000
- depends on BOARD_VIA_EPIA
config IRQ_SLOT_COUNT
int
default 5
- depends on BOARD_VIA_EPIA
+
+endif # BOARD_VIA_EPIA
diff --git a/src/mainboard/via/pc2500e/Kconfig b/src/mainboard/via/pc2500e/Kconfig
index f2bf195..96932d7 100644
--- a/src/mainboard/via/pc2500e/Kconfig
+++ b/src/mainboard/via/pc2500e/Kconfig
@@ -1,5 +1,7 @@
-config BOARD_VIA_PC2500E
- bool "pc2500e"
+if BOARD_VIA_PC2500E
+
+config BOARD_SPECIFIC_OPTIONS # dummy
+ def_bool y
select ARCH_X86
select CPU_VIA_C7
select NORTHBRIDGE_VIA_CN700
@@ -15,40 +17,33 @@
config MAINBOARD_DIR
string
default via/pc2500e
- depends on BOARD_VIA_PC2500E
config MAINBOARD_PART_NUMBER
string
default "pc2500e"
- depends on BOARD_VIA_PC2500E
config RAMBASE
hex
default 0x4000
- depends on BOARD_VIA_PC2500E
config IRQ_SLOT_COUNT
int
default 10
- depends on BOARD_VIA_PC2500E
config MAINBOARD_PCI_SUBSYSTEM_VENDOR_ID
hex
default 0x1019
- depends on BOARD_VIA_PC2500E
config MAINBOARD_PCI_SUBSYSTEM_DEVICE_ID
hex
default 0xaa51
- depends on BOARD_VIA_PC2500E
config FALLBACK_VGA_BIOS_FILE
string
default "M14CRT.ROM"
- depends on BOARD_VIA_PC2500E
config FALLBACK_VGA_BIOS_ID
string
default "1106,3344"
- depends on BOARD_VIA_PC2500E
+endif # BOARD_VIA_PC2500E
diff --git a/src/mainboard/via/vt8454c/Kconfig b/src/mainboard/via/vt8454c/Kconfig
index 33b75b4..547f6c6 100644
--- a/src/mainboard/via/vt8454c/Kconfig
+++ b/src/mainboard/via/vt8454c/Kconfig
@@ -1,5 +1,7 @@
-config BOARD_VIA_VT8454C
- bool "VT8454c"
+if BOARD_VIA_VT8454C
+
+config BOARD_SPECIFIC_OPTIONS # dummy
+ def_bool y
select ARCH_X86
select CPU_VIA_C7
select NORTHBRIDGE_VIA_CX700
@@ -18,19 +20,17 @@
config MAINBOARD_DIR
string
default via/vt8454c
- depends on BOARD_VIA_VT8454C
config MAINBOARD_PART_NUMBER
string
default "VT8454c"
- depends on BOARD_VIA_VT8454C
config IRQ_SLOT_COUNT
int
default 15
- depends on BOARD_VIA_VT8454C
config RAMBASE
hex
default 0x4000
- depends on BOARD_VIA_VT8454C
+
+endif # BOARD_VIA_VT8454C