summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Langlais <philippe.langlais@stericsson.com>2011-10-19 14:21:06 +0200
committerPhilippe Langlais <philippe.langlais@stericsson.com>2012-05-22 11:03:46 +0200
commit71bf721523e1fd0062feebf4928e07d313ccb0e3 (patch)
tree76e1d983eee4e00ef03afe175e4991280a1efad1
parent48349909caa096be381320a0e9dd29c3a0b01329 (diff)
video: mcde: Fix Kconfig to match the ux500 update
Change the dependencies of MCDE Kconfigs to match the mach-ux500 update. Change name of the regulators used by the mcde driver to match the mach-ux500 update. Added the EGPIO used by mcde. Signed-off-by: Robert Marklund <robert.marklund@stericsson.com>
-rw-r--r--arch/arm/mach-ux500/Kconfig-arch148
-rw-r--r--arch/arm/mach-ux500/board-mop500-mcde.c27
-rw-r--r--arch/arm/mach-ux500/board-u5500-mcde.c12
-rw-r--r--drivers/video/mcde/display-generic_dsi.c2
4 files changed, 169 insertions, 20 deletions
diff --git a/arch/arm/mach-ux500/Kconfig-arch b/arch/arm/mach-ux500/Kconfig-arch
new file mode 100644
index 00000000000..596399284ad
--- /dev/null
+++ b/arch/arm/mach-ux500/Kconfig-arch
@@ -0,0 +1,148 @@
+config U8500_SECURE
+ bool "Support for running in Secure mode"
+ default n
+ help
+ Build the kernel to run in Secure mode.
+
+#Configuration for MCDE setup
+
+if FB_MCDE
+
+menu "Display selection"
+
+config DISPLAY_GENERIC_PRIMARY
+ bool "Generic primary display support"
+ depends on (MACH_U8500 || MACH_U5500)
+ default y
+
+choice
+ prompt "Display port type"
+ depends on DISPLAY_GENERIC_PRIMARY
+ default DISPLAY_GENERIC_DSI_PRIMARY
+ help
+ Select the kind of display port used for the primary display
+
+config DISPLAY_GENERIC_DSI_PRIMARY
+ bool "DSI display"
+ select MCDE_DISPLAY_GENERIC_DSI
+ help
+ Say yes here when using a DSI display
+
+config MCDE_DISPLAY_DPI_PRIMARY
+ bool "DPI display"
+ select MCDE_DISPLAY_DPI
+ depends on MACH_U8500
+ help
+ Say yes here when using a DPI display
+
+endchoice
+
+choice
+ prompt "Color depth"
+ depends on DISPLAY_GENERIC_PRIMARY
+ default MCDE_DISPLAY_PRIMARY_16BPP
+ help
+ Select color depth for primary display
+
+config MCDE_DISPLAY_PRIMARY_16BPP
+ bool "16 bpp"
+ help
+ 16 bpp color depth
+
+config MCDE_DISPLAY_PRIMARY_32BPP
+ bool "32 bpp"
+ help
+ 32 bpp color depth
+
+endchoice
+
+choice DISPLAY_GENERIC_DSI_PRIMARY_ROTATION
+ prompt "Enable main display rotation"
+ depends on DISPLAY_GENERIC_DSI_PRIMARY
+ default DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_90
+ help
+ Set rotation of main display
+
+config DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_0
+ bool "0 degrees"
+config DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_90
+ bool "90 degrees"
+config DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_180
+ bool "180 degrees"
+config DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_270
+ bool "270 degrees"
+endchoice
+
+config DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_ANGLE
+ int
+ depends on DISPLAY_GENERIC_DSI_PRIMARY
+ default "0" if DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_0
+ default "90" if DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_90
+ default "180" if DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_180
+ default "270" if DISPLAY_GENERIC_DSI_PRIMARY_ROTATION_270
+
+config DISPLAY_SONY_SY35560_DSI_PRIMARY
+ bool "Sony SY35560 primary display support"
+ depends on MACH_U8500_PDP
+ select MCDE_DISPLAY_SONY_SY35560_DSI
+ default y
+ help
+ Say yes here if main display exists
+
+config DISPLAY_GENERIC_DSI_PRIMARY_VSYNC
+ bool "Enable v-sync for primary display"
+ depends on DISPLAY_GENERIC_DSI_PRIMARY || DISPLAY_SONY_SY35560_DSI_PRIMARY
+ default n
+ help
+ Say yes to enable v-sync for primary display
+
+config DISPLAY_GENERIC_DSI_PRIMARY_AUTO_SYNC
+ bool "Enable auto sync for primary display"
+ depends on DISPLAY_GENERIC_DSI_PRIMARY
+ default n
+ help
+ Say yes to enable auto sync for primary display
+
+config SONY_SY35560_ENABLE_ESD_CHECK
+ bool "Enable esd status check for primary display"
+ depends on DISPLAY_SONY_SY35560_DSI_PRIMARY
+ default n
+ help
+ Say yes to enable esd status check for primary display
+
+config DISPLAY_GENERIC_DSI_SECONDARY
+ bool "Sub display support"
+ depends on MACH_U8500
+ select MCDE_DISPLAY_GENERIC_DSI
+ help
+ Say yes here if sub display exists
+
+config DISPLAY_GENERIC_DSI_SECONDARY_VSYNC
+ bool "Enable v-sync for secondary display"
+ depends on DISPLAY_GENERIC_DSI_SECONDARY
+ help
+ Say yes to enable v-sync for secondary display
+
+config DISPLAY_GENERIC_DSI_SECONDARY_AUTO_SYNC
+ bool "Enable auto sync for secondary display"
+ depends on DISPLAY_GENERIC_DSI_SECONDARY
+ help
+ Say yes to enable auto sync for secondary display
+
+config DISPLAY_AB8500_TERTIARY
+ bool "AB8500 TVout display support"
+ depends on MACH_U8500 && !AV8100_SDTV
+ select MCDE_DISPLAY_AB8500_DENC
+ help
+ Say yes here if tv out support
+
+config DISPLAY_AV8100_TERTIARY
+ bool "AV8100 HDMI/CVBS display support"
+ depends on MACH_U8500
+ select MCDE_DISPLAY_AV8100
+ help
+ Say yes here if HDMI output support
+
+endmenu
+
+endif
diff --git a/arch/arm/mach-ux500/board-mop500-mcde.c b/arch/arm/mach-ux500/board-mop500-mcde.c
index 59bc22c01d1..97778a4b426 100644
--- a/arch/arm/mach-ux500/board-mop500-mcde.c
+++ b/arch/arm/mach-ux500/board-mop500-mcde.c
@@ -23,6 +23,7 @@
#include "pins-db8500.h"
#include "pins.h"
#include "board-mop500.h"
+#include "asm/mach-types.h"
#define DSI_UNIT_INTERVAL_0 0x9
@@ -91,16 +92,16 @@ static struct mcde_port port0 = {
},
};
-struct mcde_display_generic_platform_data generic_display0_pdata = {
+struct mcde_display_generic_platform_data mop500_generic_display0_pdata = {
.reset_delay = 1,
#ifdef CONFIG_REGULATOR
- .regulator_id = "v-display",
+ .regulator_id = "vaux12v5",
.min_supply_voltage = 2500000, /* 2.5V */
.max_supply_voltage = 2700000 /* 2.7V */
#endif
};
-struct mcde_display_device generic_display0 = {
+struct mcde_display_device mop500_generic_display0 = {
.name = "mcde_disp_generic",
.id = PRIMARY_DISPLAY_ID,
.port = &port0,
@@ -118,7 +119,7 @@ struct mcde_display_device generic_display0 = {
.rotbuf1 = U8500_ESRAM_BASE + 0x20000 * 4,
.rotbuf2 = U8500_ESRAM_BASE + 0x20000 * 4 + 0x10000,
.dev = {
- .platform_data = &generic_display0_pdata,
+ .platform_data = &mop500_generic_display0_pdata,
},
};
#endif /* CONFIG_DISPLAY_GENERIC_DSI_PRIMARY */
@@ -195,7 +196,7 @@ static struct mcde_port port0 = {
},
};
-struct mcde_display_dpi_platform_data generic_display0_pdata = {0};
+struct mcde_display_dpi_platform_data mop500_generic_display0_pdata = {0};
static struct ux500_pins *dpi_pins;
static int dpi_display_platform_enable(struct mcde_display_device *ddev)
@@ -230,7 +231,7 @@ static int dpi_display_platform_disable(struct mcde_display_device *ddev)
}
-struct mcde_display_device generic_display0 = {
+struct mcde_display_device mop500_generic_display0 = {
.name = "mcde_display_dpi",
.id = 0,
.port = &port0,
@@ -245,7 +246,7 @@ struct mcde_display_device generic_display0 = {
.native_y_res = 480,
/* .synchronized_update: Don't care: port is set to update_auto_trig */
.dev = {
- .platform_data = &generic_display0_pdata,
+ .platform_data = &mop500_generic_display0_pdata,
},
.platform_enable = dpi_display_platform_enable,
.platform_disable = dpi_display_platform_disable,
@@ -610,9 +611,9 @@ int __init init_display_devices(void)
#ifdef CONFIG_DISPLAY_GENERIC_PRIMARY
if (machine_is_hrefv60())
- generic_display0_pdata.reset_gpio = HREFV60_DISP1_RST_GPIO;
+ mop500_generic_display0_pdata.reset_gpio = HREFV60_DISP1_RST_GPIO;
else
- generic_display0_pdata.reset_gpio = EGPIO_PIN_15;
+ mop500_generic_display0_pdata.reset_gpio = GPIO_MCDE_RESET;
#ifdef CONFIG_DISPLAY_GENERIC_DSI_PRIMARY_VSYNC
i2c0 = i2c_get_adapter(0);
@@ -626,16 +627,16 @@ int __init init_display_devices(void)
i2c_put_adapter(i2c0);
/* ret == 0 => U8500 UIB connected */
- generic_display0.synchronized_update = (ret == 0);
+ mop500_generic_display0.synchronized_update = (ret == 0);
}
#endif
if (display_initialized_during_boot)
- generic_display0.power_mode = MCDE_DISPLAY_PM_STANDBY;
- ret = mcde_display_device_register(&generic_display0);
+ mop500_generic_display0.power_mode = MCDE_DISPLAY_PM_STANDBY;
+ ret = mcde_display_device_register(&mop500_generic_display0);
if (ret)
pr_warning("Failed to register generic display device 0\n");
- displays[0] = &generic_display0;
+ displays[0] = &mop500_generic_display0;
#endif
#ifdef CONFIG_DISPLAY_GENERIC_DSI_SECONDARY
diff --git a/arch/arm/mach-ux500/board-u5500-mcde.c b/arch/arm/mach-ux500/board-u5500-mcde.c
index 38811d5db1f..8d755b2ec80 100644
--- a/arch/arm/mach-ux500/board-u5500-mcde.c
+++ b/arch/arm/mach-ux500/board-u5500-mcde.c
@@ -67,7 +67,7 @@ static struct mcde_port port0 = {
},
};
-struct mcde_display_generic_platform_data generic_display0_pdata = {
+struct mcde_display_generic_platform_data u5500_generic_display0_pdata = {
.reset_gpio = 226,
.reset_delay = 10,
.sleep_out_delay = 140,
@@ -78,7 +78,7 @@ struct mcde_display_generic_platform_data generic_display0_pdata = {
#endif
};
-struct mcde_display_device generic_display0 = {
+struct mcde_display_device u5500_generic_display0 = {
.name = "mcde_disp_generic",
.id = PRIMARY_DISPLAY_ID,
.port = &port0,
@@ -96,7 +96,7 @@ struct mcde_display_device generic_display0 = {
.rotbuf1 = U5500_ESRAM_BASE,
.rotbuf2 = U5500_ESRAM_BASE + 0x10000,
.dev = {
- .platform_data = &generic_display0_pdata,
+ .platform_data = &u5500_generic_display0_pdata,
},
};
#endif /* CONFIG_DISPLAY_GENERIC_DSI_PRIMARY */
@@ -265,11 +265,11 @@ int __init init_display_devices_u5500(void)
#ifdef CONFIG_DISPLAY_GENERIC_PRIMARY
if (display_initialized_during_boot)
- generic_display0.power_mode = MCDE_DISPLAY_PM_STANDBY;
- ret = mcde_display_device_register(&generic_display0);
+ u5500_generic_display0.power_mode = MCDE_DISPLAY_PM_STANDBY;
+ ret = mcde_display_device_register(&u5500_generic_display0);
if (ret)
pr_warning("Failed to register generic display device 0\n");
- displays[0] = &generic_display0;
+ displays[0] = &u5500_generic_display0;
#endif
return ret;
}
diff --git a/drivers/video/mcde/display-generic_dsi.c b/drivers/video/mcde/display-generic_dsi.c
index 9bb5babda5f..452da92f64a 100644
--- a/drivers/video/mcde/display-generic_dsi.c
+++ b/drivers/video/mcde/display-generic_dsi.c
@@ -164,7 +164,7 @@ static int __devinit generic_probe(struct mcde_display_device *dev)
!pdata->reset_high);
}
if (pdata->regulator_id) {
- pdata->regulator = regulator_get(NULL,
+ pdata->regulator = regulator_get(&dev->dev,
pdata->regulator_id);
if (IS_ERR(pdata->regulator)) {
ret = PTR_ERR(pdata->regulator);