aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/omap2/omapfb
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@nokia.com>2010-01-12 07:16:41 -0500
committerTomi Valkeinen <tomi.valkeinen@nokia.com>2010-02-24 07:31:28 -0500
commit18946f62c6cc8cf051bafca8b7fa72309e8a1067 (patch)
treef1e33d76a571ebc4580b15c1b7ba1bec8e441cf6 /drivers/video/omap2/omapfb
parent446f7bff703f5f82560afde90fb22b7a1d366bbc (diff)
OMAP: DSS2: move update() and sync()
Move update() and sync() from omap_dss_device to omap_dss_driver. Also, update was hardcoded to use virtual channel 0. This patch adds a parameter that specifies the VC. 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/omapfb')
-rw-r--r--drivers/video/omap2/omapfb/omapfb-ioctl.c10
-rw-r--r--drivers/video/omap2/omapfb/omapfb-main.c10
2 files changed, 10 insertions, 10 deletions
diff --git a/drivers/video/omap2/omapfb/omapfb-ioctl.c b/drivers/video/omap2/omapfb/omapfb-ioctl.c
index 4f68cb0d59de..1ffa760b8545 100644
--- a/drivers/video/omap2/omapfb/omapfb-ioctl.c
+++ b/drivers/video/omap2/omapfb/omapfb-ioctl.c
@@ -172,7 +172,7 @@ static int omapfb_update_window_nolock(struct fb_info *fbi,
172 if (x + w > dw || y + h > dh) 172 if (x + w > dw || y + h > dh)
173 return -EINVAL; 173 return -EINVAL;
174 174
175 return display->update(display, x, y, w, h); 175 return display->driver->update(display, x, y, w, h);
176} 176}
177 177
178/* This function is exported for SGX driver use */ 178/* This function is exported for SGX driver use */
@@ -496,18 +496,18 @@ int omapfb_ioctl(struct fb_info *fbi, unsigned int cmd, unsigned long arg)
496 switch (cmd) { 496 switch (cmd) {
497 case OMAPFB_SYNC_GFX: 497 case OMAPFB_SYNC_GFX:
498 DBG("ioctl SYNC_GFX\n"); 498 DBG("ioctl SYNC_GFX\n");
499 if (!display || !display->sync) { 499 if (!display || !display->driver->sync) {
500 /* DSS1 never returns an error here, so we neither */ 500 /* DSS1 never returns an error here, so we neither */
501 /*r = -EINVAL;*/ 501 /*r = -EINVAL;*/
502 break; 502 break;
503 } 503 }
504 504
505 r = display->sync(display); 505 r = display->driver->sync(display);
506 break; 506 break;
507 507
508 case OMAPFB_UPDATE_WINDOW_OLD: 508 case OMAPFB_UPDATE_WINDOW_OLD:
509 DBG("ioctl UPDATE_WINDOW_OLD\n"); 509 DBG("ioctl UPDATE_WINDOW_OLD\n");
510 if (!display || !display->update) { 510 if (!display || !display->driver->update) {
511 r = -EINVAL; 511 r = -EINVAL;
512 break; 512 break;
513 } 513 }
@@ -525,7 +525,7 @@ int omapfb_ioctl(struct fb_info *fbi, unsigned int cmd, unsigned long arg)
525 525
526 case OMAPFB_UPDATE_WINDOW: 526 case OMAPFB_UPDATE_WINDOW:
527 DBG("ioctl UPDATE_WINDOW\n"); 527 DBG("ioctl UPDATE_WINDOW\n");
528 if (!display || !display->update) { 528 if (!display || !display->driver->update) {
529 r = -EINVAL; 529 r = -EINVAL;
530 break; 530 break;
531 } 531 }
diff --git a/drivers/video/omap2/omapfb/omapfb-main.c b/drivers/video/omap2/omapfb/omapfb-main.c
index c720842341b2..3dbbddc2d51e 100644
--- a/drivers/video/omap2/omapfb/omapfb-main.c
+++ b/drivers/video/omap2/omapfb/omapfb-main.c
@@ -1254,11 +1254,11 @@ static int omapfb_blank(int blank, struct fb_info *fbi)
1254exit: 1254exit:
1255 omapfb_unlock(fbdev); 1255 omapfb_unlock(fbdev);
1256 1256
1257 if (r == 0 && do_update && display->update) { 1257 if (r == 0 && do_update && display->driver->update) {
1258 u16 w, h; 1258 u16 w, h;
1259 display->driver->get_resolution(display, &w, &h); 1259 display->driver->get_resolution(display, &w, &h);
1260 1260
1261 r = display->update(display, 0, 0, w, h); 1261 r = display->driver->update(display, 0, 0, w, h);
1262 } 1262 }
1263 1263
1264 return r; 1264 return r;
@@ -1639,8 +1639,8 @@ int omapfb_realloc_fbmem(struct fb_info *fbi, unsigned long size, int type)
1639 if (old_size == size && old_type == type) 1639 if (old_size == size && old_type == type)
1640 return 0; 1640 return 0;
1641 1641
1642 if (display && display->sync) 1642 if (display && display->driver->sync)
1643 display->sync(display); 1643 display->driver->sync(display);
1644 1644
1645 omapfb_free_fbmem(fbi); 1645 omapfb_free_fbmem(fbi);
1646 1646
@@ -2221,7 +2221,7 @@ static int omapfb_probe(struct platform_device *pdev)
2221 2221
2222 dssdrv->get_resolution(def_display, 2222 dssdrv->get_resolution(def_display,
2223 &w, &h); 2223 &w, &h);
2224 def_display->update(def_display, 0, 0, w, h); 2224 def_display->driver->update(def_display, 0, 0, w, h);
2225#endif 2225#endif
2226 } else { 2226 } else {
2227 if (dssdrv->set_update_mode) 2227 if (dssdrv->set_update_mode)