drivers/pci/hotplug/rpaphp_slot.c
Source file repositories/reference/linux-study-clean/drivers/pci/hotplug/rpaphp_slot.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/pci/hotplug/rpaphp_slot.c- Extension
.c- Size
- 2687 bytes
- Lines
- 118
- Domain
- Representative Device Path
- Bucket
- PCIe NVMe Storage Path
- Inferred role
- Representative Device Path: exported/initcall integration point
- Status
- integration implementation candidate
Why This File Exists
Part of the selected hardware vertical slice: PCI discovery, driver binding, NVMe queues, block requests, DMA, interrupts, and completion.
- Part of the selected hardware vertical slice: PCI discovery, driver binding, NVMe queues, block requests, DMA, interrupts, and completion.
- 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/kernel.hlinux/module.hlinux/sysfs.hlinux/of.hlinux/pci.hlinux/string.hlinux/slab.hasm/rtas.hrpaphp.h
Detected Declarations
function Copyrightfunction is_registeredfunction list_for_each_entryfunction rpaphp_deregister_slotfunction rpaphp_register_slotfunction for_each_child_of_node_scopedexport rpaphp_deregister_slot
Annotated Snippet
if (my_index == slot->index) {
slotno = PCI_SLOT(PCI_DN(child)->devfn);
break;
}
}
retval = pci_hp_register(php_slot, slot->bus, slotno, slot->name);
if (retval) {
err("pci_hp_register failed with error %d\n", retval);
return retval;
}
/* add slot to our internal list */
list_add(&slot->rpaphp_slot_list, &rpaphp_slot_head);
info("Slot [%s] registered\n", slot->name);
return 0;
}
Annotation
- Immediate include surface: `linux/kernel.h`, `linux/module.h`, `linux/sysfs.h`, `linux/of.h`, `linux/pci.h`, `linux/string.h`, `linux/slab.h`, `asm/rtas.h`.
- Detected declarations: `function Copyright`, `function is_registered`, `function list_for_each_entry`, `function rpaphp_deregister_slot`, `function rpaphp_register_slot`, `function for_each_child_of_node_scoped`, `export rpaphp_deregister_slot`.
- Atlas domain: Representative Device Path / PCIe NVMe Storage Path.
- 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.