]> Git Repo - linux.git/commitdiff
bpf: Reset data_meta before running programs attached to devmap entry
authorDavid Ahern <[email protected]>
Mon, 8 Jun 2020 15:17:23 +0000 (09:17 -0600)
committerAlexei Starovoitov <[email protected]>
Tue, 9 Jun 2020 18:19:35 +0000 (11:19 -0700)
This is a new context that does not handle metadata at the moment, so
mark data_meta invalid.

Fixes: fbee97feed9b ("bpf: Add support to attach bpf program to a devmap entry")
Signed-off-by: David Ahern <[email protected]>
Signed-off-by: Alexei Starovoitov <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
kernel/bpf/devmap.c

index 854b09beb16bb0f0e8bc2a0b4e221de388bce0a1..bfdff2faf5cb4323a8f74cc45100fcd75cf81eb8 100644 (file)
@@ -479,6 +479,7 @@ static struct xdp_buff *dev_map_run_prog(struct net_device *dev,
        struct xdp_txq_info txq = { .dev = dev };
        u32 act;
 
+       xdp_set_data_meta_invalid(xdp);
        xdp->txq = &txq;
 
        act = bpf_prog_run_xdp(xdp_prog, xdp);
This page took 0.056588 seconds and 4 git commands to generate.