drivers/nvdimm/core.c
Source file repositories/reference/linux-study-clean/drivers/nvdimm/core.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/nvdimm/core.c- Extension
.c- Size
- 12689 bytes
- Lines
- 547
- Domain
- Driver Families
- Bucket
- drivers/nvdimm
- Inferred role
- Driver Families: exported/initcall integration point
- Status
- integration 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.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- 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/libnvdimm.hlinux/suspend.hlinux/export.hlinux/module.hlinux/blkdev.hlinux/device.hlinux/ctype.hlinux/ndctl.hlinux/mutex.hlinux/slab.hlinux/io.hnd-core.hnd.h
Detected Declarations
struct nvdimm_mapfunction nvdimm_bus_lockfunction nvdimm_bus_unlockfunction is_nvdimm_bus_lockedfunction nvdimm_map_releasefunction nvdimm_map_putfunction scoped_guardfunction nd_fletcher64function nd_uuid_storefunction nd_size_select_showfunction nd_size_select_storefunction commands_showfunction provider_showfunction flush_namespacesfunction flush_regions_dimmsfunction wait_probe_showfunction capability_showfunction activate_showfunction exec_firmware_activatefunction activate_storefunction nvdimm_bus_firmware_visiblefunction nvdimm_bus_add_badrangefunction libnvdimm_initfunction libnvdimm_exitmodule init libnvdimm_initexport nvdimm_bus_lockexport nvdimm_bus_unlockexport is_nvdimm_bus_lockedexport devm_nvdimm_memremapexport nd_fletcher64export to_nd_descexport to_nvdimm_bus_devexport nvdimm_bus_add_badrange
Annotated Snippet
subsys_initcall(libnvdimm_init);
module_exit(libnvdimm_exit);
Annotation
- Immediate include surface: `linux/libnvdimm.h`, `linux/suspend.h`, `linux/export.h`, `linux/module.h`, `linux/blkdev.h`, `linux/device.h`, `linux/ctype.h`, `linux/ndctl.h`.
- Detected declarations: `struct nvdimm_map`, `function nvdimm_bus_lock`, `function nvdimm_bus_unlock`, `function is_nvdimm_bus_locked`, `function nvdimm_map_release`, `function nvdimm_map_put`, `function scoped_guard`, `function nd_fletcher64`, `function nd_uuid_store`, `function nd_size_select_show`.
- Atlas domain: Driver Families / drivers/nvdimm.
- Implementation status: integration 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.