drivers/virt/nitro_enclaves/ne_pci_dev.c
Source file repositories/reference/linux-study-clean/drivers/virt/nitro_enclaves/ne_pci_dev.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/virt/nitro_enclaves/ne_pci_dev.c- Extension
.c- Size
- 15795 bytes
- Lines
- 627
- Domain
- Driver Families
- Bucket
- drivers/virt
- 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.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- 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/delay.hlinux/device.hlinux/list.hlinux/module.hlinux/mutex.hlinux/nitro_enclaves.hlinux/pci.hlinux/types.hlinux/wait.hne_misc_dev.hne_pci_dev.h
Detected Declarations
function ne_submit_requestfunction ne_retrieve_replyfunction ne_wait_for_replyfunction ne_do_requestfunction ne_reply_handlerfunction ne_event_work_handlerfunction enclavefunction ne_event_handlerfunction ne_setup_msixfunction ne_teardown_msixfunction ne_pci_dev_enablefunction ne_pci_dev_disablefunction ne_pci_probefunction ne_pci_removefunction ne_pci_shutdown
Annotated Snippet
struct pci_driver ne_pci_driver = {
.name = "nitro_enclaves",
.id_table = ne_pci_ids,
.probe = ne_pci_probe,
.remove = ne_pci_remove,
.shutdown = ne_pci_shutdown,
};
Annotation
- Immediate include surface: `linux/delay.h`, `linux/device.h`, `linux/list.h`, `linux/module.h`, `linux/mutex.h`, `linux/nitro_enclaves.h`, `linux/pci.h`, `linux/types.h`.
- Detected declarations: `function ne_submit_request`, `function ne_retrieve_reply`, `function ne_wait_for_reply`, `function ne_do_request`, `function ne_reply_handler`, `function ne_event_work_handler`, `function enclave`, `function ne_event_handler`, `function ne_setup_msix`, `function ne_teardown_msix`.
- Atlas domain: Driver Families / drivers/virt.
- Implementation status: pattern implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
- 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.