summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Ziswiler <marcel.ziswiler@toradex.com>2013-11-29 09:02:08 +0100
committerMarcel Ziswiler <marcel.ziswiler@toradex.com>2013-11-29 09:02:08 +0100
commit7d161df98671d3816875bfeccab527e3d8ab5dda (patch)
tree6b6eb7651de87cc10c183f1af5fbc7a740eb3596
parentf7931050d576ffa31a94300e6ce1c7e3e04c2288 (diff)
colibri_vf: fix ifdefs
Various ifdefs still use CONFIG_MACH_COLIBRI_VF50. Migrate them to using the hidden CONFIG_COLIBRI_VF define active for both Colibri VF50 as well as Colibri VF61.
-rw-r--r--arch/arm/mach-mvf/clock.c4
-rw-r--r--arch/arm/mach-mvf/mvf_fec.c2
-rw-r--r--arch/arm/plat-mxc/include/mach/iomux-mvf.h3
-rwxr-xr-xdrivers/net/fec.c12
-rw-r--r--drivers/video/mvf_dcu.c10
5 files changed, 16 insertions, 15 deletions
diff --git a/arch/arm/mach-mvf/clock.c b/arch/arm/mach-mvf/clock.c
index 3b514d61002b..8ccfce7678a5 100644
--- a/arch/arm/mach-mvf/clock.c
+++ b/arch/arm/mach-mvf/clock.c
@@ -1973,7 +1973,7 @@ int __init mvf_clocks_init(unsigned long ckil, unsigned long osc,
clk_set_parent(&dcu0_clk, &pll1_pfd2_452M);
//480 MHz
// clk_set_parent(&dcu0_clk, &pll3_usb_otg_main_clk);
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
clk_set_rate(&dcu0_clk, 113000000);
#else
clk_set_rate(&dcu0_clk, 452000000);
@@ -1982,7 +1982,7 @@ int __init mvf_clocks_init(unsigned long ckil, unsigned long osc,
clk_set_parent(&sai2_clk, &audio_external_clk);
clk_set_rate(&sai2_clk, 24576000);
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
clk_set_parent(&qspi0_clk, &pll1_pfd4_528M);
clk_set_rate(&qspi0_clk, 66000000);
#endif
diff --git a/arch/arm/mach-mvf/mvf_fec.c b/arch/arm/mach-mvf/mvf_fec.c
index 437ba538d583..55ba44bf73f0 100644
--- a/arch/arm/mach-mvf/mvf_fec.c
+++ b/arch/arm/mach-mvf/mvf_fec.c
@@ -52,7 +52,7 @@ void __init mvf_init_fec(struct fec_platform_data fec_data)
if (!is_valid_ether_addr(fec_data.mac))
memcpy(fec_data.mac, default_mac, ETH_ALEN);
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
mvf_add_fec(0, &fec_data);
#endif
#ifdef CONFIG_FEC1
diff --git a/arch/arm/plat-mxc/include/mach/iomux-mvf.h b/arch/arm/plat-mxc/include/mach/iomux-mvf.h
index cfbc24b8fa8e..b9ba094fbd7a 100644
--- a/arch/arm/plat-mxc/include/mach/iomux-mvf.h
+++ b/arch/arm/plat-mxc/include/mach/iomux-mvf.h
@@ -64,7 +64,7 @@ typedef enum iomux_config {
#define MVF600_HIGH_DRV PAD_CTL_DSE_150ohm
-#if defined(CONFIG_MACH_COLIBRI_VF50)
+#if defined(CONFIG_COLIBRI_VF)
#define MVF600_DCU_PAD_CTRL (PAD_CTL_DSE_75ohm | PAD_CTL_OBE_ENABLE)
#else
#define MVF600_DCU_PAD_CTRL (MVF600_HIGH_DRV | PAD_CTL_OBE_ENABLE)
@@ -73,6 +73,7 @@ typedef enum iomux_config {
#define MVF600_UART_PAD_CTRL (PAD_CTL_PUS_100K_UP | PAD_CTL_SPEED_MED | \
PAD_CTL_DSE_25ohm)
+//why PKE?
#define MVF600_GPIO_GENERAL_CTRL (PAD_CTL_PKE | PAD_CTL_PUE | PAD_CTL_SPEED_MED | PAD_CTL_PUS_47K_UP | \
PAD_CTL_DSE_25ohm)
diff --git a/drivers/net/fec.c b/drivers/net/fec.c
index e8a22fff507b..8a2c60f29898 100755
--- a/drivers/net/fec.c
+++ b/drivers/net/fec.c
@@ -691,11 +691,11 @@ static void __inline__ fec_get_mac(struct net_device *ndev)
memcpy(ndev->dev_addr, iap, ETH_ALEN);
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
/* Adjust MAC if using macaddr */
if (iap == macaddr)
ndev->dev_addr[ETH_ALEN-1] = macaddr[ETH_ALEN-1] + fep->pdev->id;
-#endif /* !CONFIG_MACH_COLIBRI_VF50 */
+#endif /* !CONFIG_COLIBRI_VF */
}
/* ------------------------------------------------------------------------- */
@@ -878,7 +878,7 @@ static int fec_enet_mii_init(struct platform_device *pdev)
platform_get_device_id(fep->pdev);
int err = -ENXIO, i;
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
/*
* The dual fec interfaces are not equivalent with enet-mac.
* Here are the differences:
@@ -900,7 +900,7 @@ static int fec_enet_mii_init(struct platform_device *pdev)
fep->mii_bus = fec0_mii_bus;
return 0;
}
-#endif /* !CONFIG_MACH_COLIBRI_VF50 */
+#endif /* !CONFIG_COLIBRI_VF */
fep->mii_timeout = 0;
@@ -944,11 +944,11 @@ static int fec_enet_mii_init(struct platform_device *pdev)
if (mdiobus_register(fep->mii_bus))
goto err_out_free_mdio_irq;
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
/* save fec0 mii_bus */
if (id_entry->driver_data & FEC_QUIRK_ENET_MAC)
fec0_mii_bus = fep->mii_bus;
-#endif /* !CONFIG_MACH_COLIBRI_VF50 */
+#endif /* !CONFIG_COLIBRI_VF */
return 0;
diff --git a/drivers/video/mvf_dcu.c b/drivers/video/mvf_dcu.c
index 7bd73a75ce0f..6a84d02f5203 100644
--- a/drivers/video/mvf_dcu.c
+++ b/drivers/video/mvf_dcu.c
@@ -38,7 +38,7 @@
#define DRIVER_NAME "mvf-dcu"
static struct fb_videomode __devinitdata mvf_dcu_default_mode = {
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
.xres = 480,
.yres = 272,
.left_margin = 2,
@@ -49,7 +49,7 @@ static struct fb_videomode __devinitdata mvf_dcu_default_mode = {
.vsync_len = 2,
.sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,
.vmode = FB_VMODE_NONINTERLACED,
-#else /* !CONFIG_MACH_COLIBRI_VF50 */
+#else /* !CONFIG_COLIBRI_VF */
// .refresh = 60,
.xres = 640,
.yres = 480,
@@ -64,7 +64,7 @@ static struct fb_videomode __devinitdata mvf_dcu_default_mode = {
.sync = 0,
.vmode = FB_VMODE_NONINTERLACED,
// .flag = 0,
-#endif /* !CONFIG_MACH_COLIBRI_VF50 */
+#endif /* !CONFIG_COLIBRI_VF */
};
static struct fb_videomode __devinitdata mvf_dcu_mode_db[] = {
@@ -530,7 +530,7 @@ static void update_lcdc(struct fb_info *info)
writel(DCU_MODE_BLEND_ITER(3) | DCU_MODE_RASTER_EN(1),
dcu->base + DCU_DCU_MODE);
-#if defined(CONFIG_MACH_COLIBRI_VF50)
+#if defined(CONFIG_COLIBRI_VF)
//1024x768: 452/7 = 64.6 MHz
// writel(6, dcu->base + DCU_DIV_RATIO);
//1024x600: 480/10 = 48 MHz
@@ -1146,7 +1146,7 @@ static int __devinit mvf_dcu_probe(struct platform_device *pdev)
goto failed_get_resource;
}
-#if !defined(CONFIG_MACH_COLIBRI_VF50)
+#if !defined(CONFIG_COLIBRI_VF)
gpio_request_one(DCU_LCD_ENABLE_PIN, GPIOF_OUT_INIT_LOW, "DCU");
msleep(2);
gpio_set_value(DCU_LCD_ENABLE_PIN, 1);