aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2011-11-16 07:31:58 -0500
committerTomi Valkeinen <tomi.valkeinen@ti.com>2011-12-02 01:54:48 -0500
commit0b53f17971700f673492e2e91b5069893e5f2d0b (patch)
tree543bfea718b2ce64ec35bbf03a2bb142d85b4d9a /drivers/video
parent6dc802e2901d33e02efad3c90bb2034fd20c79e7 (diff)
OMAPDSS: APPLY: rename dirty & shadow_dirty
Rename ovl_priv_data's and mgr_priv_data's dirty and shadow_dirty fields to info_dirty and shadow_info_dirty to better reflect what they mean. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/video')
-rw-r--r--drivers/video/omap2/dss/apply.c62
1 files changed, 27 insertions, 35 deletions
diff --git a/drivers/video/omap2/dss/apply.c b/drivers/video/omap2/dss/apply.c
index d5505becd065..9916eb8e20d5 100644
--- a/drivers/video/omap2/dss/apply.c
+++ b/drivers/video/omap2/dss/apply.c
@@ -31,8 +31,10 @@
31 * We have 4 levels of cache for the dispc settings. First two are in SW and 31 * We have 4 levels of cache for the dispc settings. First two are in SW and
32 * the latter two in HW. 32 * the latter two in HW.
33 * 33 *
34 * set_info()
35 * v
34 * +--------------------+ 36 * +--------------------+
35 * |overlay/manager_info| 37 * | user_info |
36 * +--------------------+ 38 * +--------------------+
37 * v 39 * v
38 * apply() 40 * apply()
@@ -59,16 +61,11 @@ struct ovl_priv_data {
59 bool user_info_dirty; 61 bool user_info_dirty;
60 struct omap_overlay_info user_info; 62 struct omap_overlay_info user_info;
61 63
62 /* If true, cache changed, but not written to shadow registers. Set 64 bool info_dirty;
63 * in apply(), cleared when registers written. */
64 bool dirty;
65 /* If true, shadow registers contain changed values not yet in real
66 * registers. Set when writing to shadow registers, cleared at
67 * VSYNC/EVSYNC */
68 bool shadow_dirty;
69
70 struct omap_overlay_info info; 65 struct omap_overlay_info info;
71 66
67 bool shadow_info_dirty;
68
72 bool extra_info_dirty; 69 bool extra_info_dirty;
73 bool shadow_extra_info_dirty; 70 bool shadow_extra_info_dirty;
74 71
@@ -82,16 +79,11 @@ struct mgr_priv_data {
82 bool user_info_dirty; 79 bool user_info_dirty;
83 struct omap_overlay_manager_info user_info; 80 struct omap_overlay_manager_info user_info;
84 81
85 /* If true, cache changed, but not written to shadow registers. Set 82 bool info_dirty;
86 * in apply(), cleared when registers written. */
87 bool dirty;
88 /* If true, shadow registers contain changed values not yet in real
89 * registers. Set when writing to shadow registers, cleared at
90 * VSYNC/EVSYNC */
91 bool shadow_dirty;
92
93 struct omap_overlay_manager_info info; 83 struct omap_overlay_manager_info info;
94 84
85 bool shadow_info_dirty;
86
95 /* If true, GO bit is up and shadow registers cannot be written. 87 /* If true, GO bit is up and shadow registers cannot be written.
96 * Never true for manual update displays */ 88 * Never true for manual update displays */
97 bool busy; 89 bool busy;
@@ -199,7 +191,7 @@ static bool need_isr(void)
199 return true; 191 return true;
200 192
201 /* to write new values to registers */ 193 /* to write new values to registers */
202 if (mp->dirty) 194 if (mp->info_dirty)
203 return true; 195 return true;
204 196
205 list_for_each_entry(ovl, &mgr->overlays, list) { 197 list_for_each_entry(ovl, &mgr->overlays, list) {
@@ -211,7 +203,7 @@ static bool need_isr(void)
211 continue; 203 continue;
212 204
213 /* to write new values to registers */ 205 /* to write new values to registers */
214 if (op->dirty || op->extra_info_dirty) 206 if (op->info_dirty || op->extra_info_dirty)
215 return true; 207 return true;
216 } 208 }
217 } 209 }
@@ -228,12 +220,12 @@ static bool need_go(struct omap_overlay_manager *mgr)
228 220
229 mp = get_mgr_priv(mgr); 221 mp = get_mgr_priv(mgr);
230 222
231 if (mp->shadow_dirty) 223 if (mp->shadow_info_dirty)
232 return true; 224 return true;
233 225
234 list_for_each_entry(ovl, &mgr->overlays, list) { 226 list_for_each_entry(ovl, &mgr->overlays, list) {
235 op = get_ovl_priv(ovl); 227 op = get_ovl_priv(ovl);
236 if (op->shadow_dirty || op->shadow_extra_info_dirty) 228 if (op->shadow_info_dirty || op->shadow_extra_info_dirty)
237 return true; 229 return true;
238 } 230 }
239 231
@@ -264,8 +256,8 @@ int dss_mgr_wait_for_go(struct omap_overlay_manager *mgr)
264 bool shadow_dirty, dirty; 256 bool shadow_dirty, dirty;
265 257
266 spin_lock_irqsave(&data_lock, flags); 258 spin_lock_irqsave(&data_lock, flags);
267 dirty = mp->dirty; 259 dirty = mp->info_dirty;
268 shadow_dirty = mp->shadow_dirty; 260 shadow_dirty = mp->shadow_info_dirty;
269 spin_unlock_irqrestore(&data_lock, flags); 261 spin_unlock_irqrestore(&data_lock, flags);
270 262
271 if (!dirty && !shadow_dirty) { 263 if (!dirty && !shadow_dirty) {
@@ -327,8 +319,8 @@ int dss_mgr_wait_for_go_ovl(struct omap_overlay *ovl)
327 bool shadow_dirty, dirty; 319 bool shadow_dirty, dirty;
328 320
329 spin_lock_irqsave(&data_lock, flags); 321 spin_lock_irqsave(&data_lock, flags);
330 dirty = op->dirty; 322 dirty = op->info_dirty;
331 shadow_dirty = op->shadow_dirty; 323 shadow_dirty = op->shadow_info_dirty;
332 spin_unlock_irqrestore(&data_lock, flags); 324 spin_unlock_irqrestore(&data_lock, flags);
333 325
334 if (!dirty && !shadow_dirty) { 326 if (!dirty && !shadow_dirty) {
@@ -371,7 +363,7 @@ static void dss_ovl_write_regs(struct omap_overlay *ovl)
371 363
372 DSSDBGF("%d", ovl->id); 364 DSSDBGF("%d", ovl->id);
373 365
374 if (!op->enabled || !op->dirty) 366 if (!op->enabled || !op->info_dirty)
375 return; 367 return;
376 368
377 oi = &op->info; 369 oi = &op->info;
@@ -396,9 +388,9 @@ static void dss_ovl_write_regs(struct omap_overlay *ovl)
396 388
397 mp = get_mgr_priv(ovl->manager); 389 mp = get_mgr_priv(ovl->manager);
398 390
399 op->dirty = false; 391 op->info_dirty = false;
400 if (mp->updating) 392 if (mp->updating)
401 op->shadow_dirty = true; 393 op->shadow_info_dirty = true;
402} 394}
403 395
404static void dss_ovl_write_regs_extra(struct omap_overlay *ovl) 396static void dss_ovl_write_regs_extra(struct omap_overlay *ovl)
@@ -443,12 +435,12 @@ static void dss_mgr_write_regs(struct omap_overlay_manager *mgr)
443 dss_ovl_write_regs_extra(ovl); 435 dss_ovl_write_regs_extra(ovl);
444 } 436 }
445 437
446 if (mp->dirty) { 438 if (mp->info_dirty) {
447 dispc_mgr_setup(mgr->id, &mp->info); 439 dispc_mgr_setup(mgr->id, &mp->info);
448 440
449 mp->dirty = false; 441 mp->info_dirty = false;
450 if (mp->updating) 442 if (mp->updating)
451 mp->shadow_dirty = true; 443 mp->shadow_info_dirty = true;
452 } 444 }
453} 445}
454 446
@@ -548,11 +540,11 @@ static void mgr_clear_shadow_dirty(struct omap_overlay_manager *mgr)
548 struct ovl_priv_data *op; 540 struct ovl_priv_data *op;
549 541
550 mp = get_mgr_priv(mgr); 542 mp = get_mgr_priv(mgr);
551 mp->shadow_dirty = false; 543 mp->shadow_info_dirty = false;
552 544
553 list_for_each_entry(ovl, &mgr->overlays, list) { 545 list_for_each_entry(ovl, &mgr->overlays, list) {
554 op = get_ovl_priv(ovl); 546 op = get_ovl_priv(ovl);
555 op->shadow_dirty = false; 547 op->shadow_info_dirty = false;
556 op->shadow_extra_info_dirty = false; 548 op->shadow_extra_info_dirty = false;
557 } 549 }
558} 550}
@@ -606,7 +598,7 @@ static void omap_dss_mgr_apply_ovl(struct omap_overlay *ovl)
606 return; 598 return;
607 599
608 op->user_info_dirty = false; 600 op->user_info_dirty = false;
609 op->dirty = true; 601 op->info_dirty = true;
610 op->info = op->user_info; 602 op->info = op->user_info;
611} 603}
612 604
@@ -625,7 +617,7 @@ static void omap_dss_mgr_apply_mgr(struct omap_overlay_manager *mgr)
625 return; 617 return;
626 618
627 mp->user_info_dirty = false; 619 mp->user_info_dirty = false;
628 mp->dirty = true; 620 mp->info_dirty = true;
629 mp->info = mp->user_info; 621 mp->info = mp->user_info;
630} 622}
631 623