From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5576AC48BE6 for ; Mon, 14 Jun 2021 09:31:37 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 38CC261357 for ; Mon, 14 Jun 2021 09:31:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232727AbhFNJdi (ORCPT ); Mon, 14 Jun 2021 05:33:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46684 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232726AbhFNJdg (ORCPT ); Mon, 14 Jun 2021 05:33:36 -0400 Received: from mail-ed1-x532.google.com (mail-ed1-x532.google.com [IPv6:2a00:1450:4864:20::532]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 40DC8C061574; Mon, 14 Jun 2021 02:31:33 -0700 (PDT) Received: by mail-ed1-x532.google.com with SMTP id s6so45566320edu.10; Mon, 14 Jun 2021 02:31:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to:cc; bh=RHIbBFwcBTvXcTVBDQuMruq6w4u/494nOVlSoFDcJQE=; b=FhTQYlhvjMYPEnaRMsU2dtL1r23iZB75KJ8RO7dBLJBpiRV8z0fcqTPDQ53cnwXCMY FXwGdAkWLAP149jwR257oHtUT9zYPNZvWw/PgCym8/u3Ar0aY6Kl9B+/YwExw/5rZxdm uKS2eTyHhtnoWweETenjiQMrJojVfndcoAtFK3ngB2zvJdKqqN8ONjUuq8zsN5LEKCyB 4cRel8UlbgfcdxRCqfOM+TXsP8DHvKQpCox+o9DxhtW8m1kVVKvgJBHefgzRgzcsrvpm L4tk+pf3UZNNkCwB3p5RmKQI8IgBCyVbGwNB1NaFfXGEDEyCXbFXkHyJQH5fKOLpxMlc HZpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=RHIbBFwcBTvXcTVBDQuMruq6w4u/494nOVlSoFDcJQE=; b=VaQnT1qYO909uivXppnsPXd0tzSOzYSorVsivJz3cxeFm8CimYHTr7F537Fn0Oz7sz +E0kPlPSfJ+AKBIB1DAlfnqIXzurP4IaW2irM8hUpFl/47ElVwLUth8sBwwYoKniKJkk 9SSTG5JRQU8tmhOi1xkl6mwoJJVj2NNiJqUnJpNeAs+1eAA/LknsH0X91PuWgzBDGgT8 XKnB4jNXL0xmPIiSlyLkUsNT6y7YjABdgchWIlnAV5V1OI1Qj34dcEVPEUtG95vgjJuq OknD9O4mLlJ+lFspR/lmuvs9uAZ2KlZ4Exl9albv4N/+YFapto4vq/vUi/fvgREnCaSd HWLw== X-Gm-Message-State: AOAM532DapXn79BdOyj+EqVIyyN3wz8bLjkVXi6MH9i700rCO4+LW8nw XYCSRrRb++gh6n84nucZllXQVV2Ofdtgxpubc5Q= X-Google-Smtp-Source: ABdhPJzD9mBruPTHgKTDgN6DxTN8Wm1w9WPUoO8Z8zHhUZiXrFcia2w8hsEMKLHFKCBF8SyirrJTADC1Q54eEr5GgN0= X-Received: by 2002:a50:fe18:: with SMTP id f24mr16309152edt.271.1623663091826; Mon, 14 Jun 2021 02:31:31 -0700 (PDT) MIME-Version: 1.0 From: Yaniv Agman Date: Mon, 14 Jun 2021 12:32:07 +0300 Message-ID: Subject: Re: [PATCH bpf-next 0/3] Fixes for TC-BPF series To: memxor@gmail.com Cc: andrii@kernel.org, ast@kernel.org, bpf@vger.kernel.org, daniel@iogearbox.net, netdev@vger.kernel.org, toke@redhat.com Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: bpf@vger.kernel.org Hi Kartikeya, I recently started experimenting with the new tc-bpf API (which is great, many thanks!) and I wanted to share a potential problem I found. I'm using this "Fixes for TC-BPF series" thread to write about it, but it is not directly related to this patch set. According to the API summary given in https://lore.kernel.org/bpf/20210512103451.989420-3-memxor@gmail.com/, "It is advised that if the qdisc is operated on by many programs, then the program at least check that there are no other existing filters before deleting the clsact qdisc." In the example given, one should: /* set opts as NULL, as we're not really interested in * getting any info for a particular filter, but just * detecting its presence. */ r = bpf_tc_query(&hook, NULL); However, following in this summary, where bpf_tc_query is described, it is written that the opts argument cannot be NULL. And indeed, when I tried to use the example above, an error (EINVAL) was returned (as expected?) Am I missing something? Yaniv