1 // SPDX-License-Identifier: GPL-2.0
2 // Copyright (c) 2020 Cloudflare
4 #include <bpf/bpf_helpers.h>
7 __uint(type
, BPF_MAP_TYPE_SOCKMAP
);
8 __uint(max_entries
, 1);
14 int bpf_sockmap(struct bpf_sock_ops
*skops
)
19 bpf_map_update_elem(&map
, &key
, skops
->sk
, 0);
23 char _license
[] SEC("license") = "GPL";