drivers/powercap/arm_scmi_powercap.c
Source file repositories/reference/linux-study-clean/drivers/powercap/arm_scmi_powercap.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/powercap/arm_scmi_powercap.c- Extension
.c- Size
- 14990 bytes
- Lines
- 551
- Domain
- Driver Families
- Bucket
- drivers/powercap
- 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/device.hlinux/math.hlinux/limits.hlinux/list.hlinux/module.hlinux/powercap.hlinux/scmi_protocol.hlinux/slab.h
Detected Declarations
struct scmi_powercap_zonestruct scmi_powercap_rootfunction scmi_powercap_zone_releasefunction scmi_powercap_get_max_power_range_uwfunction scmi_powercap_get_power_uwfunction scmi_powercap_zone_enable_setfunction scmi_powercap_zone_enable_getfunction scmi_powercap_normalize_capfunction scmi_powercap_set_power_limit_uwfunction scmi_powercap_get_power_limit_uwfunction scmi_powercap_normalize_timefunction scmi_powercap_set_time_window_usfunction scmi_powercap_get_time_window_usfunction scmi_powercap_get_max_power_uwfunction scmi_powercap_get_min_power_uwfunction scmi_powercap_get_max_time_window_usfunction scmi_powercap_get_min_time_window_usfunction scmi_powercap_unregister_all_zonesfunction scmi_powercap_get_zone_heightfunction scmi_powercap_get_parent_zonefunction scmi_powercap_register_zonefunction scmi_zones_registerfunction scmi_powercap_probefunction scmi_powercap_removefunction scmi_powercap_initfunction scmi_powercap_exitmodule init scmi_powercap_init
Annotated Snippet
module_init(scmi_powercap_init);
static void __exit scmi_powercap_exit(void)
{
scmi_unregister(&scmi_powercap_driver);
powercap_unregister_control_type(scmi_top_pcntrl);
}
module_exit(scmi_powercap_exit);
MODULE_AUTHOR("Cristian Marussi <cristian.marussi@arm.com>");
MODULE_DESCRIPTION("ARM SCMI Powercap driver");
MODULE_LICENSE("GPL");
Annotation
- Immediate include surface: `linux/device.h`, `linux/math.h`, `linux/limits.h`, `linux/list.h`, `linux/module.h`, `linux/powercap.h`, `linux/scmi_protocol.h`, `linux/slab.h`.
- Detected declarations: `struct scmi_powercap_zone`, `struct scmi_powercap_root`, `function scmi_powercap_zone_release`, `function scmi_powercap_get_max_power_range_uw`, `function scmi_powercap_get_power_uw`, `function scmi_powercap_zone_enable_set`, `function scmi_powercap_zone_enable_get`, `function scmi_powercap_normalize_cap`, `function scmi_powercap_set_power_limit_uw`, `function scmi_powercap_get_power_limit_uw`.
- Atlas domain: Driver Families / drivers/powercap.
- 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.