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.7 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 CC2C0C18E57 for ; Thu, 3 Dec 2020 14:46:31 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2CD6E22A7F for ; Thu, 3 Dec 2020 14:41:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389288AbgLCOlF (ORCPT ); Thu, 3 Dec 2020 09:41:05 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41850 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387666AbgLCOlE (ORCPT ); Thu, 3 Dec 2020 09:41:04 -0500 Received: from mail-io1-xd41.google.com (mail-io1-xd41.google.com [IPv6:2607:f8b0:4864:20::d41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F0F58C061A4E for ; Thu, 3 Dec 2020 06:40:23 -0800 (PST) Received: by mail-io1-xd41.google.com with SMTP id y5so2280597iow.5 for ; Thu, 03 Dec 2020 06:40:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=d9G45ZkjSgba/8DWe2/HGegTTTpqJzhrbsxzg42vBcs=; b=CVVHlYKVkUuvqh9bfQvPy2zQdBUWgyUHM+qhL0Fh3EUm+Tos2jOqrOs/UW4wYXHECs cBpQmFc+/CRk+O1q/TS+Hez05bPUu84G5nTaVVvKVOl2Rzl2ct1FZJKmkvWNJG/nxjeM ejlk36Uvewc/BIaayxv36bM6FF9ZBtFz13vWjfzg8XmOwHbn7kZg0op+tUxn/WkpaCq/ Nihyv7BOMcFpngQhg+SswL+VGR/WCpd3keXSP2WUhRva/Db9tM2QEFNJ9iUnENe8YOsE J7BsFkVqZff9BbG51QUcr+BGsUo3Iz/4a5THHymiI6B62Fl+vMerndO5McxTBvzCW5Qa wCxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=d9G45ZkjSgba/8DWe2/HGegTTTpqJzhrbsxzg42vBcs=; b=po9hMCk/wocMDWlkTrSGrMk5lIIEnxUBCUk9lhkQW01e0py3h36h5gXUedbD5T/nM/ z7KNzrr6gWv0LJaFpWCdAsl/SFyUePeli9dlTaivRFFO8134eKZkFJamYCiaYDB72WZj yw3VyJ5apm+aoMshdNzlKPH64VduhKoxPrvVOVct7Ya0jZGxDR4ls5LVzgtzKbbsY+3H 8QOlXFLDghQzDISyK4x55ByDnr5mb5uL0WKkqSJBQFtGPHXHi8E5saL+JIzvAzSg6Wvj tUlwp85K2ztMWxB7WSwZL9fPUzm0/KEgg0qizWrbVL60+ohaRm4+duQH5ePf4WAbeSu2 JIAw== X-Gm-Message-State: AOAM530DUgCAufXe7sJU0Cch7F9wjSZ5i8rJ7vbwzQEdi5IJRqb8qZmz Y0N73lKsolwJ7VMOt5ZPUKbCysiDGh253ToqlIQ= X-Google-Smtp-Source: ABdhPJwpyumKf+74VQrJ3K8qZjhr0J1QStmOrdQAut9BoXn/hDEucd19fbjX4b46twoQz7uylpgzMX/xEeSGDaN17M0= X-Received: by 2002:a5e:9906:: with SMTP id t6mr3355199ioj.183.1607006423313; Thu, 03 Dec 2020 06:40:23 -0800 (PST) MIME-Version: 1.0 References: <20201107075550.2244055-1-ndesaulniers@google.com> <4910042649a4f3ab22fac93191b8c1fa0a2e17c3.camel@perches.com> <26052c5a0a098aa7d9c0c8a1d39cc4a8f7915dd2.camel@perches.com> <7ca84085-f8e1-6792-7d1c-455815986572@redhat.com> In-Reply-To: From: Lukas Bulwahn Date: Thu, 3 Dec 2020 15:40:12 +0100 Message-ID: Subject: Re: [PATCH] netfilter: conntrack: fix -Wformat To: Miguel Ojeda Cc: Tom Rix , Nick Desaulniers , Joe Perches , Nathan Chancellor , LKML , clang-built-linux , Dwaipayan Ray Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Dec 3, 2020 at 2:44 PM Miguel Ojeda wrote: > > On Thu, Dec 3, 2020 at 8:26 AM Lukas Bulwahn wrote: > > > > It is not a competition between checkpatch and clang-format, but if it would be: > > Please note that clang-tidy is a different tool, it is designed to > write lints based on the AST rather than formatting. > > > But jokes aside: Dwaipayan Ray, a mentee Joe and I are working with, > > has already submitted a patch to checkpatch that identifies those > > patterns and provides a fix: > > > > https://lore.kernel.org/lkml/20201128200046.78739-1-dwaipayanray1@gmail.com/ > > That is very good! However, it does not hurt to have it repeated in > clang-tidy too: it is a very good thing to have a full C parser behind > when writing lints! > Completely agree. A regular expression is only a limited (but quite powerful) heuristics to a full C parser :) ... and it did a good job in the case here. Lukas > Cheers, > Miguel