tools/testing/selftests/livepatch/test_modules/test_klp_syscall.c
Source file repositories/reference/linux-study-clean/tools/testing/selftests/livepatch/test_modules/test_klp_syscall.c
File Facts
- System
- Linux kernel
- Corpus path
tools/testing/selftests/livepatch/test_modules/test_klp_syscall.c- Extension
.c- Size
- 3016 bytes
- Lines
- 132
- Domain
- Support Tooling And Documentation
- Bucket
- tools
- Inferred role
- Support Tooling And Documentation: syscall or user/kernel boundary
- Status
- core implementation candidate
Why This File Exists
Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Defines or participates in a user/kernel boundary; inspect argument validation, copy_from_user/copy_to_user, credentials, and dispatch target.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/module.hlinux/kernel.hlinux/sched.hlinux/slab.hlinux/livepatch.h
Detected Declarations
function npids_showfunction lp_sys_getpidfunction livepatch_initfunction livepatch_exitmodule init livepatch_init
Annotated Snippet
module_init(livepatch_init);
module_exit(livepatch_exit);
MODULE_LICENSE("GPL");
MODULE_INFO(livepatch, "Y");
MODULE_AUTHOR("Libor Pechacek <lpechacek@suse.cz>");
MODULE_AUTHOR("Nicolai Stange <nstange@suse.de>");
MODULE_AUTHOR("Marcos Paulo de Souza <mpdesouza@suse.com>");
MODULE_DESCRIPTION("Livepatch test: syscall transition");
Annotation
- Immediate include surface: `linux/module.h`, `linux/kernel.h`, `linux/sched.h`, `linux/slab.h`, `linux/livepatch.h`.
- Detected declarations: `function npids_show`, `function lp_sys_getpid`, `function livepatch_init`, `function livepatch_exit`, `module init livepatch_init`.
- Atlas domain: Support Tooling And Documentation / tools.
- Implementation status: core 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.