diff options
author | David S. Miller <davem@davemloft.net> | 2017-05-25 13:44:29 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-05-25 13:44:29 -0400 |
commit | ae08ea976862dcd058af89fcddc2ef4790b4a2bd (patch) | |
tree | 0dc8e1e5384df1cdadfb109bbd191eafe24a594d /kernel/bpf/stackmap.c | |
parent | 5990baaa6d7b437dfcf58b7021ca56b1d6b35869 (diff) | |
parent | 614d0d77b49a9b131e58b77473698ab5b2c525b7 (diff) |
Merge branch 'bpf-fixes'
Daniel Borkmann says:
====================
Various BPF fixes
Follow-up to fix incorrect pruning when alignment tracking is
in use and to properly clear regs after call to not leave stale
data behind, also a fix that adds bpf_clone_redirect to the
bpf_helper_changes_pkt_data helper and exposes correct map_flags
for lpm map into fdinfo. For details, please see individual
patches.
v1 -> v2:
- Reworked first patch so that env->strict_alignment is the
final indicator on whether we have to deal with strict
alignment rather than having CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS
checks on various locations, so only checking env->strict_alignment
is sufficient after that. Thanks for spotting, Dave!
- Added patch 3 and 4.
- Rest as is.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'kernel/bpf/stackmap.c')
-rw-r--r-- | kernel/bpf/stackmap.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/bpf/stackmap.c b/kernel/bpf/stackmap.c index 4dfd6f2ec2f9..31147d730abf 100644 --- a/kernel/bpf/stackmap.c +++ b/kernel/bpf/stackmap.c | |||
@@ -88,6 +88,7 @@ static struct bpf_map *stack_map_alloc(union bpf_attr *attr) | |||
88 | smap->map.key_size = attr->key_size; | 88 | smap->map.key_size = attr->key_size; |
89 | smap->map.value_size = value_size; | 89 | smap->map.value_size = value_size; |
90 | smap->map.max_entries = attr->max_entries; | 90 | smap->map.max_entries = attr->max_entries; |
91 | smap->map.map_flags = attr->map_flags; | ||
91 | smap->n_buckets = n_buckets; | 92 | smap->n_buckets = n_buckets; |
92 | smap->map.pages = round_up(cost, PAGE_SIZE) >> PAGE_SHIFT; | 93 | smap->map.pages = round_up(cost, PAGE_SIZE) >> PAGE_SHIFT; |
93 | 94 | ||