aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/omap2/dss/overlay.c
diff options
context:
space:
mode:
authorArchit Taneja <archit@ti.com>2012-06-25 05:28:48 -0400
committerArchit Taneja <archit@ti.com>2012-06-29 06:57:59 -0400
commit6c6f510afb86e3c77c351dfa20cbb8ca834abad9 (patch)
tree72188f07c300e04f30d059bf502f651d2cbeb829 /drivers/video/omap2/dss/overlay.c
parentc47cdb3088581f9d744b03399e8b4e89a56a111b (diff)
OMAPDSS: OVERLAY: Clean up replication checking
Replication logic for an overlay depends on the color mode in which it is configured and the video port width of the manager it is connected to. video port width now held in dss_lcd_mgr_config in the manager's private data in APPLY. Use this instead of referring to the omap_dss_device connected to the manager. Replication is enabled in the case of TV manager, the video_port_width is set to a default value of 24 for TV manager. Make the replication checking an overlay function since it's more of an overlay characteristic than a display characteristic. Signed-off-by: Archit Taneja <archit@ti.com>
Diffstat (limited to 'drivers/video/omap2/dss/overlay.c')
-rw-r--r--drivers/video/omap2/dss/overlay.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/video/omap2/dss/overlay.c b/drivers/video/omap2/dss/overlay.c
index ec69325a118a..952c6fad9a81 100644
--- a/drivers/video/omap2/dss/overlay.c
+++ b/drivers/video/omap2/dss/overlay.c
@@ -687,3 +687,16 @@ int dss_ovl_check(struct omap_overlay *ovl, struct omap_overlay_info *info,
687 687
688 return 0; 688 return 0;
689} 689}
690
691/*
692 * Checks if replication logic should be used. Only use when overlay is in
693 * RGB12U or RGB16 mode, and video port width interface is 18bpp or 24bpp
694 */
695bool dss_ovl_use_replication(struct dss_lcd_mgr_config config,
696 enum omap_color_mode mode)
697{
698 if (mode != OMAP_DSS_COLOR_RGB12U && mode != OMAP_DSS_COLOR_RGB16)
699 return false;
700
701 return config.video_port_width > 16;
702}