diff options
| -rw-r--r-- | arch/arm/mach-ux500/board-mop500-mcde.c | 13 | ||||
| -rw-r--r-- | arch/arm/mach-ux500/board-u5500-mcde.c | 16 |
2 files changed, 19 insertions, 10 deletions
diff --git a/arch/arm/mach-ux500/board-mop500-mcde.c b/arch/arm/mach-ux500/board-mop500-mcde.c index d9b36fcdb81..bf4045f3965 100644 --- a/arch/arm/mach-ux500/board-mop500-mcde.c +++ b/arch/arm/mach-ux500/board-mop500-mcde.c @@ -43,7 +43,6 @@ static struct delayed_work work_dispreg_hdmi; #endif #define MCDE_NR_OF_DISPLAYS 3 -static struct mcde_display_device *displays[MCDE_NR_OF_DISPLAYS] = { NULL }; static int display_initialized_during_boot; static int __init startup_graphics_setup(char *str) @@ -419,7 +418,6 @@ static void delayed_work_dispreg_hdmi(struct work_struct *ptr) { if (mcde_display_device_register(&av8100_hdmi)) pr_warning("Failed to register av8100_hdmi\n"); - displays[TERTIARY_DISPLAY_ID] = &av8100_hdmi; } #endif /* CONFIG_DISPLAY_AV8100_TERTIARY */ @@ -494,16 +492,20 @@ static int display_postregistered_callback(struct notifier_block *nb, ddev->default_pixel_format, rotate); - if (IS_ERR(fbi)) + if (IS_ERR(fbi)) { dev_warn(&ddev->dev, "Failed to create fb for display %s\n", ddev->name); - else + goto display_postregistered_callback_err; + } else dev_info(&ddev->dev, "Framebuffer created (%s)\n", ddev->name); } return 0; + +display_postregistered_callback_err: + return -1; } static struct notifier_block display_nb = { @@ -648,7 +650,6 @@ int __init init_display_devices(void) ret = mcde_display_device_register(&generic_display0); if (ret) pr_warning("Failed to register generic display device 0\n"); - displays[0] = &generic_display0; #endif #ifdef CONFIG_DISPLAY_GENERIC_DSI_SECONDARY @@ -659,7 +660,6 @@ int __init init_display_devices(void) ret = mcde_display_device_register(&generic_subdisplay); if (ret) pr_warning("Failed to register generic sub display device\n"); - displays[1] = &generic_subdisplay; #endif #ifdef CONFIG_DISPLAY_AV8100_TERTIARY @@ -673,7 +673,6 @@ int __init init_display_devices(void) ret = mcde_display_device_register(&tvout_ab8500_display); if (ret) pr_warning("Failed to register ab8500 tvout device\n"); - displays[2] = &tvout_ab8500_display; #endif return ret; diff --git a/arch/arm/mach-ux500/board-u5500-mcde.c b/arch/arm/mach-ux500/board-u5500-mcde.c index eba695e5ed5..d1a49297965 100644 --- a/arch/arm/mach-ux500/board-u5500-mcde.c +++ b/arch/arm/mach-ux500/board-u5500-mcde.c @@ -163,7 +163,7 @@ static struct mcde_display_hdmi_platform_data av8100_hdmi_pdata = { {0xffda, 0xffb6, 0x70}, {0x70, 0xffa2, 0xffee}, }, - .offset = {0x80, 0x10, 0x80}, + .offset = {0x10, 0x80, 0x80}, } }; @@ -234,11 +234,17 @@ static int display_postregistered_callback(struct notifier_block *nb, virtual_width = width; virtual_height = height * 2; + #ifdef CONFIG_DISPLAY_GENERIC_DSI_PRIMARY_AUTO_SYNC if (ddev->id == PRIMARY_DISPLAY_ID) virtual_height = height; #endif +#ifdef CONFIG_DISPLAY_AV8100_TRIPPLE_BUFFER + if (ddev->id == TERTIARY_DISPLAY_ID) + virtual_height = height * 3; +#endif + if (ddev->id == TERTIARY_DISPLAY_ID) { #ifdef CONFIG_MCDE_DISPLAY_HDMI_FB_AUTO_CREATE hdmi_fb_onoff(ddev, 1, 0, 0); @@ -251,16 +257,20 @@ static int display_postregistered_callback(struct notifier_block *nb, ddev->default_pixel_format, rotate); - if (IS_ERR(fbi)) + if (IS_ERR(fbi)) { dev_warn(&ddev->dev, "Failed to create fb for display %s\n", ddev->name); - else + goto display_postregistered_callback_err; + } else dev_info(&ddev->dev, "Framebuffer created (%s)\n", ddev->name); } return 0; + +display_postregistered_callback_err: + return -1; } static struct notifier_block display_nb = { |
