tools/testing/selftests/bpf/task_local_storage_helpers.h

Source file repositories/reference/linux-study-clean/tools/testing/selftests/bpf/task_local_storage_helpers.h

File Facts

System
Linux kernel
Corpus path
tools/testing/selftests/bpf/task_local_storage_helpers.h
Extension
.h
Size
425 bytes
Lines
23
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.

Dependency Surface

Detected Declarations

Annotated Snippet

#ifndef __TASK_LOCAL_STORAGE_HELPER_H
#define __TASK_LOCAL_STORAGE_HELPER_H

#include <unistd.h>
#include <sys/syscall.h>
#include <sys/types.h>

#ifndef __NR_pidfd_open
#ifdef __alpha__
#define __NR_pidfd_open 544
#else
#define __NR_pidfd_open 434
#endif
#endif

static inline int sys_pidfd_open(pid_t pid, unsigned int flags)
{
	return syscall(__NR_pidfd_open, pid, flags);
}

#endif

Annotation

Implementation Notes