summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/core/Makefile2
-rw-r--r--drivers/core/device.c4
-rw-r--r--drivers/core/lists.c2
-rw-r--r--drivers/core/root.c6
-rw-r--r--drivers/gpio/mxc_gpio.c2
-rw-r--r--drivers/gpio/vybrid_gpio.c2
-rw-r--r--drivers/i2c/s3c24x0_i2c.c4
-rw-r--r--drivers/input/Makefile2
-rw-r--r--drivers/input/tegra-kbc.c2
-rw-r--r--drivers/mmc/exynos_dw_mmc.c2
-rw-r--r--drivers/mmc/s5p_sdhci.c2
-rw-r--r--drivers/mmc/tegra_mmc.c2
-rw-r--r--drivers/mmc/zynq_sdhci.c2
-rw-r--r--drivers/mtd/spi/sf_probe.c6
-rw-r--r--drivers/net/xilinx_emaclite.c2
-rw-r--r--drivers/net/zynq_gem.c2
-rw-r--r--drivers/power/exynos-tmu.c2
-rw-r--r--drivers/power/pmic/pmic_max77686.c4
-rw-r--r--drivers/serial/ns16550.c2
-rw-r--r--drivers/serial/serial-uclass.c4
-rw-r--r--drivers/serial/serial_omap.c2
-rw-r--r--drivers/serial/serial_pl01x.c2
-rw-r--r--drivers/serial/serial_tegra.c4
-rw-r--r--drivers/serial/serial_uniphier.c2
-rw-r--r--drivers/serial/serial_zynq.c2
-rw-r--r--drivers/sound/max98095.c2
-rw-r--r--drivers/sound/wm8994.c2
-rw-r--r--drivers/tpm/tpm_tis_i2c.c2
-rw-r--r--drivers/video/exynos_dp_lowlevel.c2
-rw-r--r--drivers/video/exynos_fb.c8
-rw-r--r--drivers/video/exynos_fimd.c4
-rw-r--r--drivers/video/exynos_mipi_dsi.c4
-rw-r--r--drivers/video/tegra.c2
33 files changed, 47 insertions, 47 deletions
diff --git a/drivers/core/Makefile b/drivers/core/Makefile
index 1dd25a3..11e0276 100644
--- a/drivers/core/Makefile
+++ b/drivers/core/Makefile
@@ -7,7 +7,7 @@
obj-y += device.o lists.o root.o uclass.o util.o
obj-$(CONFIG_DEVRES) += devres.o
ifndef CONFIG_SPL_BUILD
-obj-$(CONFIG_OF_CONTROL) += simple-bus.o
+obj-$(CONFIG_$(SPL_)OF_CONTROL) += simple-bus.o
endif
obj-$(CONFIG_$(SPL_)DM_DEVICE_REMOVE) += device-remove.o
obj-$(CONFIG_DM) += dump.o
diff --git a/drivers/core/device.c b/drivers/core/device.c
index 56b9081..e23a872 100644
--- a/drivers/core/device.c
+++ b/drivers/core/device.c
@@ -59,7 +59,7 @@ int device_bind(struct udevice *parent, const struct driver *drv,
dev->seq = -1;
dev->req_seq = -1;
- if (IS_ENABLED(CONFIG_OF_CONTROL) && IS_ENABLED(CONFIG_DM_SEQ_ALIAS)) {
+ if (CONFIG_IS_ENABLED(OF_CONTROL) && IS_ENABLED(CONFIG_DM_SEQ_ALIAS)) {
/*
* Some devices, such as a SPI bus, I2C bus and serial ports
* are numbered using aliases.
@@ -561,7 +561,7 @@ const char *dev_get_uclass_name(struct udevice *dev)
fdt_addr_t dev_get_addr(struct udevice *dev)
{
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
fdt_addr_t addr;
addr = fdtdec_get_addr(gd->fdt_blob, dev->of_offset, "reg");
diff --git a/drivers/core/lists.c b/drivers/core/lists.c
index 2e52500..a1c9478 100644
--- a/drivers/core/lists.c
+++ b/drivers/core/lists.c
@@ -99,7 +99,7 @@ int device_bind_driver_to_node(struct udevice *parent, const char *drv_name,
return 0;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
/**
* driver_check_compatible() - Check if a driver is compatible with this node
*
diff --git a/drivers/core/root.c b/drivers/core/root.c
index 12d0460..78ab00c 100644
--- a/drivers/core/root.c
+++ b/drivers/core/root.c
@@ -114,7 +114,7 @@ int dm_init(void)
ret = device_bind_by_name(NULL, false, &root_info, &DM_ROOT_NON_CONST);
if (ret)
return ret;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
DM_ROOT_NON_CONST->of_offset = 0;
#endif
ret = device_probe(DM_ROOT_NON_CONST);
@@ -145,7 +145,7 @@ int dm_scan_platdata(bool pre_reloc_only)
return ret;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int dm_scan_fdt_node(struct udevice *parent, const void *blob, int offset,
bool pre_reloc_only)
{
@@ -198,7 +198,7 @@ int dm_init_and_scan(bool pre_reloc_only)
return ret;
}
- if (OF_CONTROL) {
+ if (CONFIG_IS_ENABLED(OF_CONTROL)) {
ret = dm_scan_fdt(gd->fdt_blob, pre_reloc_only);
if (ret) {
debug("dm_scan_fdt() failed: %d\n", ret);
diff --git a/drivers/gpio/mxc_gpio.c b/drivers/gpio/mxc_gpio.c
index 57a650f..0c48320 100644
--- a/drivers/gpio/mxc_gpio.c
+++ b/drivers/gpio/mxc_gpio.c
@@ -336,7 +336,7 @@ U_BOOT_DRIVER(gpio_mxc) = {
.bind = mxc_gpio_bind,
};
-#ifndef CONFIG_OF_CONTROL
+#if !CONFIG_IS_ENABLED(OF_CONTROL)
static const struct mxc_gpio_plat mxc_plat[] = {
{ 0, (struct gpio_regs *)GPIO1_BASE_ADDR },
{ 1, (struct gpio_regs *)GPIO2_BASE_ADDR },
diff --git a/drivers/gpio/vybrid_gpio.c b/drivers/gpio/vybrid_gpio.c
index 6eaf0a9..4d25f9a 100644
--- a/drivers/gpio/vybrid_gpio.c
+++ b/drivers/gpio/vybrid_gpio.c
@@ -135,7 +135,7 @@ static int vybrid_gpio_bind(struct udevice *dev)
return 0;
}
-#ifndef CONFIG_OF_CONTROL
+#if !CONFIG_IS_ENABLED(OF_CONTROL)
static const struct vybrid_gpio_platdata vybrid_gpio[] = {
{0, GPIO0_BASE_ADDR, "GPIO0 "},
{1, GPIO1_BASE_ADDR, "GPIO1 "},
diff --git a/drivers/i2c/s3c24x0_i2c.c b/drivers/i2c/s3c24x0_i2c.c
index c11a6be..ae6f436 100644
--- a/drivers/i2c/s3c24x0_i2c.c
+++ b/drivers/i2c/s3c24x0_i2c.c
@@ -1002,7 +1002,7 @@ static int s3c24x0_i2c_write(struct i2c_adapter *adap, uchar chip, uint addr,
}
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
static void process_nodes(const void *blob, int node_list[], int count,
int is_highspeed)
{
@@ -1101,7 +1101,7 @@ int i2c_reset_port_fdt(const void *blob, int node)
return 0;
}
-#endif /* CONFIG_OF_CONTROL */
+#endif /* CONFIG_IS_ENABLED(OF_CONTROL) */
#ifdef CONFIG_EXYNOS5
static void exynos_i2c_init(struct i2c_adapter *adap, int speed, int slaveaddr)
diff --git a/drivers/input/Makefile b/drivers/input/Makefile
index 24fec9b..b1161c5 100644
--- a/drivers/input/Makefile
+++ b/drivers/input/Makefile
@@ -14,4 +14,4 @@ obj-y += keyboard.o pc_keyb.o
obj-$(CONFIG_PS2MULT) += ps2mult.o ps2ser.o
endif
obj-y += input.o
-obj-$(CONFIG_OF_CONTROL) += key_matrix.o
+obj-$(CONFIG_$(SPL_)OF_CONTROL) += key_matrix.o
diff --git a/drivers/input/tegra-kbc.c b/drivers/input/tegra-kbc.c
index 0ef94f7..c9c9fac 100644
--- a/drivers/input/tegra-kbc.c
+++ b/drivers/input/tegra-kbc.c
@@ -295,7 +295,7 @@ static int init_tegra_keyboard(struct stdio_dev *dev)
if (config.created)
return 0;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int node;
node = fdtdec_next_compatible(gd->fdt_blob, 0,
diff --git a/drivers/mmc/exynos_dw_mmc.c b/drivers/mmc/exynos_dw_mmc.c
index e083745..cde2ba7 100644
--- a/drivers/mmc/exynos_dw_mmc.c
+++ b/drivers/mmc/exynos_dw_mmc.c
@@ -158,7 +158,7 @@ int exynos_dwmci_add_port(int index, u32 regbase, int bus_width, u32 clksel)
return exynos_dwmci_core_init(host, index);
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
static struct dwmci_host dwmci_host[DWMMC_MAX_CH_NUM];
static int do_dwmci_init(struct dwmci_host *host)
diff --git a/drivers/mmc/s5p_sdhci.c b/drivers/mmc/s5p_sdhci.c
index 522eab9..4db51d6 100644
--- a/drivers/mmc/s5p_sdhci.c
+++ b/drivers/mmc/s5p_sdhci.c
@@ -96,7 +96,7 @@ int s5p_sdhci_init(u32 regbase, int index, int bus_width)
return s5p_sdhci_core_init(host);
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
struct sdhci_host sdhci_host[SDHCI_MAX_HOSTS];
static int do_sdhci_init(struct sdhci_host *host)
diff --git a/drivers/mmc/tegra_mmc.c b/drivers/mmc/tegra_mmc.c
index 6f8b4d0..1584865 100644
--- a/drivers/mmc/tegra_mmc.c
+++ b/drivers/mmc/tegra_mmc.c
@@ -21,7 +21,7 @@ DECLARE_GLOBAL_DATA_PTR;
struct mmc_host mmc_host[CONFIG_SYS_MMC_MAX_DEVICE];
-#ifndef CONFIG_OF_CONTROL
+#if !CONFIG_IS_ENABLED(OF_CONTROL)
#error "Please enable device tree support to use this driver"
#endif
diff --git a/drivers/mmc/zynq_sdhci.c b/drivers/mmc/zynq_sdhci.c
index 971acbb..c69f5d4 100644
--- a/drivers/mmc/zynq_sdhci.c
+++ b/drivers/mmc/zynq_sdhci.c
@@ -33,7 +33,7 @@ int zynq_sdhci_init(phys_addr_t regbase)
return 0;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int zynq_sdhci_of_init(const void *blob)
{
int offset = 0;
diff --git a/drivers/mtd/spi/sf_probe.c b/drivers/mtd/spi/sf_probe.c
index e0283dc..954376d 100644
--- a/drivers/mtd/spi/sf_probe.c
+++ b/drivers/mtd/spi/sf_probe.c
@@ -266,7 +266,7 @@ static int spi_flash_validate_params(struct spi_slave *spi, u8 *idcode,
return 0;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int spi_flash_decode_fdt(const void *blob, struct spi_flash *flash)
{
fdt_addr_t addr;
@@ -292,7 +292,7 @@ int spi_flash_decode_fdt(const void *blob, struct spi_flash *flash)
return 0;
}
-#endif /* CONFIG_OF_CONTROL */
+#endif /* CONFIG_IS_ENABLED(OF_CONTROL) */
/**
* spi_flash_probe_slave() - Probe for a SPI flash device on a bus
@@ -347,7 +347,7 @@ int spi_flash_probe_slave(struct spi_slave *spi, struct spi_flash *flash)
}
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
if (spi_flash_decode_fdt(gd->fdt_blob, flash)) {
debug("SF: FDT decode error\n");
ret = -EINVAL;
diff --git a/drivers/net/xilinx_emaclite.c b/drivers/net/xilinx_emaclite.c
index c9afa99..564205d 100644
--- a/drivers/net/xilinx_emaclite.c
+++ b/drivers/net/xilinx_emaclite.c
@@ -361,7 +361,7 @@ int xilinx_emaclite_initialize(bd_t *bis, unsigned long base_addr,
return 1;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int xilinx_emaclite_of_init(const void *blob)
{
int offset = 0;
diff --git a/drivers/net/zynq_gem.c b/drivers/net/zynq_gem.c
index b2006df..9175d2c 100644
--- a/drivers/net/zynq_gem.c
+++ b/drivers/net/zynq_gem.c
@@ -553,7 +553,7 @@ int zynq_gem_initialize(bd_t *bis, phys_addr_t base_addr,
return 1;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int zynq_gem_of_init(const void *blob)
{
int offset = 0;
diff --git a/drivers/power/exynos-tmu.c b/drivers/power/exynos-tmu.c
index 9a093a5..b9968c2 100644
--- a/drivers/power/exynos-tmu.c
+++ b/drivers/power/exynos-tmu.c
@@ -180,7 +180,7 @@ enum tmu_status_t tmu_monitor(int *temp)
*/
static int get_tmu_fdt_values(struct tmu_info *info, const void *blob)
{
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
fdt_addr_t addr;
int node;
int error = 0;
diff --git a/drivers/power/pmic/pmic_max77686.c b/drivers/power/pmic/pmic_max77686.c
index 1ad810a..93c8d2b 100644
--- a/drivers/power/pmic/pmic_max77686.c
+++ b/drivers/power/pmic/pmic_max77686.c
@@ -256,7 +256,7 @@ int pmic_init(unsigned char bus)
{
static const char name[] = "MAX77686_PMIC";
struct pmic *p = pmic_alloc();
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
const void *blob = gd->fdt_blob;
int node, parent, tmp;
#endif
@@ -266,7 +266,7 @@ int pmic_init(unsigned char bus)
return -ENOMEM;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
node = fdtdec_next_compatible(blob, 0, COMPAT_MAXIM_MAX77686_PMIC);
if (node < 0) {
debug("PMIC: No node for PMIC Chip in device tree\n");
diff --git a/drivers/serial/ns16550.c b/drivers/serial/ns16550.c
index c8a77e2..2b6d1e4 100644
--- a/drivers/serial/ns16550.c
+++ b/drivers/serial/ns16550.c
@@ -357,7 +357,7 @@ int ns16550_serial_probe(struct udevice *dev)
return 0;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int ns16550_serial_ofdata_to_platdata(struct udevice *dev)
{
struct ns16550_platdata *plat = dev->platdata;
diff --git a/drivers/serial/serial-uclass.c b/drivers/serial/serial-uclass.c
index 2a49697..55011cc 100644
--- a/drivers/serial/serial-uclass.c
+++ b/drivers/serial/serial-uclass.c
@@ -32,7 +32,7 @@ static void serial_find_console_or_panic(void)
struct udevice *dev;
int node;
- if (OF_CONTROL && gd->fdt_blob) {
+ if (CONFIG_IS_ENABLED(OF_CONTROL) && gd->fdt_blob) {
/* Check for a chosen console */
node = fdtdec_get_chosen_node(gd->fdt_blob, "stdout-path");
if (node < 0)
@@ -55,7 +55,7 @@ static void serial_find_console_or_panic(void)
}
}
}
- if (!SPL_BUILD || !OF_CONTROL || !gd->fdt_blob) {
+ if (!SPL_BUILD || !CONFIG_IS_ENABLED(OF_CONTROL) || !gd->fdt_blob) {
/*
* Try to use CONFIG_CONS_INDEX if available (it is numbered
* from 1!).
diff --git a/drivers/serial/serial_omap.c b/drivers/serial/serial_omap.c
index 325fe42..e8d544f 100644
--- a/drivers/serial/serial_omap.c
+++ b/drivers/serial/serial_omap.c
@@ -12,7 +12,7 @@
DECLARE_GLOBAL_DATA_PTR;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
static const struct udevice_id omap_serial_ids[] = {
{ .compatible = "ti,omap3-uart" },
{ .compatible = "ti,omap4-uart" },
diff --git a/drivers/serial/serial_pl01x.c b/drivers/serial/serial_pl01x.c
index ad503af..917b603 100644
--- a/drivers/serial/serial_pl01x.c
+++ b/drivers/serial/serial_pl01x.c
@@ -353,7 +353,7 @@ static const struct dm_serial_ops pl01x_serial_ops = {
.setbrg = pl01x_serial_setbrg,
};
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
static const struct udevice_id pl01x_serial_id[] ={
{.compatible = "arm,pl011", .data = TYPE_PL011},
{.compatible = "arm,pl010", .data = TYPE_PL010},
diff --git a/drivers/serial/serial_tegra.c b/drivers/serial/serial_tegra.c
index b9227f0..0c84f0b 100644
--- a/drivers/serial/serial_tegra.c
+++ b/drivers/serial/serial_tegra.c
@@ -9,7 +9,7 @@
#include <ns16550.h>
#include <serial.h>
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
static const struct udevice_id tegra_serial_ids[] = {
{ .compatible = "nvidia,tegra20-uart" },
{ }
@@ -42,7 +42,7 @@ U_BOOT_DEVICE(ns16550_serial) = {
U_BOOT_DRIVER(serial_ns16550) = {
.name = "serial_tegra20",
.id = UCLASS_SERIAL,
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
.of_match = tegra_serial_ids,
.ofdata_to_platdata = tegra_serial_ofdata_to_platdata,
.platdata_auto_alloc_size = sizeof(struct ns16550_platdata),
diff --git a/drivers/serial/serial_uniphier.c b/drivers/serial/serial_uniphier.c
index f210986..abf362a 100644
--- a/drivers/serial/serial_uniphier.c
+++ b/drivers/serial/serial_uniphier.c
@@ -113,7 +113,7 @@ static int uniphier_serial_remove(struct udevice *dev)
return 0;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
static const struct udevice_id uniphier_uart_of_match[] = {
{ .compatible = "socionext,uniphier-uart" },
{ /* sentinel */ }
diff --git a/drivers/serial/serial_zynq.c b/drivers/serial/serial_zynq.c
index 9278763..9d84290 100644
--- a/drivers/serial/serial_zynq.c
+++ b/drivers/serial/serial_zynq.c
@@ -175,7 +175,7 @@ DECLARE_PSSERIAL_FUNCTIONS(1);
static struct serial_device uart_zynq_serial1_device =
INIT_PSSERIAL_STRUCTURE(1, "ttyPS1");
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
__weak struct serial_device *default_serial_console(void)
{
const void *blob = gd->fdt_blob;
diff --git a/drivers/sound/max98095.c b/drivers/sound/max98095.c
index febf419..35829f8 100644
--- a/drivers/sound/max98095.c
+++ b/drivers/sound/max98095.c
@@ -520,7 +520,7 @@ static int get_max98095_codec_values(struct sound_codec_info *pcodec_info,
const void *blob)
{
int error = 0;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
enum fdt_compat_id compat;
int node;
int parent;
diff --git a/drivers/sound/wm8994.c b/drivers/sound/wm8994.c
index f8e9a6e..d378442 100644
--- a/drivers/sound/wm8994.c
+++ b/drivers/sound/wm8994.c
@@ -814,7 +814,7 @@ static int get_codec_values(struct sound_codec_info *pcodec_info,
const void *blob)
{
int error = 0;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
enum fdt_compat_id compat;
int node;
int parent;
diff --git a/drivers/tpm/tpm_tis_i2c.c b/drivers/tpm/tpm_tis_i2c.c
index ee4dfea..cc740e9 100644
--- a/drivers/tpm/tpm_tis_i2c.c
+++ b/drivers/tpm/tpm_tis_i2c.c
@@ -585,7 +585,7 @@ static struct tpm_vendor_specific tpm_tis_i2c = {
static enum i2c_chip_type tpm_vendor_chip_type(void)
{
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
const void *blob = gd->fdt_blob;
if (fdtdec_next_compatible(blob, 0, COMPAT_INFINEON_SLB9645_TPM) >= 0)
diff --git a/drivers/video/exynos_dp_lowlevel.c b/drivers/video/exynos_dp_lowlevel.c
index 05118f8..e9b461a 100644
--- a/drivers/video/exynos_dp_lowlevel.c
+++ b/drivers/video/exynos_dp_lowlevel.c
@@ -22,7 +22,7 @@ struct exynos_dp *dp_regs;
void exynos_dp_set_base_addr(void)
{
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
unsigned int node = fdtdec_next_compatible(gd->fdt_blob,
0, COMPAT_SAMSUNG_EXYNOS5_DP);
if (node <= 0)
diff --git a/drivers/video/exynos_fb.c b/drivers/video/exynos_fb.c
index 8f3b826..69edc3a 100644
--- a/drivers/video/exynos_fb.c
+++ b/drivers/video/exynos_fb.c
@@ -28,7 +28,7 @@ DECLARE_GLOBAL_DATA_PTR;
static unsigned int panel_width, panel_height;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
vidinfo_t panel_info = {
/*
* Insert a value here so that we don't end up in the BSS
@@ -126,7 +126,7 @@ static void lcd_panel_on(vidinfo_t *vid)
exynos_backlight_on(1);
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
node = fdtdec_next_compatible(gd->fdt_blob, 0,
COMPAT_SAMSUNG_EXYNOS_FIMD);
if (node <= 0) {
@@ -150,7 +150,7 @@ static void lcd_panel_on(vidinfo_t *vid)
exynos_mipi_dsi_init();
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int exynos_lcd_early_init(const void *blob)
{
unsigned int node;
@@ -295,7 +295,7 @@ void lcd_ctrl_init(void *lcdbase)
set_system_display_ctrl();
set_lcd_clk();
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
#ifdef CONFIG_EXYNOS_MIPI_DSIM
exynos_init_dsim_platform_data(&panel_info);
#endif
diff --git a/drivers/video/exynos_fimd.c b/drivers/video/exynos_fimd.c
index f67fa81..ac001a8 100644
--- a/drivers/video/exynos_fimd.c
+++ b/drivers/video/exynos_fimd.c
@@ -251,7 +251,7 @@ void exynos_fimd_window_off(unsigned int win_id)
writel(cfg, &fimd_ctrl->winshmap);
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
/*
* The reset value for FIMD SYSMMU register MMU_CTRL is 3
* on Exynos5420 and newer versions.
@@ -295,7 +295,7 @@ void exynos_fimd_lcd_init(vidinfo_t *vid)
{
unsigned int cfg = 0, rgb_mode;
unsigned int offset;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
unsigned int node;
node = fdtdec_next_compatible(gd->fdt_blob,
diff --git a/drivers/video/exynos_mipi_dsi.c b/drivers/video/exynos_mipi_dsi.c
index c68ebd6..b597acc 100644
--- a/drivers/video/exynos_mipi_dsi.c
+++ b/drivers/video/exynos_mipi_dsi.c
@@ -28,7 +28,7 @@
DECLARE_GLOBAL_DATA_PTR;
static struct exynos_platform_mipi_dsim *dsim_pd;
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
static struct mipi_dsim_config dsim_config_dt;
static struct exynos_platform_mipi_dsim dsim_platform_data_dt;
static struct mipi_dsim_lcd_device mipi_lcd_device_dt;
@@ -249,7 +249,7 @@ void exynos_set_dsim_platform_data(struct exynos_platform_mipi_dsim *pd)
dsim_pd = pd;
}
-#ifdef CONFIG_OF_CONTROL
+#if CONFIG_IS_ENABLED(OF_CONTROL)
int exynos_dsim_config_parse_dt(const void *blob)
{
int node;
diff --git a/drivers/video/tegra.c b/drivers/video/tegra.c
index 33c6103..8e81346 100644
--- a/drivers/video/tegra.c
+++ b/drivers/video/tegra.c
@@ -49,7 +49,7 @@ vidinfo_t panel_info = {
.vl_col = -1,
};
-#ifndef CONFIG_OF_CONTROL
+#if !CONFIG_IS_ENABLED(OF_CONTROL)
#error "You must enable CONFIG_OF_CONTROL to get Tegra LCD support"
#endif