mm/workingset.c
Source file repositories/reference/linux-study-clean/mm/workingset.c
File Facts
- System
- Linux kernel
- Corpus path
mm/workingset.c- Extension
.c- Size
- 28503 bytes
- Lines
- 848
- Domain
- Core OS
- Bucket
- Memory Management
- Inferred role
- Core OS: exported/initcall integration point
- Status
- integration implementation candidate
Why This File Exists
Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- 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/memcontrol.hlinux/mm_inline.hlinux/writeback.hlinux/shmem_fs.hlinux/pagemap.hlinux/atomic.hlinux/module.hlinux/swap.hlinux/dax.hlinux/fs.hlinux/mm.hswap_table.hinternal.h
Detected Declarations
function unpack_shadowfunction lru_gen_test_recentfunction lru_gen_refaultfunction lru_gen_test_recentfunction lru_gen_refaultfunction workingset_test_recentfunction workingset_refaultfunction workingset_activationfunction workingset_update_nodefunction count_shadow_nodesfunction shadow_lru_isolatefunction scan_shadow_nodesfunction workingset_initmodule init workingset_init
Annotated Snippet
module_init(workingset_init);
Annotation
- Immediate include surface: `linux/memcontrol.h`, `linux/mm_inline.h`, `linux/writeback.h`, `linux/shmem_fs.h`, `linux/pagemap.h`, `linux/atomic.h`, `linux/module.h`, `linux/swap.h`.
- Detected declarations: `function unpack_shadow`, `function lru_gen_test_recent`, `function lru_gen_refault`, `function lru_gen_test_recent`, `function lru_gen_refault`, `function workingset_test_recent`, `function workingset_refault`, `function workingset_activation`, `function workingset_update_node`, `function count_shadow_nodes`.
- Atlas domain: Core OS / Memory Management.
- 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.