include/linux/unwind_deferred_types.h
Source file repositories/reference/linux-study-clean/include/linux/unwind_deferred_types.h
File Facts
- System
- Linux kernel
- Corpus path
include/linux/unwind_deferred_types.h- Extension
.h- Size
- 1403 bytes
- Lines
- 56
- Domain
- Core OS
- Bucket
- Core Kernel Interface
- Inferred role
- Core OS: implementation source
- Status
- source 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.
- 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/types.hlinux/atomic.h
Detected Declarations
struct unwind_cachestruct unwind_task_infostruct unwind_workstruct unwind_stacktracestruct unwind_work
Annotated Snippet
struct unwind_cache {
unsigned long unwind_completed;
unsigned int nr_entries;
unsigned long entries[];
};
/*
* The unwind_task_id is a unique identifier that maps to a user space
* stacktrace. It is generated the first time a deferred user space
* stacktrace is requested after a task has entered the kerenl and
* is cleared to zero when it exits. The mapped id will be a non-zero
* number.
*
* To simplify the generation of the 64 bit number, 32 bits will be
* the CPU it was generated on, and the other 32 bits will be a per
* cpu counter that gets incremented by two every time a new identifier
* is generated. The LSB will always be set to keep the value
* from being zero.
*/
union unwind_task_id {
struct {
u32 cpu;
u32 cnt;
};
u64 id;
};
struct unwind_task_info {
atomic_long_t unwind_mask;
struct unwind_cache *cache;
struct callback_head work;
union unwind_task_id id;
};
struct unwind_work;
struct unwind_stacktrace;
typedef void (*unwind_callback_t)(struct unwind_work *work,
struct unwind_stacktrace *trace,
u64 cookie);
struct unwind_work {
struct list_head list;
unwind_callback_t func;
int bit;
};
#endif /* _LINUX_UNWIND_USER_DEFERRED_TYPES_H */
Annotation
- Immediate include surface: `linux/types.h`, `linux/atomic.h`.
- Detected declarations: `struct unwind_cache`, `struct unwind_task_info`, `struct unwind_work`, `struct unwind_stacktrace`, `struct unwind_work`.
- Atlas domain: Core OS / Core Kernel Interface.
- Implementation status: source 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.