From 6e7da522869a7ff5f4f2880390723f996a526300 Mon Sep 17 00:00:00 2001 From: Eugene Syromyatnikov Date: Sun, 19 Aug 2018 15:46:26 +0200 Subject: [PATCH] xlat: add BPF_PROG_TYPE_SK_REUSEPORT to bpf_prog_types.in * xlat/bpf_prog_types.in (BPF_PROG_TYPE_SK_REUSEPORT): New constant, introduced by Linux commit v4.19-rc1~140^2~24^2~2^2~5. * tests/bpf.c: Update expected output. --- tests/bpf.c | 8 ++++---- xlat/bpf_prog_types.in | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/bpf.c b/tests/bpf.c index 55e0ff67..44aac051 100644 --- a/tests/bpf.c +++ b/tests/bpf.c @@ -593,7 +593,7 @@ static struct bpf_attr_check BPF_PROG_LOAD_checks[] = { }, { /* 1 */ .data = { .BPF_PROG_LOAD_data = { - .prog_type = 20, + .prog_type = 21, .insn_cnt = 0xbadc0ded, .insns = 0, .license = 0, @@ -604,7 +604,7 @@ static struct bpf_attr_check BPF_PROG_LOAD_checks[] = { .prog_flags = 0, } }, .size = offsetofend(struct BPF_PROG_LOAD_struct, prog_flags), - .str = "prog_type=0x14 /* BPF_PROG_TYPE_??? */" + .str = "prog_type=0x15 /* BPF_PROG_TYPE_??? */" ", insn_cnt=3134983661, insns=NULL, license=NULL" ", log_level=42, log_size=3141592653, log_buf=NULL" ", kern_version=KERNEL_VERSION(51966, 240, 13)" @@ -612,7 +612,7 @@ static struct bpf_attr_check BPF_PROG_LOAD_checks[] = { }, { /* 2 */ .data = { .BPF_PROG_LOAD_data = { - .prog_type = 19, + .prog_type = 20, .insn_cnt = 0xbadc0ded, .insns = 0xffffffff00000000, .license = 0xffffffff00000000, @@ -624,7 +624,7 @@ static struct bpf_attr_check BPF_PROG_LOAD_checks[] = { .prog_name = "fedcba987654321", } }, .size = offsetofend(struct BPF_PROG_LOAD_struct, prog_name), - .str = "prog_type=BPF_PROG_TYPE_LIRC_MODE2" + .str = "prog_type=BPF_PROG_TYPE_SK_REUSEPORT" ", insn_cnt=3134983661" ", insns=" BIG_ADDR("0xffffffff00000000", "NULL") ", license=" BIG_ADDR("0xffffffff00000000", "NULL") diff --git a/xlat/bpf_prog_types.in b/xlat/bpf_prog_types.in index 77b864ed..d32ca7fa 100644 --- a/xlat/bpf_prog_types.in +++ b/xlat/bpf_prog_types.in @@ -19,3 +19,4 @@ BPF_PROG_TYPE_SK_MSG 16 BPF_PROG_TYPE_RAW_TRACEPOINT 17 BPF_PROG_TYPE_LWT_SEG6LOCAL 18 BPF_PROG_TYPE_LIRC_MODE2 19 +BPF_PROG_TYPE_SK_REUSEPORT 20 -- 2.40.0