diff options
| author | Alexei Starovoitov <[email protected]> | 2016-03-08 05:57:20 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2016-03-08 20:28:32 +0000 |
| commit | 89b976070190eb9dd14943c0d6ca4b7209f61405 (patch) | |
| tree | 36762c9aedfdf442e89148c0079e6cc1cbebbd57 /samples/bpf/bpf_load.c | |
| parent | samples/bpf: move ksym_search() into library (diff) | |
| download | kernel-89b976070190eb9dd14943c0d6ca4b7209f61405.tar.gz kernel-89b976070190eb9dd14943c0d6ca4b7209f61405.zip | |
samples/bpf: add map_flags to bpf loader
note old loader is compatible with new kernel.
map_flags are optional
Signed-off-by: Alexei Starovoitov <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'samples/bpf/bpf_load.c')
| -rw-r--r-- | samples/bpf/bpf_load.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/samples/bpf/bpf_load.c b/samples/bpf/bpf_load.c index d16864293c00..58f86bd11b3d 100644 --- a/samples/bpf/bpf_load.c +++ b/samples/bpf/bpf_load.c @@ -157,7 +157,8 @@ static int load_maps(struct bpf_map_def *maps, int len) map_fd[i] = bpf_create_map(maps[i].type, maps[i].key_size, maps[i].value_size, - maps[i].max_entries); + maps[i].max_entries, + maps[i].map_flags); if (map_fd[i] < 0) { printf("failed to create a map: %d %s\n", errno, strerror(errno)); |
