Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec
[linux-2.6-block.git] / net / core / sock_map.c
index 2d213c4011dbd03b972d52afd307832190197bab..81d4b4756a02d4e47cb8d5db39fb16a1cccc1e72 100644 (file)
@@ -793,7 +793,7 @@ static const struct bpf_iter_seq_info sock_map_iter_seq_info = {
        .seq_priv_size          = sizeof(struct sock_map_seq_info),
 };
 
-static int sock_map_btf_id;
+BTF_ID_LIST_SINGLE(sock_map_btf_ids, struct, bpf_stab)
 const struct bpf_map_ops sock_map_ops = {
        .map_meta_equal         = bpf_map_meta_equal,
        .map_alloc              = sock_map_alloc,
@@ -805,8 +805,7 @@ const struct bpf_map_ops sock_map_ops = {
        .map_lookup_elem        = sock_map_lookup,
        .map_release_uref       = sock_map_release_progs,
        .map_check_btf          = map_check_no_btf,
-       .map_btf_name           = "bpf_stab",
-       .map_btf_id             = &sock_map_btf_id,
+       .map_btf_id             = &sock_map_btf_ids[0],
        .iter_seq_info          = &sock_map_iter_seq_info,
 };
 
@@ -1385,7 +1384,7 @@ static const struct bpf_iter_seq_info sock_hash_iter_seq_info = {
        .seq_priv_size          = sizeof(struct sock_hash_seq_info),
 };
 
-static int sock_hash_map_btf_id;
+BTF_ID_LIST_SINGLE(sock_hash_map_btf_ids, struct, bpf_shtab)
 const struct bpf_map_ops sock_hash_ops = {
        .map_meta_equal         = bpf_map_meta_equal,
        .map_alloc              = sock_hash_alloc,
@@ -1397,8 +1396,7 @@ const struct bpf_map_ops sock_hash_ops = {
        .map_lookup_elem_sys_only = sock_hash_lookup_sys,
        .map_release_uref       = sock_hash_release_progs,
        .map_check_btf          = map_check_no_btf,
-       .map_btf_name           = "bpf_shtab",
-       .map_btf_id             = &sock_hash_map_btf_id,
+       .map_btf_id             = &sock_hash_map_btf_ids[0],
        .iter_seq_info          = &sock_hash_iter_seq_info,
 };