drivers/hwmon/asus-ec-sensors.c
Source file repositories/reference/linux-study-clean/drivers/hwmon/asus-ec-sensors.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/hwmon/asus-ec-sensors.c- Extension
.c- Size
- 50821 bytes
- Lines
- 1553
- Domain
- Driver Families
- Bucket
- drivers/hwmon
- Inferred role
- Driver Families: exported/initcall integration point
- Status
- integration implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/acpi.hlinux/bitops.hlinux/dev_printk.hlinux/dmi.hlinux/hwmon.hlinux/init.hlinux/jiffies.hlinux/kernel.hlinux/module.hlinux/platform_device.hlinux/sort.hlinux/units.hlinux/unaligned.h
Detected Declarations
struct ec_sensor_infostruct ec_board_infostruct ec_sensorstruct lock_datastruct ec_sensors_dataenum ec_sensorsenum board_familyfunction lock_via_acpi_mutexfunction unlock_acpi_mutexfunction lock_via_global_acpi_lockfunction unlock_global_acpi_lockfunction register_bankfunction register_indexfunction is_sensor_data_signedfunction get_sensor_infofunction find_ec_sensor_indexfunction bank_comparefunction setup_sensor_datafunction for_each_set_bitfunction fill_ec_registersfunction setup_lock_datafunction asus_ec_bank_switchfunction asus_ec_block_readfunction get_sensor_valuefunction update_sensor_valuesfunction update_ec_sensorsfunction scale_sensor_valuefunction get_cached_value_or_updatefunction asus_ec_hwmon_readfunction asus_ec_hwmon_read_stringfunction asus_ec_hwmon_is_visiblefunction asus_ec_hwmon_add_chan_infofunction asus_ec_probefunction asus_ec_initfunction asus_ec_exitmodule init asus_ec_init
Annotated Snippet
module_init(asus_ec_init);
module_exit(asus_ec_exit);
module_param_named(mutex_path, mutex_path_override, charp, 0);
MODULE_PARM_DESC(mutex_path,
"Override ACPI mutex path used to guard access to hardware");
MODULE_AUTHOR("Eugene Shalygin <eugene.shalygin@gmail.com>");
MODULE_DESCRIPTION(
"HWMON driver for sensors accessible via ACPI EC in ASUS motherboards");
MODULE_LICENSE("GPL");
Annotation
- Immediate include surface: `linux/acpi.h`, `linux/bitops.h`, `linux/dev_printk.h`, `linux/dmi.h`, `linux/hwmon.h`, `linux/init.h`, `linux/jiffies.h`, `linux/kernel.h`.
- Detected declarations: `struct ec_sensor_info`, `struct ec_board_info`, `struct ec_sensor`, `struct lock_data`, `struct ec_sensors_data`, `enum ec_sensors`, `enum board_family`, `function lock_via_acpi_mutex`, `function unlock_acpi_mutex`, `function lock_via_global_acpi_lock`.
- Atlas domain: Driver Families / drivers/hwmon.
- Implementation status: integration implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.