Lines Matching refs:config_store

15 static struct auto_mode_mode_config config_store;  variable
21 struct power_table_control *pwr_ctrl = &config_store.mode_set[idx].power_control; in amd_pmf_set_automode()
34 apmf_update_fan_idx(dev, config_store.mode_set[idx].fan_control.manual, in amd_pmf_set_automode()
35 config_store.mode_set[idx].fan_control.fan_id); in amd_pmf_set_automode()
66 if ((config_store.transition[i].shifting_up && avg_power >= in amd_pmf_trans_automode()
67 config_store.transition[i].power_threshold) || in amd_pmf_trans_automode()
68 (!config_store.transition[i].shifting_up && avg_power <= in amd_pmf_trans_automode()
69 config_store.transition[i].power_threshold)) { in amd_pmf_trans_automode()
70 if (config_store.transition[i].timer < in amd_pmf_trans_automode()
71 config_store.transition[i].time_constant) in amd_pmf_trans_automode()
72 config_store.transition[i].timer += time_elapsed_ms; in amd_pmf_trans_automode()
74 config_store.transition[i].timer = 0; in amd_pmf_trans_automode()
77 if (config_store.transition[i].timer >= in amd_pmf_trans_automode()
78 config_store.transition[i].time_constant && in amd_pmf_trans_automode()
79 !config_store.transition[i].applied) { in amd_pmf_trans_automode()
80 config_store.transition[i].applied = true; in amd_pmf_trans_automode()
82 } else if (config_store.transition[i].timer <= in amd_pmf_trans_automode()
83 config_store.transition[i].time_constant && in amd_pmf_trans_automode()
84 config_store.transition[i].applied) { in amd_pmf_trans_automode()
85 config_store.transition[i].applied = false; in amd_pmf_trans_automode()
91 state_as_str(config_store.current_mode)); in amd_pmf_trans_automode()
96 if (config_store.transition[j].applied) { in amd_pmf_trans_automode()
97 if (config_store.current_mode != in amd_pmf_trans_automode()
98 config_store.transition[j].target_mode) { in amd_pmf_trans_automode()
99 config_store.current_mode = in amd_pmf_trans_automode()
100 config_store.transition[j].target_mode; in amd_pmf_trans_automode()
102 state_as_str(config_store.current_mode)); in amd_pmf_trans_automode()
103 amd_pmf_set_automode(dev, config_store.current_mode, NULL); in amd_pmf_trans_automode()
113 int mode = config_store.current_mode; in amd_pmf_update_2_cql()
115 config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].target_mode = in amd_pmf_update_2_cql()
119 mode != config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].target_mode) { in amd_pmf_update_2_cql()
120 mode = config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].target_mode; in amd_pmf_update_2_cql()
128 config_store.transition[AUTO_TRANSITION_TO_QUIET].power_threshold = in amd_pmf_get_power_threshold()
129 config_store.mode_set[AUTO_BALANCE].power_floor - in amd_pmf_get_power_threshold()
130 config_store.transition[AUTO_TRANSITION_TO_QUIET].power_delta; in amd_pmf_get_power_threshold()
132 config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].power_threshold = in amd_pmf_get_power_threshold()
133 config_store.mode_set[AUTO_BALANCE].power_floor - in amd_pmf_get_power_threshold()
134 config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].power_delta; in amd_pmf_get_power_threshold()
136 config_store.transition[AUTO_TRANSITION_FROM_QUIET_TO_BALANCE].power_threshold = in amd_pmf_get_power_threshold()
137 config_store.mode_set[AUTO_QUIET].power_floor - in amd_pmf_get_power_threshold()
138 config_store.transition[AUTO_TRANSITION_FROM_QUIET_TO_BALANCE].power_delta; in amd_pmf_get_power_threshold()
140 config_store.transition[AUTO_TRANSITION_FROM_PERFORMANCE_TO_BALANCE].power_threshold = in amd_pmf_get_power_threshold()
141 config_store.mode_set[AUTO_PERFORMANCE].power_floor - in amd_pmf_get_power_threshold()
142 config_store.transition[AUTO_TRANSITION_FROM_PERFORMANCE_TO_BALANCE].power_delta; in amd_pmf_get_power_threshold()
169 config_store.transition[AUTO_TRANSITION_TO_QUIET].time_constant = in amd_pmf_load_defaults_auto_mode()
171 config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].time_constant = in amd_pmf_load_defaults_auto_mode()
173 config_store.transition[AUTO_TRANSITION_FROM_QUIET_TO_BALANCE].time_constant = in amd_pmf_load_defaults_auto_mode()
175 config_store.transition[AUTO_TRANSITION_FROM_PERFORMANCE_TO_BALANCE].time_constant = in amd_pmf_load_defaults_auto_mode()
179 config_store.mode_set[AUTO_QUIET].power_floor = output.pfloor_quiet; in amd_pmf_load_defaults_auto_mode()
180 config_store.mode_set[AUTO_BALANCE].power_floor = output.pfloor_balanced; in amd_pmf_load_defaults_auto_mode()
181 config_store.mode_set[AUTO_PERFORMANCE].power_floor = output.pfloor_perf; in amd_pmf_load_defaults_auto_mode()
182 config_store.mode_set[AUTO_PERFORMANCE_ON_LAP].power_floor = output.pfloor_perf; in amd_pmf_load_defaults_auto_mode()
185 config_store.transition[AUTO_TRANSITION_TO_QUIET].power_delta = in amd_pmf_load_defaults_auto_mode()
187 config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].power_delta = in amd_pmf_load_defaults_auto_mode()
189 config_store.transition[AUTO_TRANSITION_FROM_QUIET_TO_BALANCE].power_delta = in amd_pmf_load_defaults_auto_mode()
191 config_store.transition[AUTO_TRANSITION_FROM_PERFORMANCE_TO_BALANCE].power_delta = in amd_pmf_load_defaults_auto_mode()
198 pwr_ctrl = &config_store.mode_set[AUTO_QUIET].power_control; in amd_pmf_load_defaults_auto_mode()
207 pwr_ctrl = &config_store.mode_set[AUTO_BALANCE].power_control; in amd_pmf_load_defaults_auto_mode()
216 pwr_ctrl = &config_store.mode_set[AUTO_PERFORMANCE].power_control; in amd_pmf_load_defaults_auto_mode()
225 pwr_ctrl = &config_store.mode_set[AUTO_PERFORMANCE_ON_LAP].power_control; in amd_pmf_load_defaults_auto_mode()
235 config_store.mode_set[AUTO_QUIET].fan_control.fan_id = output.fan_id_quiet; in amd_pmf_load_defaults_auto_mode()
236 config_store.mode_set[AUTO_BALANCE].fan_control.fan_id = output.fan_id_balanced; in amd_pmf_load_defaults_auto_mode()
237 config_store.mode_set[AUTO_PERFORMANCE].fan_control.fan_id = output.fan_id_perf; in amd_pmf_load_defaults_auto_mode()
238 config_store.mode_set[AUTO_PERFORMANCE_ON_LAP].fan_control.fan_id = in amd_pmf_load_defaults_auto_mode()
241 config_store.transition[AUTO_TRANSITION_TO_QUIET].target_mode = AUTO_QUIET; in amd_pmf_load_defaults_auto_mode()
242 config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].target_mode = in amd_pmf_load_defaults_auto_mode()
244 config_store.transition[AUTO_TRANSITION_FROM_QUIET_TO_BALANCE].target_mode = in amd_pmf_load_defaults_auto_mode()
246 config_store.transition[AUTO_TRANSITION_FROM_PERFORMANCE_TO_BALANCE].target_mode = in amd_pmf_load_defaults_auto_mode()
249 config_store.transition[AUTO_TRANSITION_TO_QUIET].shifting_up = false; in amd_pmf_load_defaults_auto_mode()
250 config_store.transition[AUTO_TRANSITION_TO_PERFORMANCE].shifting_up = true; in amd_pmf_load_defaults_auto_mode()
251 config_store.transition[AUTO_TRANSITION_FROM_QUIET_TO_BALANCE].shifting_up = true; in amd_pmf_load_defaults_auto_mode()
252 config_store.transition[AUTO_TRANSITION_FROM_PERFORMANCE_TO_BALANCE].shifting_up = in amd_pmf_load_defaults_auto_mode()
256 if (config_store.mode_set[i].fan_control.fan_id == FAN_INDEX_AUTO) in amd_pmf_load_defaults_auto_mode()
257 config_store.mode_set[i].fan_control.manual = false; in amd_pmf_load_defaults_auto_mode()
259 config_store.mode_set[i].fan_control.manual = true; in amd_pmf_load_defaults_auto_mode()
263 config_store.current_mode = AUTO_BALANCE; in amd_pmf_load_defaults_auto_mode()
291 amd_pmf_set_automode(dev, config_store.current_mode, NULL); in amd_pmf_handle_amt()
303 amd_pmf_set_automode(dev, config_store.current_mode, NULL); in amd_pmf_init_auto_mode()