display: Remove unused function display_panel_set_dpms_running_state() 23/296023/3
authorYunhee Seo <yuni.seo@samsung.com>
Tue, 18 Jul 2023 10:04:00 +0000 (19:04 +0900)
committerChanwoo Choi <cw00.choi@samsung.com>
Tue, 25 Jul 2023 01:55:00 +0000 (01:55 +0000)
dpms_running_state variable and setter have never been used since they were added.
There is no place to call display_panel_set_dpms_running_state() and it is unreachable.
Thus display_panel_set_dpms_running_state() and dpms_running_state is removed.

Change-Id: I51a74e0e300d37e2d87808248a7759c0992c45d9
Signed-off-by: Yunhee Seo <yuni.seo@samsung.com>
src/display/device-interface.h
src/display/display-panel.c
src/display/display-panel.h

index 6f0fb1c..f490053 100644 (file)
@@ -45,8 +45,6 @@
 #define DEFAULT_DISPLAY_MAX_BRIGHTNESS  100
 #define DEFAULT_DISPLAY_MAX_DIM_BRIGHTNESS  50
 
-#define DPMS_SETTING_DONE      -1
-
 /*
  * Event type enumeration
  */
index 85b56a4..1314386 100644 (file)
@@ -45,7 +45,6 @@
        (b.tv_sec * 1000000 + b.tv_usec)) \
        / 1000)
 
-static int dpms_running_state = DPMS_SETTING_DONE;
 static bool lcd_paneloff_mode = false;
 static bool lcd_on_broadcasted = true;
 static struct timeval lcd_on_timeval;
@@ -515,12 +514,6 @@ int display_panel_calculate_diff_time_between_lcd_on_direct_and_state_action(int
 }
 
 /* FIXME: This function is deprecated, should be fixed after plugin refactoring */
-void display_panel_set_dpms_running_state(int val)
-{
-       dpms_running_state = val;
-}
-
-/* FIXME: This function is deprecated, should be fixed after plugin refactoring */
 int display_panel_get_dpms_state(void)
 {
        int ret;
@@ -538,9 +531,6 @@ int display_panel_get_dpms_state(void)
        //if (val == DISPLAY_ON && ambient_get_state())
        //      return DPMS_OFF;
 
-       if (dpms_running_state != DPMS_SETTING_DONE)
-               return dpms_running_state;
-
        switch (val) {
                case DISPLAY_ON:
                        return DPMS_ON;
index 1cee8c7..0e87988 100644 (file)
@@ -57,6 +57,5 @@ void display_panel_exit_dpms(void);
 void __display_panel_register_dpms_checklist(int mode, void (*checker)(void), const char *caller);
 #define display_panel_register_dpms_checklist(mode, checker) __display_panel_register_dpms_checklist(mode, checker, __func__)
 
-void display_panel_set_dpms_running_state(int val);
 
 #endif /* __DISPLAY_PANEL_H__ */