From: Michal Kubecek <mkubecek@suse.cz>
To: "David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
netdev@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH net-next 0/5] tun: debug messages cleanup
Date: Wed, 4 Mar 2020 17:23:54 +0100 (CET) [thread overview]
Message-ID: <cover.1583337972.git.mkubecek@suse.cz> (raw)
While testing ethtool output for "strange" devices, I noticed confusing and
obviously incorrect message level information for a tun device and sent
a quick fix. The result of the upstream discussion was that tun driver
would rather deserve a more complex cleanup of the way it handles debug
messages.
The main problem is that all debugging statements and setting of message
level are controlled by TUN_DEBUG macro which is only defined if one edits
the source and rebuilds the module, otherwise all DBG1() and tun_debug()
statements do nothing.
This series drops the TUN_DEBUG switch and replaces custom tun_debug()
macro with standard netif_info() so that message level (mask) set and
displayed using ethtool works as expected. Some debugging messages are
dropped as they only notify about entering a function which can be done
easily using ftrace or kprobe.
Patch 1 is a trivial fix for compilation warning with W=1.
Michal Kubecek (5):
tun: fix misleading comment format
tun: get rid of DBG1() macro
tun: drop useless debugging statements
tun: replace tun_debug() by netif_info()
tun: drop TUN_DEBUG and tun_debug()
drivers/net/tun.c | 105 ++++++++++++----------------------------------
1 file changed, 27 insertions(+), 78 deletions(-)
--
2.25.1
next reply other threads:[~2020-03-04 16:24 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-04 16:23 Michal Kubecek [this message]
2020-03-04 16:23 ` [PATCH net-next 1/5] tun: fix misleading comment format Michal Kubecek
2020-03-04 16:24 ` [PATCH net-next 2/5] tun: get rid of DBG1() macro Michal Kubecek
2020-03-04 16:24 ` [PATCH net-next 3/5] tun: drop useless debugging statements Michal Kubecek
2020-03-04 16:24 ` [PATCH net-next 4/5] tun: replace tun_debug() by netif_info() Michal Kubecek
2020-03-04 16:24 ` [PATCH net-next 5/5] tun: drop TUN_DEBUG and tun_debug() Michal Kubecek
2020-03-06 5:38 ` [PATCH net-next 0/5] tun: debug messages cleanup David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1583337972.git.mkubecek@suse.cz \
--to=mkubecek@suse.cz \
--cc=davem@davemloft.net \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).