From 6bd77c848cafe1b5c2cb2bd60f9b7f369ee80cc5 Mon Sep 17 00:00:00 2001 From: Jordan Yates Date: Thu, 11 Jul 2024 21:09:17 +1000 Subject: [PATCH] disk: use standard DT kconfig dependencies Use `depends on DT_HAS_* default y` instead of `default y if DT_HAS_*` as the driver depends on devicetree instance. Signed-off-by: Jordan Yates --- drivers/disk/Kconfig.mmc | 3 ++- drivers/disk/Kconfig.ram | 3 ++- drivers/disk/Kconfig.sdmmc | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/disk/Kconfig.mmc b/drivers/disk/Kconfig.mmc index b17a756b55b..72a81b8e60f 100644 --- a/drivers/disk/Kconfig.mmc +++ b/drivers/disk/Kconfig.mmc @@ -3,7 +3,8 @@ config DISK_DRIVER_MMC bool "MMC card driver" - default y if DT_HAS_ZEPHYR_MMC_DISK_ENABLED + depends on DT_HAS_ZEPHYR_MMC_DISK_ENABLED + default y help MMC card driver. diff --git a/drivers/disk/Kconfig.ram b/drivers/disk/Kconfig.ram index f09bd3af45f..137596fbd9c 100644 --- a/drivers/disk/Kconfig.ram +++ b/drivers/disk/Kconfig.ram @@ -3,7 +3,8 @@ config DISK_DRIVER_RAM bool "RAM Disk" - default y if DT_HAS_ZEPHYR_RAM_DISK_ENABLED + depends on DT_HAS_ZEPHYR_RAM_DISK_ENABLED + default y help RAM buffer used to emulate storage disk. This option can be used to test the file diff --git a/drivers/disk/Kconfig.sdmmc b/drivers/disk/Kconfig.sdmmc index b1999b64eff..01272176ffb 100644 --- a/drivers/disk/Kconfig.sdmmc +++ b/drivers/disk/Kconfig.sdmmc @@ -6,8 +6,9 @@ DT_STM32_SDMMC_HAS_DMA := $(dt_nodelabel_has_prop,sdmmc,dmas) config DISK_DRIVER_SDMMC bool "SDMMC card driver" - default y if DT_HAS_ZEPHYR_SDMMC_DISK_ENABLED || \ + depends on DT_HAS_ZEPHYR_SDMMC_DISK_ENABLED || \ DT_HAS_ST_STM32_SDMMC_ENABLED + default y help SDMMC card driver.