diff options
author | Tomi Valkeinen <tomi.valkeinen@nokia.com> | 2010-01-11 17:12:31 +0300 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@nokia.com> | 2010-02-24 15:31:28 +0300 |
commit | 446f7bff703f5f82560afde90fb22b7a1d366bbc (patch) | |
tree | 6ed3d56bbe170c8491e77734822fbcd8f07fbe0c /drivers/video/omap2/dss/venc.c | |
parent | 225b650d41e7cdbf5cd322a461b04493caabed09 (diff) | |
download | linux-446f7bff703f5f82560afde90fb22b7a1d366bbc.tar.xz |
OMAP: DSS2: move set/get_update_mode()
Move set/get_update_mode() from omap_dss_device to omap_dss_driver.
This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
Diffstat (limited to 'drivers/video/omap2/dss/venc.c')
-rw-r--r-- | drivers/video/omap2/dss/venc.c | 27 |
1 files changed, 17 insertions, 10 deletions
diff --git a/drivers/video/omap2/dss/venc.c b/drivers/video/omap2/dss/venc.c index d13071dd46e5..0d0dc94417fc 100644 --- a/drivers/video/omap2/dss/venc.c +++ b/drivers/video/omap2/dss/venc.c @@ -450,6 +450,20 @@ static int venc_panel_resume(struct omap_dss_device *dssdev) return venc_panel_enable(dssdev); } +static enum omap_dss_update_mode venc_get_update_mode( + struct omap_dss_device *dssdev) +{ + return OMAP_DSS_UPDATE_AUTO; +} + +static int venc_set_update_mode(struct omap_dss_device *dssdev, + enum omap_dss_update_mode mode) +{ + if (mode != OMAP_DSS_UPDATE_AUTO) + return -EINVAL; + return 0; +} + static struct omap_dss_driver venc_driver = { .probe = venc_panel_probe, .remove = venc_panel_remove, @@ -462,6 +476,9 @@ static struct omap_dss_driver venc_driver = { .get_resolution = omapdss_default_get_resolution, .get_recommended_bpp = omapdss_default_get_recommended_bpp, + .set_update_mode = venc_set_update_mode, + .get_update_mode = venc_get_update_mode, + .driver = { .name = "venc", .owner = THIS_MODULE, @@ -717,15 +734,6 @@ static int venc_set_wss(struct omap_dss_device *dssdev, u32 wss) return 0; } -static enum omap_dss_update_mode venc_display_get_update_mode( - struct omap_dss_device *dssdev) -{ - if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE) - return OMAP_DSS_UPDATE_AUTO; - else - return OMAP_DSS_UPDATE_DISABLED; -} - int venc_init_display(struct omap_dss_device *dssdev) { DSSDBG("init_display\n"); @@ -739,7 +747,6 @@ int venc_init_display(struct omap_dss_device *dssdev) dssdev->check_timings = venc_check_timings; dssdev->get_wss = venc_get_wss; dssdev->set_wss = venc_set_wss; - dssdev->get_update_mode = venc_display_get_update_mode; return 0; } |