linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Guenter Roeck <groeck@google.com>
Cc: Ezequiel Garcia <ezequiel@collabora.com>,
	Enric Balletbo i Serra <enric.balletbo@collabora.com>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Gwendal Grignou <gwendal@chromium.org>,
	Guenter Roeck <groeck@chromium.org>,
	Benson Leung <bleung@chromium.org>,
	Lee Jones <lee.jones@linaro.org>,
	kernel@collabora.com, Dmitry Torokhov <dtor@chromium.org>,
	Gustavo Pimentel <gustavo.pimentel@synopsys.com>,
	Randy Dunlap <rdunlap@infradead.org>,
	Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>,
	linux-doc@vger.kernel.org,
	Enno Luebbers <enno.luebbers@intel.com>,
	Guido Kiener <guido@kiener-muenchen.de>,
	Thomas Gleixner <tglx@linutronix.de>,
	Kishon Vijay Abraham I <kishon@ti.com>,
	Jonathan Corbet <corbet@lwn.net>, Wu Hao <hao.wu@intel.com>,
	Kate Stewart <kstewart@linuxfoundation.org>,
	Tycho Andersen <tycho@tycho.ws>,
	Gerd Hoffmann <kraxel@redhat.com>,
	Jilayne Lovejoy <opensource@jilayne.com>
Subject: Re: [PATCH 03/10] mfd / platform: cros_ec: Miscellaneous character device to talk with the EC
Date: Tue, 4 Jun 2019 20:59:53 +0200	[thread overview]
Message-ID: <20190604185953.GA2061@kroah.com> (raw)
In-Reply-To: <CABXOdTfU9KaBDhQcwvBGWCmVfnd02_ZFmPGtJsCtGQ-iO9A3Qw@mail.gmail.com>

On Tue, Jun 04, 2019 at 11:39:21AM -0700, Guenter Roeck wrote:
> On Tue, Jun 4, 2019 at 11:35 AM Greg Kroah-Hartman
> <gregkh@linuxfoundation.org> wrote:
> >
> > On Tue, Jun 04, 2019 at 01:58:38PM -0300, Ezequiel Garcia wrote:
> > > Hey Greg,
> > >
> > > > > + dev_info(&pdev->dev, "Created misc device /dev/%s\n",
> > > > > +          data->misc.name);
> > > >
> > > > No need to be noisy, if all goes well, your code should be quiet.
> > > >
> > >
> > > I sometimes wonder about this being noise or not, so I will slightly
> > > hijack this thread for this discussion.
> > >
> > > >From a kernel developer point-of-view, or even from a platform
> > > developer or user with a debugging hat point-of-view, having
> > > a "device created" or "device registered" message is often very useful.
> >
> > For you, yes.  For someone with 30000 devices attached to their system,
> > it is not, and causes booting to take longer than it should be.
> >
> > > In fact, I wish people would do this more often, so I don't have to
> > > deal with dynamic debug, or hack my way:
> > >
> > > diff --git a/drivers/media/i2c/ov5647.c b/drivers/media/i2c/ov5647.c
> > > index 4589631798c9..473549b26bb2 100644
> > > --- a/drivers/media/i2c/ov5647.c
> > > +++ b/drivers/media/i2c/ov5647.c
> > > @@ -603,7 +603,7 @@ static int ov5647_probe(struct i2c_client *client,
> > >         if (ret < 0)
> > >                 goto error;
> > >
> > > -       dev_dbg(dev, "OmniVision OV5647 camera driver probed\n");
> > > +       dev_info(dev, "OmniVision OV5647 camera driver probed\n");
> > >         return 0;
> > >  error:
> > >         media_entity_cleanup(&sd->entity);
> > >
> > > In some subsystems, it's even a behavior I'm more or less relying on:
> > >
> > > $ git grep v4l2_info.*registered drivers/media/ | wc -l
> > > 26
> > >
> > > And on the downsides, I can't find much. It's just one little line,
> > > that is not even noticed unless you have logging turned on.
> >
> > Its better to be quiet, which is why the "default driver registration"
> > macros do not have any printk messages in them.  When converting drivers
> > over to it, we made the boot process much more sane, don't try to go and
> > add messages for no good reason back in please.
> >
> > dynamic debugging can be enabled on a module and line-by-line basis,
> > even from the boot command line.  So if you need debugging, you can
> > always ask someone to just reboot or unload/load the module and get the
> > message that way.
> >
> 
> Can we by any chance make this an official policy ? I am kind of tired
> having to argue about this over and over again.

Sure, but how does anyone make any "official policy" in the kernel?  :)

I could just go through and delete all "look ma, a new driver/device!"
messages, but that might be annoying...

thanks,

greg k-h

  reply	other threads:[~2019-06-04 18:59 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20190604152019.16100-1-enric.balletbo@collabora.com>
2019-06-04 15:20 ` [PATCH 03/10] mfd / platform: cros_ec: Miscellaneous character device to talk with the EC Enric Balletbo i Serra
2019-06-04 15:52   ` Greg Kroah-Hartman
2019-06-04 16:58     ` Ezequiel Garcia
2019-06-04 18:35       ` Greg Kroah-Hartman
2019-06-04 18:39         ` Guenter Roeck
2019-06-04 18:59           ` Greg Kroah-Hartman [this message]
2019-06-05  6:48             ` Lee Jones
2019-06-05  8:02               ` Greg Kroah-Hartman
2019-06-05  8:40                 ` Lee Jones
2019-06-05  8:48                   ` Greg Kroah-Hartman
2019-06-05  9:21                     ` Lee Jones
2019-06-06 14:01             ` Ezequiel Garcia
2019-06-06 14:51               ` Greg Kroah-Hartman
2019-06-06 15:12                 ` Ezequiel Garcia
2019-06-06 21:11                   ` Randy Dunlap
2019-06-10  7:27                     ` Lee Jones
2019-06-05 14:33     ` Enric Balletbo Serra

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=20190604185953.GA2061@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=bleung@chromium.org \
    --cc=corbet@lwn.net \
    --cc=dtor@chromium.org \
    --cc=enno.luebbers@intel.com \
    --cc=enric.balletbo@collabora.com \
    --cc=ezequiel@collabora.com \
    --cc=groeck@chromium.org \
    --cc=groeck@google.com \
    --cc=guido@kiener-muenchen.de \
    --cc=gustavo.pimentel@synopsys.com \
    --cc=gwendal@chromium.org \
    --cc=hao.wu@intel.com \
    --cc=kernel@collabora.com \
    --cc=kishon@ti.com \
    --cc=kraxel@redhat.com \
    --cc=kstewart@linuxfoundation.org \
    --cc=lee.jones@linaro.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lorenzo.pieralisi@arm.com \
    --cc=opensource@jilayne.com \
    --cc=rdunlap@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=tycho@tycho.ws \
    /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).