tools/perf/ui/keysyms.c
Source file repositories/reference/linux-study-clean/tools/perf/ui/keysyms.c
File Facts
- System
- Linux kernel
- Corpus path
tools/perf/ui/keysyms.c- Extension
.c- Size
- 1194 bytes
- Lines
- 45
- Domain
- Support Tooling And Documentation
- Bucket
- tools
- Inferred role
- Support Tooling And Documentation: implementation source
- Status
- source 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.
Dependency Surface
keysyms.hlinux/ctype.hlinux/kernel.h
Detected Declarations
- No top-level syscall, struct, function, initcall, or export declaration detected by the generator.
Annotated Snippet
switch (key) {
case K_DOWN: name = "Down"; break;
case K_END: name = "End"; break;
case K_ENTER: name = "Enter"; break;
case K_ESC: name = "ESC"; break;
case K_F1: name = "F1"; break;
case K_HOME: name = "Home"; break;
case K_LEFT: name = "Left"; break;
case K_PGDN: name = "PgDown"; break;
case K_PGUP: name = "PgUp"; break;
case K_RIGHT: name = "Right"; break;
case K_TAB: name = "Tab"; break;
case K_UNTAB: name = "Untab"; break;
case K_UP: name = "Up"; break;
case K_BKSPC: name = "Backspace"; break;
case K_DEL: name = "Del"; break;
default:
if (key >= SL_KEY_F(1) && key <= SL_KEY_F(63))
scnprintf(bf, size, "F%d", key - SL_KEY_F(0));
else
scnprintf(bf, size, "Unknown (%d)", key);
}
if (name)
scnprintf(bf, size, "%s", name);
}
return bf;
}
Annotation
- Immediate include surface: `keysyms.h`, `linux/ctype.h`, `linux/kernel.h`.
- Atlas domain: Support Tooling And Documentation / tools.
- Implementation status: source 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.