hwc: Fix locking.
Remove the unnecessary blank lock, mdp comp lock, secure lock.
Rename the ext lock to a more appropriate draw lock.
The mdp comp lock is at an incorrect place and causes unwanted
objects to show up in dumpsys, since configDone hasnt cleaned
them up yet.
dump(), blank(), draw() should all acquire a common lock.
draw() includes prepare() and set().
Change-Id: I595547dd5a393a8af6cd8c9297d50793b715e658
diff --git a/libhwcomposer/hwc_utils.h b/libhwcomposer/hwc_utils.h
index 71b51ab..d9f96a5 100644
--- a/libhwcomposer/hwc_utils.h
+++ b/libhwcomposer/hwc_utils.h
@@ -357,17 +357,8 @@
bool mVirtualonExtActive;
//Display in secure mode indicator
bool mSecureMode;
- //Lock to prevent set from being called while blanking
- mutable Locker mBlankLock;
- //Lock to protect prepare & set when detaching external disp
- mutable Locker mExtLock;
- /*Lock to set both mSecureMode and mSecuring as part
- of binder thread without context switch to composition
- thread. This lock is needed only for A-family targets
- since the state of mSecureMode and mSecuring variables
- are not checked in B-family targets.
- */
- mutable Locker mSecureLock;
+ //Lock to protect drawing data structures
+ mutable Locker mDrawLock;
//Drawing round when we use GPU
bool isPaddingRound;
// External Orientation