diff options
Diffstat (limited to 'lib/utils')
-rw-r--r-- | lib/utils/Kconfig | 4 | ||||
-rw-r--r-- | lib/utils/fdt/Kconfig | 18 | ||||
-rw-r--r-- | lib/utils/fdt/objects.mk | 8 | ||||
-rw-r--r-- | lib/utils/gpio/Kconfig | 1 | ||||
-rw-r--r-- | lib/utils/i2c/Kconfig | 1 | ||||
-rw-r--r-- | lib/utils/ipi/Kconfig | 1 | ||||
-rw-r--r-- | lib/utils/irqchip/Kconfig | 1 | ||||
-rw-r--r-- | lib/utils/libfdt/Kconfig | 5 | ||||
-rw-r--r-- | lib/utils/libfdt/objects.mk | 2 | ||||
-rw-r--r-- | lib/utils/reset/Kconfig | 1 | ||||
-rw-r--r-- | lib/utils/serial/Kconfig | 1 | ||||
-rw-r--r-- | lib/utils/timer/Kconfig | 1 |
12 files changed, 39 insertions, 5 deletions
diff --git a/lib/utils/Kconfig b/lib/utils/Kconfig index 673b02b..5a71e75 100644 --- a/lib/utils/Kconfig +++ b/lib/utils/Kconfig @@ -2,6 +2,8 @@ menu "Utils and Drivers Support" +source "$(OPENSBI_SRC_DIR)/lib/utils/fdt/Kconfig" + source "$(OPENSBI_SRC_DIR)/lib/utils/gpio/Kconfig" source "$(OPENSBI_SRC_DIR)/lib/utils/i2c/Kconfig" @@ -10,6 +12,8 @@ source "$(OPENSBI_SRC_DIR)/lib/utils/ipi/Kconfig" source "$(OPENSBI_SRC_DIR)/lib/utils/irqchip/Kconfig" +source "$(OPENSBI_SRC_DIR)/lib/utils/libfdt/Kconfig" + source "$(OPENSBI_SRC_DIR)/lib/utils/reset/Kconfig" source "$(OPENSBI_SRC_DIR)/lib/utils/serial/Kconfig" diff --git a/lib/utils/fdt/Kconfig b/lib/utils/fdt/Kconfig new file mode 100644 index 0000000..23b003b --- /dev/null +++ b/lib/utils/fdt/Kconfig @@ -0,0 +1,18 @@ +# SPDX-License-Identifier: BSD-2-Clause + +menuconfig FDT + bool "Flattened Device Tree (FDT) support" + select LIBFDT + default n + +if FDT + +config FDT_DOMAIN + bool "FDT domain support" + default n + +config FDT_PMU + bool "FDT performance monitoring unit (PMU) support" + default n + +endif diff --git a/lib/utils/fdt/objects.mk b/lib/utils/fdt/objects.mk index 03800f9..5cede81 100644 --- a/lib/utils/fdt/objects.mk +++ b/lib/utils/fdt/objects.mk @@ -4,7 +4,7 @@ # Copyright (C) 2020 Bin Meng <bmeng.cn@gmail.com> # -libsbiutils-objs-y += fdt/fdt_domain.o -libsbiutils-objs-y += fdt/fdt_pmu.o -libsbiutils-objs-y += fdt/fdt_helper.o -libsbiutils-objs-y += fdt/fdt_fixup.o +libsbiutils-objs-$(CONFIG_FDT_DOMAIN) += fdt/fdt_domain.o +libsbiutils-objs-$(CONFIG_FDT_PMU) += fdt/fdt_pmu.o +libsbiutils-objs-$(CONFIG_FDT) += fdt/fdt_helper.o +libsbiutils-objs-$(CONFIG_FDT) += fdt/fdt_fixup.o diff --git a/lib/utils/gpio/Kconfig b/lib/utils/gpio/Kconfig index daf7f91..38a9d75 100644 --- a/lib/utils/gpio/Kconfig +++ b/lib/utils/gpio/Kconfig @@ -4,6 +4,7 @@ menu "GPIO Support" config FDT_GPIO bool "FDT based GPIO drivers" + depends on FDT select GPIO default n diff --git a/lib/utils/i2c/Kconfig b/lib/utils/i2c/Kconfig index 16c4453..46a3454 100644 --- a/lib/utils/i2c/Kconfig +++ b/lib/utils/i2c/Kconfig @@ -4,6 +4,7 @@ menu "I2C Support" config FDT_I2C bool "FDT based I2C drivers" + depends on FDT select I2C default n diff --git a/lib/utils/ipi/Kconfig b/lib/utils/ipi/Kconfig index c0634d3..efc8960 100644 --- a/lib/utils/ipi/Kconfig +++ b/lib/utils/ipi/Kconfig @@ -4,6 +4,7 @@ menu "IPI Device Support" config FDT_IPI bool "FDT based ipi drivers" + depends on FDT default n if FDT_IPI diff --git a/lib/utils/irqchip/Kconfig b/lib/utils/irqchip/Kconfig index 6a7e297..7a71388 100644 --- a/lib/utils/irqchip/Kconfig +++ b/lib/utils/irqchip/Kconfig @@ -4,6 +4,7 @@ menu "Interrupt Controller Support" config FDT_IRQCHIP bool "FDT based interrupt controller drivers" + depends on FDT default n if FDT_IRQCHIP diff --git a/lib/utils/libfdt/Kconfig b/lib/utils/libfdt/Kconfig new file mode 100644 index 0000000..d1cecf8 --- /dev/null +++ b/lib/utils/libfdt/Kconfig @@ -0,0 +1,5 @@ +# SPDX-License-Identifier: BSD-2-Clause + +config LIBFDT + bool + default n diff --git a/lib/utils/libfdt/objects.mk b/lib/utils/libfdt/objects.mk index 8c060df..0e01b54 100644 --- a/lib/utils/libfdt/objects.mk +++ b/lib/utils/libfdt/objects.mk @@ -12,5 +12,5 @@ libfdt_files = fdt.o fdt_addresses.o fdt_check.o fdt_empty_tree.o fdt_ro.o fdt_r $(foreach file, $(libfdt_files), \ $(eval CFLAGS_$(file) = -I$(src)/../../utils/libfdt)) -libsbiutils-objs-y += $(addprefix libfdt/,$(libfdt_files)) +libsbiutils-objs-$(CONFIG_LIBFDT) += $(addprefix libfdt/,$(libfdt_files)) libsbiutils-genflags-y += -I$(libsbiutils_dir)/libfdt/ diff --git a/lib/utils/reset/Kconfig b/lib/utils/reset/Kconfig index 71996cb..2e83ff6 100644 --- a/lib/utils/reset/Kconfig +++ b/lib/utils/reset/Kconfig @@ -4,6 +4,7 @@ menu "System Reset Support" config FDT_RESET bool "FDT based reset drivers" + depends on FDT default n if FDT_RESET diff --git a/lib/utils/serial/Kconfig b/lib/utils/serial/Kconfig index bf37e34..152060d 100644 --- a/lib/utils/serial/Kconfig +++ b/lib/utils/serial/Kconfig @@ -4,6 +4,7 @@ menu "Serial Device Support" config FDT_SERIAL bool "FDT based serial drivers" + depends on FDT default n if FDT_SERIAL diff --git a/lib/utils/timer/Kconfig b/lib/utils/timer/Kconfig index 0a1c727..23c48c5 100644 --- a/lib/utils/timer/Kconfig +++ b/lib/utils/timer/Kconfig @@ -4,6 +4,7 @@ menu "Timer Device Support" config FDT_TIMER bool "FDT based timer drivers" + depends on FDT default n if FDT_TIMER |