Refactor lock/unlock

Move the usage dependent codepath from
unlock to lock, also make lock/unlock
more symmetric in checking if hostHandle
is available.

Bug: 141385612
Test: boot, check if the virtual scene camera shows
Test: the picture and takes photos and videos.
Change-Id: I41d070dd051a1185276e34c27d8ccdbe48b4b4d7
Signed-off-by: Roman Kiryanov <rkir@google.com>
1 file changed