From: Jonathan Corbet <corbet@lwn.net>
To: Abhishek Pandit-Subedi <abhishekpandit@chromium.org>,
gregkh@linuxfoundation.org
Cc: Abhishek Pandit-Subedi <abhishekpandit@chromium.org>,
linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
workflows@vger.kernel.org
Subject: Re: [PATCH] coding-style: Add guidance to prefer dev_dbg
Date: Tue, 30 Jan 2024 14:03:42 -0700 [thread overview]
Message-ID: <87fryea5zl.fsf@meer.lwn.net> (raw)
In-Reply-To: <20240125165311.1.I8d9c88e747e233917e527c7dad1feb8a18f070e2@changeid>
Abhishek Pandit-Subedi <abhishekpandit@chromium.org> writes:
> During review, it was suggested that drivers only emit messages when
> something is wrong or it is a debug message. Document this as a formal
> recommendation.
>
> https://lore.kernel.org/linux-usb/2024012525-alienate-frown-916b@gregkh/
>
> Signed-off-by: Abhishek Pandit-Subedi <abhishekpandit@chromium.org>
> ---
> I'm sending up the change to documentation while this is still fresh.
> Will send an update to checkpatch.pl afterwards.
>
> Documentation/process/coding-style.rst | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/process/coding-style.rst b/Documentation/process/coding-style.rst
> index c48382c6b477..f8ec23fa89bc 100644
> --- a/Documentation/process/coding-style.rst
> +++ b/Documentation/process/coding-style.rst
> @@ -899,7 +899,8 @@ which you should use to make sure messages are matched to the right device
> and driver, and are tagged with the right level: dev_err(), dev_warn(),
> dev_info(), and so forth. For messages that aren't associated with a
> particular device, <linux/printk.h> defines pr_notice(), pr_info(),
> -pr_warn(), pr_err(), etc.
> +pr_warn(), pr_err(), etc. When drivers are working properly they are quiet,
> +so prefer to use dev_dbg/pr_debug unless something is wrong.
>
Applied, thanks.
jon
prev parent reply other threads:[~2024-01-30 21:03 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-26 0:53 [PATCH] coding-style: Add guidance to prefer dev_dbg Abhishek Pandit-Subedi
2024-01-26 1:28 ` Greg KH
2024-01-30 21:03 ` Jonathan Corbet [this message]
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=87fryea5zl.fsf@meer.lwn.net \
--to=corbet@lwn.net \
--cc=abhishekpandit@chromium.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=workflows@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.