Lines Matching refs:in

33 void amd_pmf_dump_ta_inputs(struct amd_pmf_dev *dev, struct ta_pmf_enact_table *in)  in amd_pmf_dump_ta_inputs()  argument
36 dev_dbg(dev->dev, "Slider State: %s\n", ta_slider_as_str(in->ev_info.power_slider)); in amd_pmf_dump_ta_inputs()
37 dev_dbg(dev->dev, "Power Source: %s\n", amd_pmf_source_as_str(in->ev_info.power_source)); in amd_pmf_dump_ta_inputs()
38 dev_dbg(dev->dev, "Battery Percentage: %u\n", in->ev_info.bat_percentage); in amd_pmf_dump_ta_inputs()
39 dev_dbg(dev->dev, "Designed Battery Capacity: %u\n", in->ev_info.bat_design); in amd_pmf_dump_ta_inputs()
40 dev_dbg(dev->dev, "Fully Charged Capacity: %u\n", in->ev_info.full_charge_capacity); in amd_pmf_dump_ta_inputs()
41 dev_dbg(dev->dev, "Drain Rate: %d\n", in->ev_info.drain_rate); in amd_pmf_dump_ta_inputs()
42 dev_dbg(dev->dev, "Socket Power: %u\n", in->ev_info.socket_power); in amd_pmf_dump_ta_inputs()
43 dev_dbg(dev->dev, "Skin Temperature: %u\n", in->ev_info.skin_temperature); in amd_pmf_dump_ta_inputs()
44 dev_dbg(dev->dev, "Avg C0 Residency: %u\n", in->ev_info.avg_c0residency); in amd_pmf_dump_ta_inputs()
45 dev_dbg(dev->dev, "Max C0 Residency: %u\n", in->ev_info.max_c0residency); in amd_pmf_dump_ta_inputs()
46 dev_dbg(dev->dev, "GFX Busy: %u\n", in->ev_info.gfx_busy); in amd_pmf_dump_ta_inputs()
47 dev_dbg(dev->dev, "LID State: %s\n", in->ev_info.lid_state ? "close" : "open"); in amd_pmf_dump_ta_inputs()
48 dev_dbg(dev->dev, "User Presence: %s\n", in->ev_info.user_present ? "Present" : "Away"); in amd_pmf_dump_ta_inputs()
49 dev_dbg(dev->dev, "Ambient Light: %d\n", in->ev_info.ambient_light); in amd_pmf_dump_ta_inputs()
53 void amd_pmf_dump_ta_inputs(struct amd_pmf_dev *dev, struct ta_pmf_enact_table *in) {} in amd_pmf_dump_ta_inputs() argument
56 static void amd_pmf_get_c0_residency(u16 *core_res, size_t size, struct ta_pmf_enact_table *in) in amd_pmf_get_c0_residency() argument
69 in->ev_info.avg_c0residency = avg; in amd_pmf_get_c0_residency()
70 in->ev_info.max_c0residency = max; in amd_pmf_get_c0_residency()
73 static void amd_pmf_get_smu_info(struct amd_pmf_dev *dev, struct ta_pmf_enact_table *in) in amd_pmf_get_smu_info() argument
82 in->ev_info.socket_power = dev->m_table.apu_power + dev->m_table.dgpu_power; in amd_pmf_get_smu_info()
83 in->ev_info.skin_temperature = dev->m_table.skin_temp; in amd_pmf_get_smu_info()
84 in->ev_info.gfx_busy = dev->m_table.avg_gfx_activity; in amd_pmf_get_smu_info()
86 ARRAY_SIZE(dev->m_table.avg_core_c0residency), in); in amd_pmf_get_smu_info()
91 in->ev_info.socket_power = dev->m_table_v2.apu_power + dev->m_table_v2.dgpu_power; in amd_pmf_get_smu_info()
92 in->ev_info.skin_temperature = dev->m_table_v2.skin_temp; in amd_pmf_get_smu_info()
93 in->ev_info.gfx_busy = dev->m_table_v2.gfx_activity; in amd_pmf_get_smu_info()
95 ARRAY_SIZE(dev->m_table_v2.core_c0residency), in); in amd_pmf_get_smu_info()
128 static int amd_pmf_get_battery_info(struct amd_pmf_dev *dev, struct ta_pmf_enact_table *in) in amd_pmf_get_battery_info() argument
138 in->ev_info.bat_percentage = amd_pmf_get_battery_prop(POWER_SUPPLY_PROP_CAPACITY); in amd_pmf_get_battery_info()
140 in->ev_info.bat_design = amd_pmf_get_battery_prop(POWER_SUPPLY_PROP_ENERGY_FULL_DESIGN) / in amd_pmf_get_battery_info()
142 in->ev_info.full_charge_capacity = amd_pmf_get_battery_prop(POWER_SUPPLY_PROP_ENERGY_FULL) / in amd_pmf_get_battery_info()
144 in->ev_info.drain_rate = amd_pmf_get_battery_prop(POWER_SUPPLY_PROP_POWER_NOW) / in amd_pmf_get_battery_info()
150 static int amd_pmf_get_slider_info(struct amd_pmf_dev *dev, struct ta_pmf_enact_table *in) in amd_pmf_get_slider_info() argument
168 in->ev_info.power_slider = val; in amd_pmf_get_slider_info()
173 static void amd_pmf_get_sensor_info(struct amd_pmf_dev *dev, struct ta_pmf_enact_table *in) in amd_pmf_get_sensor_info() argument
178 in->ev_info.user_present = false; in amd_pmf_get_sensor_info()
182 in->ev_info.ambient_light = sfh_info.ambient_light; in amd_pmf_get_sensor_info()
189 in->ev_info.user_present = true; in amd_pmf_get_sensor_info()
195 void amd_pmf_populate_ta_inputs(struct amd_pmf_dev *dev, struct ta_pmf_enact_table *in) in amd_pmf_populate_ta_inputs() argument
198 in->ev_info.lid_state = !acpi_lid_open(); in amd_pmf_populate_ta_inputs()
199 in->ev_info.power_source = amd_pmf_get_power_source(); in amd_pmf_populate_ta_inputs()
200 amd_pmf_get_smu_info(dev, in); in amd_pmf_populate_ta_inputs()
201 amd_pmf_get_battery_info(dev, in); in amd_pmf_populate_ta_inputs()
202 amd_pmf_get_slider_info(dev, in); in amd_pmf_populate_ta_inputs()
203 amd_pmf_get_sensor_info(dev, in); in amd_pmf_populate_ta_inputs()