drivers/counter/intel-qep.c
Source file repositories/reference/linux-study-clean/drivers/counter/intel-qep.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/counter/intel-qep.c- Extension
.c- Size
- 13182 bytes
- Lines
- 523
- Domain
- Driver Families
- Bucket
- drivers/counter
- Inferred role
- Driver Families: operation-table or driver-model contract
- Status
- pattern 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.
- Defines an operation table; this is where Linux turns generic core objects into subsystem-specific behavior.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/counter.hlinux/kernel.hlinux/module.hlinux/mutex.hlinux/pci.hlinux/pm_runtime.h
Detected Declarations
struct intel_qepfunction intel_qep_readlfunction intel_qep_writelfunction intel_qep_initfunction intel_qep_count_readfunction intel_qep_function_readfunction intel_qep_action_readfunction intel_qep_ceiling_readfunction intel_qep_ceiling_writefunction intel_qep_enable_readfunction intel_qep_enable_writefunction intel_qep_spike_filter_ns_readfunction intel_qep_spike_filter_ns_writefunction intel_qep_preset_enable_readfunction intel_qep_preset_enable_writefunction intel_qep_probefunction intel_qep_removefunction intel_qep_suspendfunction intel_qep_resume
Annotated Snippet
static struct pci_driver intel_qep_driver = {
.name = "intel-qep",
.id_table = intel_qep_id_table,
.probe = intel_qep_probe,
.remove = intel_qep_remove,
.driver = {
.pm = &intel_qep_pm_ops,
}
};
module_pci_driver(intel_qep_driver);
MODULE_AUTHOR("Felipe Balbi (Intel)");
MODULE_AUTHOR("Jarkko Nikula <jarkko.nikula@linux.intel.com>");
MODULE_AUTHOR("Raymond Tan <raymond.tan@intel.com>");
MODULE_LICENSE("GPL");
MODULE_DESCRIPTION("Intel Quadrature Encoder Peripheral driver");
MODULE_IMPORT_NS("COUNTER");
Annotation
- Immediate include surface: `linux/counter.h`, `linux/kernel.h`, `linux/module.h`, `linux/mutex.h`, `linux/pci.h`, `linux/pm_runtime.h`.
- Detected declarations: `struct intel_qep`, `function intel_qep_readl`, `function intel_qep_writel`, `function intel_qep_init`, `function intel_qep_count_read`, `function intel_qep_function_read`, `function intel_qep_action_read`, `function intel_qep_ceiling_read`, `function intel_qep_ceiling_write`, `function intel_qep_enable_read`.
- Atlas domain: Driver Families / drivers/counter.
- Implementation status: pattern implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
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.