drivers/vfio/pci/ism/main.c
Source file repositories/reference/linux-study-clean/drivers/vfio/pci/ism/main.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/vfio/pci/ism/main.c- Extension
.c- Size
- 11126 bytes
- Lines
- 409
- Domain
- Driver Families
- Bucket
- drivers/vfio
- 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 user memory; correctness depends on fault-safe copying and privilege boundary handling.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/slab.h../vfio_pci_priv.h
Detected Declarations
struct ism_vfio_pci_core_devicefunction ism_vfio_pci_open_devicefunction ism_vfio_pci_do_io_rfunction ism_vfio_pci_do_io_wfunction ism_vfio_pci_bar_rwfunction ism_vfio_pci_config_rwfunction ism_vfio_pci_rwfunction ism_vfio_pci_readfunction ism_vfio_pci_writefunction ism_vfio_pci_ioctl_get_region_infofunction ism_vfio_pci_init_devfunction kmem_cache_createfunction ism_vfio_pci_release_devfunction ism_vfio_pci_probefunction ism_vfio_pci_remove
Annotated Snippet
static struct pci_driver ism_vfio_pci_driver = {
.name = KBUILD_MODNAME,
.id_table = ism_device_table,
.probe = ism_vfio_pci_probe,
.remove = ism_vfio_pci_remove,
.err_handler = &vfio_pci_core_err_handlers,
.driver_managed_dma = true,
};
module_pci_driver(ism_vfio_pci_driver);
MODULE_LICENSE("GPL");
MODULE_DESCRIPTION("vfio-pci variant driver for the IBM Internal Shared Memory (ISM) device");
MODULE_AUTHOR("IBM Corporation");
Annotation
- Immediate include surface: `linux/slab.h`, `../vfio_pci_priv.h`.
- Detected declarations: `struct ism_vfio_pci_core_device`, `function ism_vfio_pci_open_device`, `function ism_vfio_pci_do_io_r`, `function ism_vfio_pci_do_io_w`, `function ism_vfio_pci_bar_rw`, `function ism_vfio_pci_config_rw`, `function ism_vfio_pci_rw`, `function ism_vfio_pci_read`, `function ism_vfio_pci_write`, `function ism_vfio_pci_ioctl_get_region_info`.
- Atlas domain: Driver Families / drivers/vfio.
- Implementation status: pattern implementation candidate.
- This snippet crosses the user/kernel memory boundary; validate fault handling and access checks before translating the pattern.
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.