summaryrefslogtreecommitdiffstats
path: root/hwc/hwc.c
diff options
context:
space:
mode:
authorSunita Nadampalli <sunitan@ti.com>2012-03-05 10:29:25 -0600
committerDaniel Levin <dendy@ti.com>2012-11-28 21:16:23 +0200
commite5e11dd7af4cdc8d07e503d05d65dc9d1a004724 (patch)
tree2853aa92abd1d20e47afb3a2af61431f3ed80031 /hwc/hwc.c
parenta5b887ee11524666c719a9a25844841cfc4b82a6 (diff)
downloadhardware_ti_omap4-e5e11dd7af4cdc8d07e503d05d65dc9d1a004724.zip
hardware_ti_omap4-e5e11dd7af4cdc8d07e503d05d65dc9d1a004724.tar.gz
hardware_ti_omap4-e5e11dd7af4cdc8d07e503d05d65dc9d1a004724.tar.bz2
hwc: added interlaced modes to HDMI best mode selection logic
Modified HWC hdmi best mode selection policy to consider Interlaced modes as well. DRT#OMAPS00262232 - HWC hal doesnt have support for interlaced timings for HDMI Rebased from p-ics-mr1: a11e07b hwc: Added Interlaced modes to the HDMI best mode selection logic Change-Id: Ie7bbe55c5694c53cc669c39ec125a72f723c3920 Signed-off-by: Sunita Nadampalli <sunitan@ti.com>
Diffstat (limited to 'hwc/hwc.c')
-rw-r--r--hwc/hwc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/hwc/hwc.c b/hwc/hwc.c
index dce3946..ef67d67 100644
--- a/hwc/hwc.c
+++ b/hwc/hwc.c
@@ -972,6 +972,9 @@ static int omap4_hwc_set_best_hdmi_mode(omap4_hwc_device_t *hwc_dev, __u32 xres,
__u32 ext_width = d.dis.width_in_mm;
__u32 ext_height = d.dis.height_in_mm;
+ if (d.modedb[i].vmode & FB_VMODE_INTERLACED)
+ mode_yres /= 2;
+
if (d.modedb[i].flag & FB_FLAG_RATIO_4_3) {
ext_width = 4;
ext_height = 3;
@@ -988,7 +991,7 @@ static int omap4_hwc_set_best_hdmi_mode(omap4_hwc_device_t *hwc_dev, __u32 xres,
/* we need to ensure that even TILER2D buffers can be scaled */
if (!d.modedb[i].pixclock ||
- d.modedb[i].vmode ||
+ (d.modedb[i].vmode & ~FB_VMODE_INTERLACED) ||
!omap4_hwc_can_scale(xres, yres, ext_fb_xres, ext_fb_yres,
1, &d.dis, &limits,
1000000000 / d.modedb[i].pixclock))
@@ -1032,7 +1035,6 @@ static int omap4_hwc_set_best_hdmi_mode(omap4_hwc_device_t *hwc_dev, __u32 xres,
get_max_dimensions(xres, yres, xpy, d.dis.timings.x_res, d.dis.timings.y_res,
ext_width, ext_height, &ext_fb_xres, &ext_fb_yres);
if (!d.dis.timings.pixel_clock ||
- d.dis.mgr.interlaced ||
!omap4_hwc_can_scale(xres, yres, ext_fb_xres, ext_fb_yres,
1, &d.dis, &limits,
d.dis.timings.pixel_clock)) {