From c0c5b02c1fb92a59f3a285ad6183e28e4bad107a Mon Sep 17 00:00:00 2001 From: Michael Bestas Date: Fri, 25 May 2018 21:33:46 +0300 Subject: power: Remove unused camera_hint_ref_count * These were part of the commit that added mutex locks for camera hints. We have now removed the locks so this is no longer necessary Change-Id: I38b91ce4e8fc811b8d9a04e6ec20521adde1b264 --- power-8996.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'power-8996.c') diff --git a/power-8996.c b/power-8996.c index 2b72c21..9269149 100644 --- a/power-8996.c +++ b/power-8996.c @@ -47,8 +47,6 @@ #include "power-common.h" #include "utils.h" -static int camera_hint_ref_count; - static int process_video_encode_hint(void* metadata) { char governor[80]; struct video_encode_metadata_t video_encode_metadata; @@ -97,20 +95,14 @@ static int process_video_encode_hint(void* metadata) { 0x41414100, 0x22C, 0x41420100, 0x5A, 0x41810000, 0x9C4, 0x41814000, 0x32, 0x4180C000, 0x0, 0x41820000, 0xA}; - camera_hint_ref_count++; - if (camera_hint_ref_count == 1) { - perform_hint_action(video_encode_metadata.hint_id, resource_values, - ARRAY_SIZE(resource_values)); - } + perform_hint_action(video_encode_metadata.hint_id, resource_values, + ARRAY_SIZE(resource_values)); ALOGI("Video Encode hint start"); return HINT_HANDLED; } } else if (video_encode_metadata.state == 0) { if (is_interactive_governor(governor)) { - camera_hint_ref_count--; - if (!camera_hint_ref_count) { - undo_hint_action(video_encode_metadata.hint_id); - } + undo_hint_action(video_encode_metadata.hint_id); ALOGI("Video Encode hint stop"); return HINT_HANDLED; -- cgit v1.2.3