diff options
author | Robert Marklund <robert.marklund@stericsson.com> | 2011-04-20 14:21:38 +0200 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@stericsson.com> | 2011-09-19 15:14:51 +0200 |
commit | 6b69e35de331fdee04db0eec587d01164f8b2f72 (patch) | |
tree | deddbf83304f1cc635b12b6a110efa5145b344bf /arch/arm/mach-ux500/board-mop500-mcde.c | |
parent | 4d005e831f693f35403063b283ccec1f2f7f076b (diff) |
video: mcde: Fix mcde GPIO and device creation
Fix so that the GPIO is defined in the right place.
Fix so only one device is created when both the u5500 and
u8500 is defined.
Signed-off-by: Robert Marklund <robert.marklund@stericsson.com>
Diffstat (limited to 'arch/arm/mach-ux500/board-mop500-mcde.c')
-rw-r--r-- | arch/arm/mach-ux500/board-mop500-mcde.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/arch/arm/mach-ux500/board-mop500-mcde.c b/arch/arm/mach-ux500/board-mop500-mcde.c index 97778a4b426..c44bc2f87f6 100644 --- a/arch/arm/mach-ux500/board-mop500-mcde.c +++ b/arch/arm/mach-ux500/board-mop500-mcde.c @@ -11,6 +11,7 @@ #include <linux/gpio.h> #include <linux/mfd/ab8500/denc.h> #include <linux/workqueue.h> +#include <asm/mach-types.h> #include <video/av8100.h> #include <video/mcde_display.h> #include <video/mcde_display-generic_dsi.h> @@ -23,8 +24,6 @@ #include "pins-db8500.h" #include "pins.h" #include "board-mop500.h" -#include "asm/mach-types.h" - #define DSI_UNIT_INTERVAL_0 0x9 #define DSI_UNIT_INTERVAL_1 0x9 @@ -595,12 +594,15 @@ static struct notifier_block framebuffer_nb = { int __init init_display_devices(void) { - int ret; + int ret = 0; #ifdef CONFIG_DISPLAY_GENERIC_DSI_PRIMARY_VSYNC struct i2c_adapter *i2c0; #endif + if (!(machine_is_u8500() || machine_is_snowball())) + return ret; + ret = fb_register_client(&framebuffer_nb); if (ret) pr_warning("Failed to register framebuffer notifier\n"); @@ -613,7 +615,7 @@ int __init init_display_devices(void) if (machine_is_hrefv60()) mop500_generic_display0_pdata.reset_gpio = HREFV60_DISP1_RST_GPIO; else - mop500_generic_display0_pdata.reset_gpio = GPIO_MCDE_RESET; + mop500_generic_display0_pdata.reset_gpio = MOP500_DISP1_RST_GPIO; #ifdef CONFIG_DISPLAY_GENERIC_DSI_PRIMARY_VSYNC i2c0 = i2c_get_adapter(0); @@ -643,7 +645,7 @@ int __init init_display_devices(void) if (machine_is_hrefv60()) generic_subdisplay_pdata.reset_gpio = HREFV60_DISP2_RST_GPIO; else - generic_subdisplay_pdata.reset_gpio = EGPIO_PIN_14; + generic_subdisplay_pdata.reset_gpio = MOP500_DISP2_RST_GPIO; ret = mcde_display_device_register(&generic_subdisplay); if (ret) pr_warning("Failed to register generic sub display device\n"); |