drivers/usb/host/xhci-pci.c
Source file repositories/reference/linux-study-clean/drivers/usb/host/xhci-pci.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/usb/host/xhci-pci.c- Extension
.c- Size
- 31090 bytes
- Lines
- 987
- Domain
- Driver Families
- Bucket
- drivers/usb
- 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.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/pci.hlinux/slab.hlinux/module.hlinux/acpi.hlinux/reset.hlinux/suspend.hxhci.hxhci-trace.hxhci-pci.h
Detected Declarations
function suspend_commonfunction xhci_cleanup_msixfunction xhci_try_enable_msifunction xhci_pci_runfunction xhci_pci_stopfunction xhci_pci_reinitfunction xhci_pci_quirksfunction xhci_pme_acpi_rtd3_enablefunction xhci_find_lpm_incapable_portsfunction xhci_pme_acpi_rtd3_enablefunction xhci_pci_update_hub_devicefunction functionfunction xhci_pci_probefunction xhci_pci_removefunction xhci_ssic_port_unused_quirkfunction xhci_pme_quirkfunction xhci_sparse_control_quirkfunction xhci_pci_suspendfunction xhci_pci_resumefunction xhci_pci_poweroff_latefunction xhci_pci_shutdownfunction xhci_pci_initfunction xhci_pci_exitmodule init xhci_pci_init
Annotated Snippet
static struct pci_driver xhci_pci_driver = {
.name = hcd_name,
.id_table = pci_ids,
.probe = xhci_pci_probe,
.remove = xhci_pci_remove,
/* suspend and resume implemented later */
.shutdown = usb_hcd_pci_shutdown,
.driver = {
.pm = pm_ptr(&usb_hcd_pci_pm_ops),
},
};
static int __init xhci_pci_init(void)
{
xhci_init_driver(&xhci_pci_hc_driver, &xhci_pci_overrides);
xhci_pci_hc_driver.pci_suspend = pm_ptr(xhci_pci_suspend);
xhci_pci_hc_driver.pci_resume = pm_ptr(xhci_pci_resume);
xhci_pci_hc_driver.pci_poweroff_late = pm_ptr(xhci_pci_poweroff_late);
xhci_pci_hc_driver.shutdown = pm_ptr(xhci_pci_shutdown);
xhci_pci_hc_driver.stop = xhci_pci_stop;
return pci_register_driver(&xhci_pci_driver);
}
module_init(xhci_pci_init);
static void __exit xhci_pci_exit(void)
{
pci_unregister_driver(&xhci_pci_driver);
}
module_exit(xhci_pci_exit);
MODULE_DESCRIPTION("xHCI PCI Host Controller Driver");
MODULE_LICENSE("GPL");
Annotation
- Immediate include surface: `linux/pci.h`, `linux/slab.h`, `linux/module.h`, `linux/acpi.h`, `linux/reset.h`, `linux/suspend.h`, `xhci.h`, `xhci-trace.h`.
- Detected declarations: `function suspend_common`, `function xhci_cleanup_msix`, `function xhci_try_enable_msi`, `function xhci_pci_run`, `function xhci_pci_stop`, `function xhci_pci_reinit`, `function xhci_pci_quirks`, `function xhci_pme_acpi_rtd3_enable`, `function xhci_find_lpm_incapable_ports`, `function xhci_pme_acpi_rtd3_enable`.
- Atlas domain: Driver Families / drivers/usb.
- Implementation status: pattern implementation candidate.
- IRQ or DMA behavior appears here, which is relevant to the selected PCIe/NVMe device path.
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.