bpf: also improve pattern matches for meta access
authorDaniel Borkmann <daniel@iogearbox.net>
Wed, 1 Nov 2017 22:58:10 +0000 (23:58 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Nov 2017 08:01:38 +0000 (17:01 +0900)
commit5beca081be9195b4316ac5f32921df0234ee8e0e
treef5c9d311d2725cef382aa6482beb6ea495d07a70
parentb06723da824af1e979eb1699623881b5f45a783c
bpf: also improve pattern matches for meta access

Follow-up to 0fd4759c5515 ("bpf: fix pattern matches for direct
packet access") to cover also the remaining data_meta/data matches
in the verifier. The matches are also refactored a bit to simplify
handling of all the cases.

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
kernel/bpf/verifier.c