Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp7121990rwb; Wed, 23 Nov 2022 02:25:48 -0800 (PST) X-Google-Smtp-Source: AA0mqf7UXXpwlBjvI9zrwMzVPrTPdi+EIeOQIJ5FeJnvsR3z1Avq0c8Yy4MYpIe4GfrqIkk/WU2F X-Received: by 2002:a17:906:160b:b0:78d:dddb:3974 with SMTP id m11-20020a170906160b00b0078ddddb3974mr22827507ejd.411.1669199148482; Wed, 23 Nov 2022 02:25:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669199148; cv=none; d=google.com; s=arc-20160816; b=CUk4wsKwPIM/dfbanmTwMkt28LJ2nk9ADAhRk5V1Lb4g6Kp7jvZ/e8jh+vt/JYHXA9 Xw3ywzVjnyNgEkJFKtBqOekNZv2o3EcpitEPR+rY9QE7/xmlo+gsN8elsV8UWr3una7H VYzUOWo+HcBXeKew3zRcQu/jtMVViurrFx7fMEoHaJkIdlYsDBSnYqZVN4RD8Ls+PZBP GR6BjdVnHW2ZbcL59nmMTWn2gzGyaH+lTr5AxcJueDWofdz0taVET9g1wuSZIt+ykZsh 1QI08CyvRTGNa9pyrFSVU16rlEe+XMf7yo0VMWed9oERGX7bNW6Bv2NgN5qfnUNm3wvp hQOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version; bh=srlt3bFZ6MegHyi5woaD55H1HX/2p/E5mzMQRE78ubI=; b=RS6dw4l2b0ARya/8h2PxMG5dgUy6XCyOeMvNJVIXMFiPdOXopRvQ5bg+JYwM42q0V3 ZNodP4xoqu3iljfyz98cV18sarTkGFE2Au3/Wxus9oVIGC9xi/vJdSoZ4dSzioT2tN3v 8cN8WSRt/sfCBIYh/kMMn7Ch+Kfu68QzI+UGvYRzyb57iQnbCiO3mXtCAmoJPLTaYj7h VUdofDUfnR15uAeRpNcrtYZ8LvFvBFhC1uus04jYgbcRjlJ/dbvEn2qfMOMcaPzExPUO 175Ey4afDzEhVBTh0kX+yulCdMxqIyFR1EI/1lJ7Se0CqxypGDHjkw1fQyOPyg52TreX Tv+w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x11-20020a05640226cb00b0046311e80ebcsi15737616edd.151.2022.11.23.02.25.26; Wed, 23 Nov 2022 02:25:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237158AbiKWJN4 (ORCPT + 88 others); Wed, 23 Nov 2022 04:13:56 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55546 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237196AbiKWJNy (ORCPT ); Wed, 23 Nov 2022 04:13:54 -0500 Received: from mail-pf1-f174.google.com (mail-pf1-f174.google.com [209.85.210.174]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 56F4387A76; Wed, 23 Nov 2022 01:13:53 -0800 (PST) Received: by mail-pf1-f174.google.com with SMTP id b29so16754935pfp.13; Wed, 23 Nov 2022 01:13:53 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=srlt3bFZ6MegHyi5woaD55H1HX/2p/E5mzMQRE78ubI=; b=mCOaP5A/twvoIWOM5puvcLpXNa8xGnl0XMQLJoDaW7vOX5vJm/zOvs2M36bPSLf5wA o5Vo6uu6UcLAmAUwY9wldYCNxfNE4qgG+fRAk08kCim8c4CE0vOqkJihmS5dgOqrxHQR 1INhVMBsHcHvcLnW0ZWlRnobqf0kYIQomqwHC7jxw/b0v2okk2T/0m7O72nYtA9Y6LQ7 ps87QH0cA6NbU3hoSYOy0j9Sw5GMAD1hYjF4lwj0FaZesz1BNI9Yjt4aOdepms4xBojm lsl+2Rz3XMQjyh8LZ6NHdjmim+84bw859okK8GSGme3Mhv7ohkVpjO5sLc/PIV/7DwvX zN5A== X-Gm-Message-State: ANoB5pmeCpVH95dTHHORtg46MS0XK3D0Kxux6EFccfWwzwnW4BRD/W/m TC9KVeNzBRnQh9BUdyVf6U1Lv/qwzQuiM0zjsE5lT61sqOVlHw== X-Received: by 2002:a63:1955:0:b0:477:50ed:6415 with SMTP id 21-20020a631955000000b0047750ed6415mr15313204pgz.535.1669194832632; Wed, 23 Nov 2022 01:13:52 -0800 (PST) MIME-Version: 1.0 References: <20221123074214.21538-1-lukas.bulwahn@gmail.com> In-Reply-To: <20221123074214.21538-1-lukas.bulwahn@gmail.com> From: Vincent MAILHOL Date: Wed, 23 Nov 2022 18:13:41 +0900 Message-ID: Subject: Re: [PATCH] can: etas_es58x: repair conditional for a verbose debug message To: Lukas Bulwahn Cc: Wolfgang Grandegger , Marc Kleine-Budde , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , linux-can@vger.kernel.org, netdev@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Lukas, Thank you for reporting this bug. On Wed. 23 Nov. 2022 at 16:45, Lukas Bulwahn wrote: > The definition of VERBOSE_DEBUG for detailled debugging is set simply by ^^^^^^^^^ detailed > adding "#define VERBOSE_DEBUG" in the source code. It is not a kernel > configuration that is prefixed by CONFIG. ACK. I initially used #ifdef VERBOSE_DEBUG but then inadvertently replaced it by IS_ENABLED(CONFIG_VERBOSE_DEBUG) instead of defined(VERBOSE_DEBUG). > As the netdev_vdbg() macro is already defined conditional on > defined(VERBOSE_DEBUG), there is really no need to duplicate the check > before calling netdev_vdbg(). NACK. There is a need. net_ratelimit() will continue to emit those messages: net_ratelimit: xxxx callbacks suppressed The goal of this check is to guard net_ratelimit(), not to guard netdev_vdbg(). > Repair the conditional for a verbose debug message. > If you want to send a v2, please also add the fix tag: Fixes: commit 8537257874e9 ("can: etas_es58x: add core support for ETAS ES58X CAN USB interfaces") > Signed-off-by: Lukas Bulwahn > --- > drivers/net/can/usb/etas_es58x/es58x_core.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/can/usb/etas_es58x/es58x_core.c b/drivers/net/can/usb/etas_es58x/es58x_core.c > index 25f863b4f5f0..2708909fb851 100644 > --- a/drivers/net/can/usb/etas_es58x/es58x_core.c > +++ b/drivers/net/can/usb/etas_es58x/es58x_core.c > @@ -989,7 +989,7 @@ int es58x_rx_cmd_ret_u32(struct net_device *netdev, > break; > > case ES58X_RET_TYPE_TX_MSG: > - if (IS_ENABLED(CONFIG_VERBOSE_DEBUG) && net_ratelimit()) > + if (net_ratelimit()) > netdev_vdbg(netdev, "%s: OK\n", ret_desc); > break; > > -- > 2.17.1 >