Lines Matching refs:acpi_battery
95 struct acpi_battery { struct
134 static inline int acpi_battery_present(struct acpi_battery *battery) in acpi_battery_present() argument
139 static int acpi_battery_technology(struct acpi_battery *battery) in acpi_battery_technology()
154 static int acpi_battery_get_state(struct acpi_battery *battery);
156 static int acpi_battery_is_charged(struct acpi_battery *battery) in acpi_battery_is_charged()
179 static bool acpi_battery_is_degraded(struct acpi_battery *battery) in acpi_battery_is_degraded()
186 static int acpi_battery_handle_discharging(struct acpi_battery *battery) in acpi_battery_handle_discharging()
205 struct acpi_battery *battery = to_acpi_battery(psy); in acpi_battery_get_property()
382 {offsetof(struct acpi_battery, state), 0},
383 {offsetof(struct acpi_battery, rate_now), 0},
384 {offsetof(struct acpi_battery, capacity_now), 0},
385 {offsetof(struct acpi_battery, voltage_now), 0},
389 {offsetof(struct acpi_battery, power_unit), 0},
390 {offsetof(struct acpi_battery, design_capacity), 0},
391 {offsetof(struct acpi_battery, full_charge_capacity), 0},
392 {offsetof(struct acpi_battery, technology), 0},
393 {offsetof(struct acpi_battery, design_voltage), 0},
394 {offsetof(struct acpi_battery, design_capacity_warning), 0},
395 {offsetof(struct acpi_battery, design_capacity_low), 0},
396 {offsetof(struct acpi_battery, capacity_granularity_1), 0},
397 {offsetof(struct acpi_battery, capacity_granularity_2), 0},
398 {offsetof(struct acpi_battery, model_number), 1},
399 {offsetof(struct acpi_battery, serial_number), 1},
400 {offsetof(struct acpi_battery, type), 1},
401 {offsetof(struct acpi_battery, oem_info), 1},
405 {offsetof(struct acpi_battery, revision), 0},
406 {offsetof(struct acpi_battery, power_unit), 0},
407 {offsetof(struct acpi_battery, design_capacity), 0},
408 {offsetof(struct acpi_battery, full_charge_capacity), 0},
409 {offsetof(struct acpi_battery, technology), 0},
410 {offsetof(struct acpi_battery, design_voltage), 0},
411 {offsetof(struct acpi_battery, design_capacity_warning), 0},
412 {offsetof(struct acpi_battery, design_capacity_low), 0},
413 {offsetof(struct acpi_battery, cycle_count), 0},
414 {offsetof(struct acpi_battery, measurement_accuracy), 0},
415 {offsetof(struct acpi_battery, max_sampling_time), 0},
416 {offsetof(struct acpi_battery, min_sampling_time), 0},
417 {offsetof(struct acpi_battery, max_averaging_interval), 0},
418 {offsetof(struct acpi_battery, min_averaging_interval), 0},
419 {offsetof(struct acpi_battery, capacity_granularity_1), 0},
420 {offsetof(struct acpi_battery, capacity_granularity_2), 0},
421 {offsetof(struct acpi_battery, model_number), 1},
422 {offsetof(struct acpi_battery, serial_number), 1},
423 {offsetof(struct acpi_battery, type), 1},
424 {offsetof(struct acpi_battery, oem_info), 1},
427 static int extract_package(struct acpi_battery *battery, in extract_package()
470 static int acpi_battery_get_status(struct acpi_battery *battery) in acpi_battery_get_status()
482 struct acpi_battery *battery, in extract_battery_info()
524 static int acpi_battery_get_info(struct acpi_battery *battery) in acpi_battery_get_info()
565 static int acpi_battery_get_state(struct acpi_battery *battery) in acpi_battery_get_state()
623 static int acpi_battery_set_alarm(struct acpi_battery *battery) in acpi_battery_set_alarm()
645 static int acpi_battery_init_alarm(struct acpi_battery *battery) in acpi_battery_init_alarm()
662 struct acpi_battery *battery = to_acpi_battery(dev_get_drvdata(dev)); in acpi_battery_alarm_show()
672 struct acpi_battery *battery = to_acpi_battery(dev_get_drvdata(dev)); in acpi_battery_alarm_store()
691 ATTRIBUTE_GROUPS(acpi_battery);
708 struct acpi_battery *battery; in battery_hook_unregister_unlocked()
740 struct acpi_battery *battery; in battery_hook_register()
776 static void battery_hook_add_battery(struct acpi_battery *battery) in battery_hook_add_battery()
804 static void battery_hook_remove_battery(struct acpi_battery *battery) in battery_hook_remove_battery()
836 static int sysfs_add_battery(struct acpi_battery *battery) in sysfs_add_battery()
889 static void sysfs_remove_battery(struct acpi_battery *battery) in sysfs_remove_battery()
904 struct acpi_battery *battery = (struct acpi_battery *)private; in find_battery()
934 static void acpi_battery_quirks(struct acpi_battery *battery) in acpi_battery_quirks()
985 static int acpi_battery_update(struct acpi_battery *battery, bool resume) in acpi_battery_update()
1031 static void acpi_battery_refresh(struct acpi_battery *battery) in acpi_battery_refresh()
1054 struct acpi_battery *battery = acpi_driver_data(device); in acpi_battery_notify()
1083 struct acpi_battery *battery = container_of(nb, struct acpi_battery, in battery_notify()
1181 static int acpi_battery_update_retry(struct acpi_battery *battery) in acpi_battery_update_retry()
1198 struct acpi_battery *battery = NULL; in acpi_battery_add()
1206 battery = kzalloc(sizeof(struct acpi_battery), GFP_KERNEL); in acpi_battery_add()
1251 struct acpi_battery *battery = NULL; in acpi_battery_remove()
1274 struct acpi_battery *battery; in acpi_battery_resume()