devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>
To: "H. Nikolaus Schaller" <hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
Cc: "Johan Hovold" <johan-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	"Rob Herring" <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	"Mark Rutland" <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
	"Benoît Cousson"
	<bcousson-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>,
	"Tony Lindgren" <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>,
	"Russell King" <linux-I+IVW8TIWO2tmTQ+vhA3Yw@public.gmane.org>,
	"Arnd Bergmann" <arnd-r2nGTMty4D4@public.gmane.org>,
	"Kevin Hilman" <khilman-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>,
	"Andreas Färber" <afaerber-l3A5Bk7waGM@public.gmane.org>,
	"Thierry Reding"
	<treding-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>,
	"Jonathan Cameron"
	<jic23-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	letux-kernel-S0jZdbWzriLCfDggNXIi3w@public.gmane.org,
	kernel-Jl6IXVxNIMRxAtABVqVhTwC/G2K4zDHf@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH v5 5/5] misc serdev: w2sg0004: add debugging code and Kconfig
Date: Fri, 22 Dec 2017 15:58:13 +0100	[thread overview]
Message-ID: <20171222145813.GA28720@kroah.com> (raw)
In-Reply-To: <A2720858-5172-4627-8133-C677E4B4DC72-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>

On Fri, Dec 22, 2017 at 03:41:24PM +0100, H. Nikolaus Schaller wrote:
> 
> > Am 22.12.2017 um 13:51 schrieb Johan Hovold <johan-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>:
> > 
> > On Fri, Dec 01, 2017 at 08:49:38AM +0100, H. Nikolaus Schaller wrote:
> >> This allows to set CONFIG_W2SG0004_DEBUG which will
> >> make the driver report more activities and it will turn on the
> >> GPS module during boot while the driver assumes that it
> >> is off. This can be used to debug the correct functioning of
> >> the hardware. Therefore we add it as an option to the driver
> >> because we think it is of general use (and a little tricky to
> >> add by system testers).
> >> 
> >> Normally it should be off.
> >> 
> >> Signed-off-by: H. Nikolaus Schaller <hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
> >> ---
> >> drivers/misc/Kconfig    |  8 ++++++++
> >> drivers/misc/w2sg0004.c | 37 +++++++++++++++++++++++++++++++++++++
> >> 2 files changed, 45 insertions(+)
> > 
> > I'd say say this does not belong in the kernel at all.
> 
> There are other examples of such DEBUG options for drivers.
> E.g. CONFIG_LIBERTAS_DEBUG.

And that is wrong and should be removed.

> It helps the hardware developer to test things and should of course
> be disabled in a production kernel.

dev_dbg() should be used instead.  And you can always hard-code #define DEBUG
at the top of your file when doing bringup.

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2017-12-22 14:58 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-01  7:49 [PATCH v5 0/5] misc serdev: new serdev based driver for Wi2Wi w2sg00x4 GPS module H. Nikolaus Schaller
2017-12-01  7:49 ` [PATCH v5 1/5] dt-bindings: define vendor prefix for Wi2Wi, Inc H. Nikolaus Schaller
2017-12-01 14:44   ` Andreas Färber
2017-12-01  7:49 ` [PATCH v5 2/5] dt-bindings: gps: add w2sg00x4 bindings documentation (GPS module with UART)) H. Nikolaus Schaller
2017-12-01  7:49 ` [PATCH v5 4/5] DTS: gta04: add uart2 child node for w2sg00x4 H. Nikolaus Schaller
     [not found]   ` <1b1c7a8319eaf61a46eebd7a366ea745b7a54634.1512114577.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2017-12-21 14:53     ` Tony Lindgren
     [not found] ` <cover.1512114576.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2017-12-01  7:49   ` [PATCH v5 3/5] misc serdev: Add w2sg0004 (gps receiver) power control driver H. Nikolaus Schaller
     [not found]     ` <5494ad34b39a6c62601e3747440268dfb3be7d5a.1512114576.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2017-12-22 12:44       ` Johan Hovold
2017-12-22 14:40         ` H. Nikolaus Schaller
2018-01-09 11:55           ` [Letux-kernel] " H. Nikolaus Schaller
     [not found]             ` <90F9A8E4-035A-4A9E-8AAB-757491D63E69-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2018-01-12 15:39               ` Johan Hovold
2018-01-12 17:59                 ` H. Nikolaus Schaller
2018-01-18  6:13                   ` Johan Hovold
2018-01-18 13:43                     ` H. Nikolaus Schaller
2018-03-07 15:53                       ` H. Nikolaus Schaller
2018-03-19 14:05                         ` Johan Hovold
2018-02-12 15:26                 ` [Letux-kernel] " Pavel Machek
2018-02-27  7:04                   ` Johan Hovold
2018-02-27  7:32                     ` H. Nikolaus Schaller
2018-03-19 13:54                       ` Johan Hovold
2018-03-20 14:49                         ` H. Nikolaus Schaller
2018-03-26 13:59                           ` Pavel Machek
2018-02-27 18:38                     ` Pavel Machek
2018-02-12 15:25             ` Pavel Machek
2018-01-09 17:43         ` Andreas Kemnade
2018-01-12 14:46           ` Johan Hovold
2018-01-12 18:40             ` Andreas Kemnade
     [not found]               ` <20180112194022.7da1e726-cLv4Z9ELZ06ZuzBka8ofvg@public.gmane.org>
2018-01-18  6:47                 ` Johan Hovold
2018-03-08  6:16                   ` Andreas Kemnade
2018-03-19 14:02                     ` Johan Hovold
2017-12-01  7:49   ` [PATCH v5 5/5] misc serdev: w2sg0004: add debugging code and Kconfig H. Nikolaus Schaller
     [not found]     ` <5816bfb9e7cab68591c133e20696d6188ebe70de.1512114577.git.hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2017-12-22 12:51       ` Johan Hovold
2017-12-22 14:41         ` H. Nikolaus Schaller
     [not found]           ` <A2720858-5172-4627-8133-C677E4B4DC72-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org>
2017-12-22 14:58             ` Greg Kroah-Hartman [this message]
2017-12-18  8:52 ` [PATCH v5 0/5] misc serdev: new serdev based driver for Wi2Wi w2sg00x4 GPS module H. Nikolaus Schaller
2017-12-18 14:48   ` Greg Kroah-Hartman
     [not found]     ` <20171218144816.GA31130-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2017-12-18 14:52       ` H. Nikolaus Schaller

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=20171222145813.GA28720@kroah.com \
    --to=gregkh-hqyy1w1ycw8ekmwlsbkhg0b+6bgklq7r@public.gmane.org \
    --cc=afaerber-l3A5Bk7waGM@public.gmane.org \
    --cc=arnd-r2nGTMty4D4@public.gmane.org \
    --cc=bcousson-rdvid1DuHRBWk0Htik3J/w@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=hns-xXXSsgcRVICgSpxsJD1C4w@public.gmane.org \
    --cc=jic23-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=johan-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=kernel-Jl6IXVxNIMRxAtABVqVhTwC/G2K4zDHf@public.gmane.org \
    --cc=khilman-rdvid1DuHRBWk0Htik3J/w@public.gmane.org \
    --cc=letux-kernel-S0jZdbWzriLCfDggNXIi3w@public.gmane.org \
    --cc=linux-I+IVW8TIWO2tmTQ+vhA3Yw@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
    --cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org \
    --cc=treding-DDmLM1+adcrQT0dZR+AlfA@public.gmane.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).