Thu, Dec 14, 2017 at 08:22:43PM CET, jakub.kicin...@netronome.com wrote: >On Wed, 13 Dec 2017 16:10:33 +0100, Jiri Pirko wrote: >> diff --git a/net/sched/cls_bpf.c b/net/sched/cls_bpf.c >> index 69d7e9a..9cf61e7 100644 >> --- a/net/sched/cls_bpf.c >> +++ b/net/sched/cls_bpf.c >> @@ -170,8 +170,10 @@ static int cls_bpf_offload_cmd(struct tcf_proto *tp, >> struct cls_bpf_prog *prog, >> cls_bpf_offload_cmd(tp, prog, TC_CLSBPF_DESTROY); >> return err; >> } else if (err > 0) { >> - prog->gen_flags |= TCA_CLS_FLAGS_IN_HW; >> + tcf_block_offload_inc(block, &prog->gen_flags); >> } >> + } else { >> + tcf_block_offload_dec(block, &prog->gen_flags); >> } >> >> if (addorrep && skip_sw && !(prog->gen_flags & TCA_CLS_FLAGS_IN_HW)) > >The in_hw reporting also seems broken. > >tools/testing/selftests/bpf/test_offload.py catches this.
Will check it. Thanks!