linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] remove pointless debug printk in rt_ioctl_giwscan()
@ 2010-06-05  4:41 Giangiacomo Mariotti
  2010-06-05 10:07 ` Arnd Bergmann
  0 siblings, 1 reply; 3+ messages in thread
From: Giangiacomo Mariotti @ 2010-06-05  4:41 UTC (permalink / raw)
  To: LKML; +Cc: gregkh, bzolnier, roel.kluin, devel, linux-kernel

This debug printk is only useful if you're debugging the staging drivers
2860 e 2870, but, if you're just using them, it becomes really annoying, because
it uselessly clobbers the kernel log. I guess this patch shouldn't really get merged,
but it's more like a request to remove these annoying debugging messages for normal users.
If I get any suggestion on how to implement this in a way acceptable to get it merged, I'll
be happy to create the "good" version  of the patch.

Thanks,

Giangiacomo

>From b24cc30ddad0bcd9a1fe00a7ecdd5dba4a3a4d06 Mon Sep 17 00:00:00 2001
From: Giangiacomo Mariotti <giangiacomo.mariotti@gmail.com>
Date: Sat, 5 Jun 2010 05:39:58 +0200
Subject: [PATCH] remove pointless debug printk in rt_ioctl_giwscan()


Signed-off-by: Giangiacomo Mariotti <giangiacomo.mariotti@gmail.com>
---
 drivers/staging/rt2860/sta_ioctl.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/rt2860/sta_ioctl.c b/drivers/staging/rt2860/sta_ioctl.c
index de4b627..f9aa6f2 100644
--- a/drivers/staging/rt2860/sta_ioctl.c
+++ b/drivers/staging/rt2860/sta_ioctl.c
@@ -1116,9 +1116,9 @@ int rt_ioctl_giwscan(struct net_device *dev,
 
 	data->length = current_ev - extra;
 	pAdapter->StaCfg.bScanReqIsFromWebUI = FALSE;
-	DBGPRINT(RT_DEBUG_ERROR,
+	/*DBGPRINT(RT_DEBUG_ERROR,
 		 ("===>rt_ioctl_giwscan. %d(%d) BSS returned, data->length = %d\n",
-		  i, pAdapter->ScanTab.BssNr, data->length));
+		  i, pAdapter->ScanTab.BssNr, data->length));*/
 	return 0;
 }
 
-- 
1.7.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] remove pointless debug printk in rt_ioctl_giwscan()
  2010-06-05  4:41 [PATCH] remove pointless debug printk in rt_ioctl_giwscan() Giangiacomo Mariotti
@ 2010-06-05 10:07 ` Arnd Bergmann
  2010-06-18 23:15   ` Greg KH
  0 siblings, 1 reply; 3+ messages in thread
From: Arnd Bergmann @ 2010-06-05 10:07 UTC (permalink / raw)
  To: Giangiacomo Mariotti; +Cc: LKML, gregkh, bzolnier, roel.kluin, devel

On Saturday 05 June 2010, Giangiacomo Mariotti wrote:
> This debug printk is only useful if you're debugging the staging drivers
> 2860 e 2870, but, if you're just using them, it becomes really annoying, because
> it uselessly clobbers the kernel log. I guess this patch shouldn't really get merged,
> but it's more like a request to remove these annoying debugging messages for normal users.
> If I get any suggestion on how to implement this in a way acceptable to get it merged, I'll
> be happy to create the "good" version  of the patch.

Ideally, drivers should not have their own debugging macros like this, but
instead use the kernel's own pr_debug() and (preferrably) dev_dbg() macros,
which are disabled by default.
For many of these debugging outputs, it's even better to kill them entirely
instead of converting to dev_dbg().
Do not put the line in comments though.

	Arnd

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] remove pointless debug printk in rt_ioctl_giwscan()
  2010-06-05 10:07 ` Arnd Bergmann
@ 2010-06-18 23:15   ` Greg KH
  0 siblings, 0 replies; 3+ messages in thread
From: Greg KH @ 2010-06-18 23:15 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Giangiacomo Mariotti, LKML, gregkh, bzolnier, roel.kluin, devel

On Sat, Jun 05, 2010 at 12:07:39PM +0200, Arnd Bergmann wrote:
> On Saturday 05 June 2010, Giangiacomo Mariotti wrote:
> > This debug printk is only useful if you're debugging the staging drivers
> > 2860 e 2870, but, if you're just using them, it becomes really annoying, because
> > it uselessly clobbers the kernel log. I guess this patch shouldn't really get merged,
> > but it's more like a request to remove these annoying debugging messages for normal users.
> > If I get any suggestion on how to implement this in a way acceptable to get it merged, I'll
> > be happy to create the "good" version  of the patch.
> 
> Ideally, drivers should not have their own debugging macros like this, but
> instead use the kernel's own pr_debug() and (preferrably) dev_dbg() macros,
> which are disabled by default.
> For many of these debugging outputs, it's even better to kill them entirely
> instead of converting to dev_dbg().
> Do not put the line in comments though.

I agree, just use dev_dbg() instead.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-06-18 23:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-05  4:41 [PATCH] remove pointless debug printk in rt_ioctl_giwscan() Giangiacomo Mariotti
2010-06-05 10:07 ` Arnd Bergmann
2010-06-18 23:15   ` Greg KH

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).