From: Peilin Ye <yepeilin.cs@gmail.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>,
Sam Ravnborg <sam@ravnborg.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>,
Jiri Slaby <jirislaby@kernel.org>,
dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fbcon: Replace printk() with pr_*()
Date: Sun, 1 Nov 2020 11:08:30 -0500 [thread overview]
Message-ID: <20201101160830.GA1526929@PWN> (raw)
In-Reply-To: <20201101154113.GA41883@kroah.com>
On Sun, Nov 01, 2020 at 04:41:13PM +0100, Greg Kroah-Hartman wrote:
> On Sun, Nov 01, 2020 at 09:49:04AM -0500, Peilin Ye wrote:
> > Replace printk() with pr_err(), pr_warn() and pr_info(). Do not split long
> > strings, for easier grepping. Use `__func__` whenever applicable.
> >
> > fbcon_prepare_logo() has more than one callers, use "fbcon_prepare_logo:"
> > instead of "fbcon_init:", for less confusion.
> >
> > Suggested-by: Sam Ravnborg <sam@ravnborg.org>
> > Signed-off-by: Peilin Ye <yepeilin.cs@gmail.com>
> > ---
> > drivers/video/fbdev/core/fbcon.c | 42 +++++++++++++-------------------
> > 1 file changed, 17 insertions(+), 25 deletions(-)
> >
> > diff --git a/drivers/video/fbdev/core/fbcon.c b/drivers/video/fbdev/core/fbcon.c
> > index cef437817b0d..a3e87ab0e523 100644
> > --- a/drivers/video/fbdev/core/fbcon.c
> > +++ b/drivers/video/fbdev/core/fbcon.c
> > @@ -659,8 +659,7 @@ static void fbcon_prepare_logo(struct vc_data *vc, struct fb_info *info,
> >
> > if (logo_lines > vc->vc_bottom) {
> > logo_shown = FBCON_LOGO_CANSHOW;
> > - printk(KERN_INFO
> > - "fbcon_init: disable boot-logo (boot-logo bigger than screen).\n");
> > + pr_info("%s: disable boot-logo (boot-logo bigger than screen).\n", __func__);
>
> Shouldn't this be:
> dev_info(info->dev, "...");
> instead?
>
> It's a driver, and you have access to the struct device that is being
> worked on, so always try to use the dev_* versions of these calls
> instead when ever possible.
Ah, I see. I'll fix them in v2, thank you!
Peilin
prev parent reply other threads:[~2020-11-01 16:08 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-21 12:15 [PATCH] video/fbdev/core: Mark debug-only variable as __maybe_unused Thomas Zimmermann
2020-11-01 9:47 ` Sam Ravnborg
2020-11-01 10:09 ` Peilin Ye
2020-11-01 14:49 ` [PATCH] fbcon: Replace printk() with pr_*() Peilin Ye
2020-11-01 15:41 ` Greg Kroah-Hartman
2020-11-01 16:08 ` Peilin Ye [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=20201101160830.GA1526929@PWN \
--to=yepeilin.cs@gmail.com \
--cc=b.zolnierkie@samsung.com \
--cc=daniel.vetter@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=gregkh@linuxfoundation.org \
--cc=jirislaby@kernel.org \
--cc=linux-fbdev@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sam@ravnborg.org \
--cc=tzimmermann@suse.de \
/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).