eBPF for Windows
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
bpf_helpers_platform.h
Go to the documentation of this file.
1// Copyright (c) eBPF for Windows contributors
2// SPDX-License-Identifier: MIT
3#pragma once
4
10#include <stdbool.h>
11#include <stdint.h>
12
13// For eBPF programs, struct bpf_map means struct _ebpf_map_definition_in_file,
14// since they use inner_map_idx and pass pointers to such structures to the various
15// map APIs.
16#define bpf_map _ebpf_map_definition_in_file
17
18#if !defined(_MSC_VER)
19const bool __ebpf_for_windows_tag __attribute__((section(".ebpf_for_windows"))) = true;
20#endif
21
22// Type aliases used by libbpf headers.
23typedef int32_t __s32;
24typedef int64_t __s64;
25typedef uint16_t __be16;
26typedef uint16_t __u16;
27typedef uint32_t __be32;
28typedef uint32_t __u32;
29typedef uint32_t __wsum;
30typedef uint64_t __u64;
uint32_t __be32
Definition bpf_helpers_platform.h:27
const bool __ebpf_for_windows_tag __attribute__((section(".ebpf_for_windows")))
int32_t __s32
Definition bpf_helpers_platform.h:23
uint32_t __u32
Definition bpf_helpers_platform.h:28
int64_t __s64
Definition bpf_helpers_platform.h:24
uint16_t __be16
Definition bpf_helpers_platform.h:25
uint16_t __u16
Definition bpf_helpers_platform.h:26
uint64_t __u64
Definition bpf_helpers_platform.h:30
uint32_t __wsum
Definition bpf_helpers_platform.h:29