[U-Boot] [PATCH 34/47] Kconfig: Add a CONFIG_IDE option

Simon Glass
2017-05-15T10:57:49Z

At present IDE support is controlled by CONFIG_CMD_IDE. Add a separate
CONFIG_IDE option so that IDE support can be enabled without requiring
the 'ide' command.

Update existing users and move the ide driver into drivers/block since
it should not be in common/.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

README | 2 +-
api/api_storage.c | 2 +-
arch/arm/mach-kirkwood/include/mach/config.h | 6 +++---
arch/powerpc/cpu/mpc5xxx/ide.c | 2 +-
arch/powerpc/lib/Makefile | 2 +-
board/freescale/m5253demo/m5253demo.c | 4 ++--
board/freescale/m5253evbe/m5253evbe.c | 4 ++--
board/freescale/m54455evb/m54455evb.c | 2 +-
board/intercontrol/digsy_mtc/digsy_mtc.c | 4 ++--
board/jupiter/jupiter.c | 2 +-
board/phytec/pcm030/pcm030.c | 4 ++--
board/tqc/tqm5200/tqm5200.c | 2 +-
board/v38b/v38b.c | 2 +-
cmd/Kconfig | 1 +
cmd/pcmcia.c | 2 +-
common/Makefile | 1 -
common/board_r.c | 10 ++++------
drivers/block/Kconfig | 8 ++++++++
drivers/block/Makefile | 1 +
{common => drivers/block}/ide.c | 0
drivers/block/sil680.c | 2 +-
drivers/pcmcia/marubun_pcmcia.c | 2 +-
drivers/pcmcia/mpc8xx_pcmcia.c | 2 +-
drivers/pcmcia/tqm8xx_pcmcia.c | 2 +-
fs/fat/fat.c | 2 +-
include/config_distro_bootcmd.h | 6 +++---
include/config_fallbacks.h | 2 +-
include/configs/M5253DEMO.h | 2 +-
include/configs/edminiv2.h | 2 +-
include/configs/ib62x0.h | 4 ++--
include/configs/lsxl.h | 2 +-
include/configs/mpc5121ads.h | 4 ++--
include/configs/nsa310s.h | 4 ++--
include/configs/qemu-x86.h | 4 ++--
include/configs/r7780mp.h | 4 ++--
include/configs/sheevaplug.h | 4 ++--
include/pcmcia.h | 4 ++--
37 files changed, 60 insertions(+), 53 deletions(-)
rename {common => drivers/block}/ide.c (100%)

diff --git a/README b/README
index a758af87b4..e069dd53a5 100644
--- a/README
+++ b/README
@@ -1081,7 +1081,7 @@ The following options need to be configured:
disk/part_efi.c
CONFIG_MTD_PARTITIONS Memory Technology Device partition table.

- If IDE or SCSI support is enabled (CONFIG_CMD_IDE or
+ If IDE or SCSI support is enabled (CONFIG_IDE or
CONFIG_SCSI) you must configure support for at
least one non-MTD partition type as well.

diff --git a/api/api_storage.c b/api/api_storage.c
index a5357bc9cf..f858f09f1a 100644
--- a/api/api_storage.c
+++ b/api/api_storage.c
@@ -46,7 +46,7 @@ static struct stor_spec specs[ENUM_MAX] = { { 0, 0, 0, 0, NULL }, };

void dev_stor_init(void)
{
-#if defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_IDE)
specs[ENUM_IDE].max_dev = CONFIG_SYS_IDE_MAXDEVICE;
specs[ENUM_IDE].enum_started = 0;
specs[ENUM_IDE].enum_ended = 0;
diff --git a/arch/arm/mach-kirkwood/include/mach/config.h b/arch/arm/mach-kirkwood/include/mach/config.h
index b786df0aaf..1d2f2613b4 100644
--- a/arch/arm/mach-kirkwood/include/mach/config.h
+++ b/arch/arm/mach-kirkwood/include/mach/config.h
@@ -96,7 +96,7 @@
/*
* IDE Support on SATA ports
*/
-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#define __io
#define CONFIG_MVSATA_IDE
#define CONFIG_IDE_PREINIT
@@ -111,12 +111,12 @@
#define CONFIG_SYS_ATA_STRIDE 4
/* Controller supports 48-bits LBA addressing */
#define CONFIG_LBA48
-/* CONFIG_CMD_IDE requires some #defines for ATA registers */
+/* CONFIG_IDE requires some #defines for ATA registers */
#define CONFIG_SYS_IDE_MAXBUS 2
#define CONFIG_SYS_IDE_MAXDEVICE 2
/* ATA registers base is at SATA controller base */
#define CONFIG_SYS_ATA_BASE_ADDR MV_SATA_BASE
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */

/*
* I2C related stuff
diff --git a/arch/powerpc/cpu/mpc5xxx/ide.c b/arch/powerpc/cpu/mpc5xxx/ide.c
index 9003b774ff..d1f4349184 100644
--- a/arch/powerpc/cpu/mpc5xxx/ide.c
+++ b/arch/powerpc/cpu/mpc5xxx/ide.c
@@ -8,7 +8,7 @@
*/
#include <common.h>

-#if defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_IDE)
#include <mpc5xxx.h>

DECLARE_GLOBAL_DATA_PTR;
diff --git a/arch/powerpc/lib/Makefile b/arch/powerpc/lib/Makefile
index 4f68613a41..88adb26e2e 100644
--- a/arch/powerpc/lib/Makefile
+++ b/arch/powerpc/lib/Makefile
@@ -35,7 +35,7 @@ obj-y += cache.o
obj-y += extable.o
obj-y += interrupts.o
obj-$(CONFIG_CMD_KGDB) += kgdb.o
-obj-$(CONFIG_CMD_IDE) += ide.o
+obj-$(CONFIG_IDE) += ide.o
obj-y += stack.o
obj-y += time.o

diff --git a/board/freescale/m5253demo/m5253demo.c b/board/freescale/m5253demo/m5253demo.c
index c2cc2d76e4..3318368623 100644
--- a/board/freescale/m5253demo/m5253demo.c
+++ b/board/freescale/m5253demo/m5253demo.c
@@ -88,7 +88,7 @@ int testdram(void)
return (0);
}

-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#include <ata.h>
int ide_preinit(void)
{
@@ -133,7 +133,7 @@ void ide_set_reset(int idereset)
setbits_8(&ata->cr, 0x01);
}
}
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */

#ifdef CONFIG_DRIVER_DM9000
diff --git a/board/freescale/m5253evbe/m5253evbe.c b/board/freescale/m5253evbe/m5253evbe.c
index c1ed431190..2c6afadb9a 100644
--- a/board/freescale/m5253evbe/m5253evbe.c
+++ b/board/freescale/m5253evbe/m5253evbe.c
@@ -81,7 +81,7 @@ int testdram(void)
return (0);
}

-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#include <ata.h>
int ide_preinit(void)
{
@@ -126,4 +126,4 @@ void ide_set_reset(int idereset)
setbits_8(&ata->cr, 0x01);
}
}
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */
diff --git a/board/freescale/m54455evb/m54455evb.c b/board/freescale/m54455evb/m54455evb.c
index d6b0650b99..1e35970023 100644
--- a/board/freescale/m54455evb/m54455evb.c
+++ b/board/freescale/m54455evb/m54455evb.c
@@ -88,7 +88,7 @@ int testdram(void)
return (0);
}

-#if defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_IDE)
#include <ata.h>

int ide_preinit(void)
diff --git a/board/intercontrol/digsy_mtc/digsy_mtc.c b/board/intercontrol/digsy_mtc/digsy_mtc.c
index b8bc0459f8..6c33eeb022 100644
--- a/board/intercontrol/digsy_mtc/digsy_mtc.c
+++ b/board/intercontrol/digsy_mtc/digsy_mtc.c
@@ -325,7 +325,7 @@ void pci_init_board(void)
}
#endif

-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE

#ifdef CONFIG_IDE_RESET

@@ -369,7 +369,7 @@ void ide_set_reset(int idereset)
setbits_be32((void *)MPC5XXX_WU_GPIO_ENABLE, (1 << 25));
}
#endif /* CONFIG_IDE_RESET */
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */

#ifdef CONFIG_OF_BOARD_SETUP
static void ft_delete_node(void *fdt, const char *compat)
diff --git a/board/jupiter/jupiter.c b/board/jupiter/jupiter.c
index ea24eaa5c0..52d2766e9a 100644
--- a/board/jupiter/jupiter.c
+++ b/board/jupiter/jupiter.c
@@ -259,7 +259,7 @@ void pci_init_board(void)
}
#endif

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_RESET)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_RESET)

void init_ide_reset (void)
{
diff --git a/board/phytec/pcm030/pcm030.c b/board/phytec/pcm030/pcm030.c
index 983559e81e..bdd980da91 100644
--- a/board/phytec/pcm030/pcm030.c
+++ b/board/phytec/pcm030/pcm030.c
@@ -176,7 +176,7 @@ int ft_board_setup(void *blob, bd_t *bd)
}
#endif /* CONFIG_OF_BOARD_SETUP */

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_RESET)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_RESET)

#define GPIO_PSC2_4 0x02000000UL

@@ -206,4 +206,4 @@ void ide_set_reset(int idereset)
} else
setbits_be32(&wu_gpio->dvo, GPIO_PSC2_4);
}
-#endif /* defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_RESET) */
+#endif /* defined(CONFIG_IDE) && defined(CONFIG_IDE_RESET) */
diff --git a/board/tqc/tqm5200/tqm5200.c b/board/tqc/tqm5200/tqm5200.c
index 92db093dbf..6a19b1ad07 100644
--- a/board/tqc/tqm5200/tqm5200.c
+++ b/board/tqc/tqm5200/tqm5200.c
@@ -312,7 +312,7 @@ void pci_init_board(void)
}
#endif

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_RESET)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_RESET)

#if defined (CONFIG_MINIFAP)
#define SM501_POWER_MODE0_GATE 0x00000040UL
diff --git a/board/v38b/v38b.c b/board/v38b/v38b.c
index 73227c1b15..e680b7b8ff 100644
--- a/board/v38b/v38b.c
+++ b/board/v38b/v38b.c
@@ -224,7 +224,7 @@ int misc_init_r(void)
return 0;
}

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_RESET)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_RESET)
void init_ide_reset(void)
{
debug("init_ide_reset\n");
diff --git a/cmd/Kconfig b/cmd/Kconfig
index 2c89a773d0..1268e38b59 100644
--- a/cmd/Kconfig
+++ b/cmd/Kconfig
@@ -486,6 +486,7 @@ config CMD_DEMO

config CMD_IDE
bool "ide - Support for IDE drivers"
+ select IDE
help
Provides an 'ide' command which allows accessing the IDE drive,
reseting the IDE interface, printing the partition table and
diff --git a/cmd/pcmcia.c b/cmd/pcmcia.c
index 682d18f55d..044fb9e618 100644
--- a/cmd/pcmcia.c
+++ b/cmd/pcmcia.c
@@ -83,7 +83,7 @@ U_BOOT_CMD(

#undef CHECK_IDE_DEVICE

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
#define CHECK_IDE_DEVICE
#endif

diff --git a/common/Makefile b/common/Makefile
index b2d663530d..c7c8ea42c6 100644
--- a/common/Makefile
+++ b/common/Makefile
@@ -145,7 +145,6 @@ obj-y += dlmalloc.o
ifdef CONFIG_SYS_MALLOC_F_LEN
obj-y += malloc_simple.o
endif
-obj-$(CONFIG_CMD_IDE) += ide.o
obj-y += image.o
obj-$(CONFIG_ANDROID_BOOT_IMAGE) += image-android.o
obj-$(CONFIG_$(SPL_)OF_LIBFDT) += image-fdt.o
diff --git a/common/board_r.c b/common/board_r.c
index d69a33c4a3..dbb9a5caef 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -23,9 +23,7 @@
#include <dm.h>
#include <environment.h>
#include <fdtdec.h>
-#if defined(CONFIG_CMD_IDE)
#include <ide.h>
-#endif
#include <initcall.h>
#include <init_helpers.h>
#ifdef CONFIG_PS2KBD
@@ -628,7 +626,7 @@ static int initr_post(void)
}
#endif

-#if defined(CONFIG_CMD_PCMCIA) && !defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_CMD_PCMCIA) && !defined(CONFIG_IDE)
static int initr_pcmcia(void)
{
puts("PCMCIA:");
@@ -637,7 +635,7 @@ static int initr_pcmcia(void)
}
#endif

-#if defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_IDE)
static int initr_ide(void)
{
#ifdef CONFIG_IDE_8xx_PCCARD
@@ -887,10 +885,10 @@ static init_fnc_t init_sequence_r[] = {
#ifdef CONFIG_POST
initr_post,
#endif
-#if defined(CONFIG_CMD_PCMCIA) && !defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_CMD_PCMCIA) && !defined(CONFIG_IDE)
initr_pcmcia,
#endif
-#if defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_IDE)
initr_ide,
#endif
#ifdef CONFIG_LAST_STAGE_INIT
diff --git a/drivers/block/Kconfig b/drivers/block/Kconfig
index 6cbe1454b8..931defd2ae 100644
--- a/drivers/block/Kconfig
+++ b/drivers/block/Kconfig
@@ -59,3 +59,11 @@ config DWC_AHCI
Synopsys DWC AHCI module.

endmenu
+
+config IDE
+ bool "Support IDE controllers"
+ help
+ Enables support for IDE (Integrated Drive Electronics) hard drives.
+ This allows access to raw blocks and filesystems on an IDE drive
+ from U-Boot. See also CMD_IDE which provides an 'ide' command for
+ performing various IDE operations.
diff --git a/drivers/block/Makefile b/drivers/block/Makefile
index d89c8b0574..06450966b1 100644
--- a/drivers/block/Makefile
+++ b/drivers/block/Makefile
@@ -17,6 +17,7 @@ obj-$(CONFIG_DM_SCSI) += scsi-uclass.o
obj-$(CONFIG_SCSI_AHCI) += ahci.o
obj-$(CONFIG_DWC_AHSATA) += dwc_ahsata.o
obj-$(CONFIG_FSL_SATA) += fsl_sata.o
+obj-$(CONFIG_IDE) += ide.o
obj-$(CONFIG_IDE_FTIDE020) += ftide020.o
obj-$(CONFIG_LIBATA) += libata.o
obj-$(CONFIG_MVSATA_IDE) += mvsata_ide.o
diff --git a/common/ide.c b/drivers/block/ide.c
similarity index 100%
rename from common/ide.c
rename to drivers/block/ide.c
diff --git a/drivers/block/sil680.c b/drivers/block/sil680.c
index 3ca64b980d..b1db257838 100644
--- a/drivers/block/sil680.c
+++ b/drivers/block/sil680.c
@@ -17,7 +17,7 @@
* incorrect for the target board (e.g. the sequoia board requires 0).
* #define CONFIG_SYS_PCI_CACHE_LINE_SIZE 0
*
- * #define CONFIG_CMD_IDE
+ * #define CONFIG_IDE
* #undef CONFIG_IDE_8xx_DIRECT
* #undef CONFIG_IDE_LED
* #undef CONFIG_IDE_RESET
diff --git a/drivers/pcmcia/marubun_pcmcia.c b/drivers/pcmcia/marubun_pcmcia.c
index afd6df6440..739d7545da 100644
--- a/drivers/pcmcia/marubun_pcmcia.c
+++ b/drivers/pcmcia/marubun_pcmcia.c
@@ -17,7 +17,7 @@
#define CONFIG_PCMCIA
#endif

-#if defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_IDE)
#define CONFIG_PCMCIA
#endif

diff --git a/drivers/pcmcia/mpc8xx_pcmcia.c b/drivers/pcmcia/mpc8xx_pcmcia.c
index 1b41e39158..dae5560f8c 100644
--- a/drivers/pcmcia/mpc8xx_pcmcia.c
+++ b/drivers/pcmcia/mpc8xx_pcmcia.c
@@ -9,7 +9,7 @@
#define CONFIG_PCMCIA
#endif

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
#define CONFIG_PCMCIA
#endif

diff --git a/drivers/pcmcia/tqm8xx_pcmcia.c b/drivers/pcmcia/tqm8xx_pcmcia.c
index 45dcb54d71..edff50f630 100644
--- a/drivers/pcmcia/tqm8xx_pcmcia.c
+++ b/drivers/pcmcia/tqm8xx_pcmcia.c
@@ -15,7 +15,7 @@
#define CONFIG_PCMCIA
#endif

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
#define CONFIG_PCMCIA
#endif

diff --git a/fs/fat/fat.c b/fs/fat/fat.c
index 56540031d6..a71bad1cbc 100644
--- a/fs/fat/fat.c
+++ b/fs/fat/fat.c
@@ -1250,7 +1250,7 @@ int file_fat_detectfs(void)
return 1;
}

-#if defined(CONFIG_CMD_IDE) || \
+#if defined(CONFIG_IDE) || \
defined(CONFIG_CMD_SATA) || \
defined(CONFIG_SCSI) || \
defined(CONFIG_CMD_USB) || \
diff --git a/include/config_distro_bootcmd.h b/include/config_distro_bootcmd.h
index 0e01e8240d..4b2c493ae3 100644
--- a/include/config_distro_bootcmd.h
+++ b/include/config_distro_bootcmd.h
@@ -186,16 +186,16 @@
BOOT_TARGET_DEVICES_references_SCSI_without_CONFIG_SCSI
#endif

-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#define BOOTENV_SHARED_IDE BOOTENV_SHARED_BLKDEV(ide)
#define BOOTENV_DEV_IDE BOOTENV_DEV_BLKDEV
#define BOOTENV_DEV_NAME_IDE BOOTENV_DEV_NAME_BLKDEV
#else
#define BOOTENV_SHARED_IDE
#define BOOTENV_DEV_IDE \
- BOOT_TARGET_DEVICES_references_IDE_without_CONFIG_CMD_IDE
+ BOOT_TARGET_DEVICES_references_IDE_without_CONFIG_IDE
#define BOOTENV_DEV_NAME_IDE \
- BOOT_TARGET_DEVICES_references_IDE_without_CONFIG_CMD_IDE
+ BOOT_TARGET_DEVICES_references_IDE_without_CONFIG_IDE
#endif

#if defined(CONFIG_CMD_PCI_ENUM) || defined(CONFIG_DM_PCI)
diff --git a/include/config_fallbacks.h b/include/config_fallbacks.h
index 7aa5b02396..5a698a8349 100644
--- a/include/config_fallbacks.h
+++ b/include/config_fallbacks.h
@@ -43,7 +43,7 @@
#endif

/* Rather than repeat this expression each time, add a define for it */
-#if defined(CONFIG_CMD_IDE) || \
+#if defined(CONFIG_IDE) || \
defined(CONFIG_CMD_SATA) || \
defined(CONFIG_SCSI) || \
defined(CONFIG_CMD_USB) || \
diff --git a/include/configs/M5253DEMO.h b/include/configs/M5253DEMO.h
index e7c6f8b558..3efd7e59cf 100644
--- a/include/configs/M5253DEMO.h
+++ b/include/configs/M5253DEMO.h
@@ -38,7 +38,7 @@
* Command line configuration.
*/

-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
/* ATA */
# define CONFIG_IDE_RESET 1
# define CONFIG_IDE_PREINIT 1
diff --git a/include/configs/edminiv2.h b/include/configs/edminiv2.h
index ee3e729256..2ea39f0457 100644
--- a/include/configs/edminiv2.h
+++ b/include/configs/edminiv2.h
@@ -140,7 +140,7 @@
/*
* IDE
*/
-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#define __io
#define CONFIG_IDE_PREINIT
/* ED Mini V has an IDE-compatible SATA connector for port 1 */
diff --git a/include/configs/ib62x0.h b/include/configs/ib62x0.h
index 36a66bb463..0b92d7b2ca 100644
--- a/include/configs/ib62x0.h
+++ b/include/configs/ib62x0.h
@@ -87,14 +87,14 @@
/*
* SATA driver configuration
*/
-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#define __io
#define CONFIG_IDE_PREINIT
#define CONFIG_MVSATA_IDE_USE_PORT0
#define CONFIG_MVSATA_IDE_USE_PORT1
#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
#define CONFIG_SYS_ATA_IDE1_OFFSET MV_SATA_PORT1_OFFSET
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */

/*
* RTC driver configuration
diff --git a/include/configs/lsxl.h b/include/configs/lsxl.h
index d2c210119b..43e4a325b4 100644
--- a/include/configs/lsxl.h
+++ b/include/configs/lsxl.h
@@ -145,7 +145,7 @@
#undef CONFIG_RESET_PHY_R
#endif /* CONFIG_CMD_NET */

-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#undef CONFIG_IDE_LED
#undef CONFIG_SYS_IDE_MAXBUS
#define CONFIG_SYS_IDE_MAXBUS 1
diff --git a/include/configs/mpc5121ads.h b/include/configs/mpc5121ads.h
index 356a376c20..9413602394 100644
--- a/include/configs/mpc5121ads.h
+++ b/include/configs/mpc5121ads.h
@@ -429,10 +429,10 @@
"1m(u-boot);" \
"mpc5121.nand:-(data)"

-#if defined(CONFIG_CMD_IDE) || defined(CONFIG_CMD_EXT2) || defined(CONFIG_CMD_USB)
+#if defined(CONFIG_IDE) || defined(CONFIG_CMD_EXT2) || defined(CONFIG_CMD_USB)
#define CONFIG_SUPPORT_VFAT

-#endif /* defined(CONFIG_CMD_IDE) */
+#endif /* defined(CONFIG_IDE) */

/*
* Watchdog timeout = CONFIG_SYS_WATCHDOG_VALUE * 65536 / IPS clock.
diff --git a/include/configs/nsa310s.h b/include/configs/nsa310s.h
index b988d3d7f9..9b99b0e44f 100644
--- a/include/configs/nsa310s.h
+++ b/include/configs/nsa310s.h
@@ -79,12 +79,12 @@
#endif /* CONFIG_CMD_NET */

/* SATA driver configuration */
-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#define __io
#define CONFIG_IDE_PREINIT
#define CONFIG_MVSATA_IDE_USE_PORT0
#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */

/* RTC driver configuration */
#ifdef CONFIG_CMD_DATE
diff --git a/include/configs/qemu-x86.h b/include/configs/qemu-x86.h
index b751ad5e14..3509c2f659 100644
--- a/include/configs/qemu-x86.h
+++ b/include/configs/qemu-x86.h
@@ -25,9 +25,9 @@
* - AHCI controller is supported for QEMU '-M q35' target
*
* Default configuraion is to support the QEMU default x86 target
- * Undefine CONFIG_CMD_IDE to support q35 target
+ * Undefine CONFIG_IDE to support q35 target
*/
-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#define CONFIG_SYS_IDE_MAXBUS 2
#define CONFIG_SYS_IDE_MAXDEVICE 4
#define CONFIG_SYS_ATA_BASE_ADDR 0
diff --git a/include/configs/r7780mp.h b/include/configs/r7780mp.h
index 26c5f0feeb..bb79a9ffea 100644
--- a/include/configs/r7780mp.h
+++ b/include/configs/r7780mp.h
@@ -119,7 +119,7 @@
#endif

/* Compact flash Support */
-#if defined(CONFIG_CMD_IDE)
+#if defined(CONFIG_IDE)
#define CONFIG_IDE_RESET 1
#define CONFIG_SYS_PIO_MODE 1
#define CONFIG_SYS_IDE_MAXBUS 1 /* IDE bus */
@@ -130,6 +130,6 @@
#define CONFIG_SYS_ATA_REG_OFFSET 0x1000 /* reg offset */
#define CONFIG_SYS_ATA_ALT_OFFSET 0x800 /* alternate register offset */
#define CONFIG_IDE_SWAP_IO
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */

#endif /* __R7780RP_H */
diff --git a/include/configs/sheevaplug.h b/include/configs/sheevaplug.h
index a111057313..9d2c106d46 100644
--- a/include/configs/sheevaplug.h
+++ b/include/configs/sheevaplug.h
@@ -90,13 +90,13 @@
/*
* SATA driver configuration
*/
-#ifdef CONFIG_CMD_IDE
+#ifdef CONFIG_IDE
#define __io
#define CONFIG_IDE_PREINIT
#define CONFIG_MVSATA_IDE_USE_PORT0
#define CONFIG_MVSATA_IDE_USE_PORT1
#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
#define CONFIG_SYS_ATA_IDE1_OFFSET MV_SATA_PORT1_OFFSET
-#endif /* CONFIG_CMD_IDE */
+#endif /* CONFIG_IDE */

#endif /* _CONFIG_SHEEVAPLUG_H */
diff --git a/include/pcmcia.h b/include/pcmcia.h
index c8a730c4d0..aaaf6511a8 100644
--- a/include/pcmcia.h
+++ b/include/pcmcia.h
@@ -16,7 +16,7 @@
* or try to generate a useful default
*/
#if defined(CONFIG_CMD_PCMCIA) || \
- (defined(CONFIG_CMD_IDE) && \
+ (defined(CONFIG_IDE) && \
(defined(CONFIG_IDE_8xx_PCCARD) || defined(CONFIG_IDE_8xx_DIRECT) ) )

#if !defined(CONFIG_PCMCIA_SLOT_A) && !defined(CONFIG_PCMCIA_SLOT_B)
@@ -268,7 +268,7 @@ extern u_int *pcmcia_pgcrx[];
#define PCMCIA_PGCRX(slot) (*pcmcia_pgcrx[slot])
#endif

-#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
+#if defined(CONFIG_IDE) && defined(CONFIG_IDE_8xx_PCCARD)
extern int check_ide_device(int slot);
#endif

--
2.13.0.rc2.291.g57267f2277-goog