[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1264601340.14552.55.camel@Joe-Laptop.home>
Date: Wed, 27 Jan 2010 06:09:00 -0800
From: Joe Perches <joe@...ches.com>
To: Jiri Slaby <jirislaby@...il.com>
Cc: linux-kernel@...r.kernel.org, akpm@...ux-foundation.org,
mm-commits@...r.kernel.org, bzolnier@...il.com,
jens.axboe@...cle.com, marcin.slusarz@...il.com,
shemminger@...tta.com
Subject: Re: + drivers-block-floppyc-use-pr_level.patch added to -mm tree
On Wed, 2010-01-27 at 10:31 +0100, Jiri Slaby wrote:
> On 01/27/2010 01:37 AM, akpm@...ux-foundation.org wrote:
> > @@ -687,9 +687,7 @@ static void __reschedule_timeout(int dri
> > fd_timeout.expires = jiffies + UDP->timeout;
> > add_timer(&fd_timeout);
> > if (UDP->flags & FD_DEBUG) {
> > - DPRINT("reschedule timeout ");
> > - printk(message, marg);
> > - printk("\n");
> > + DPRINT("reschedule timeout %s %d\n", message, marg);
>
> This is wrong.
I disagree.
It does add an always output decimal value to the DPRINT
instead of a mostly mismatched format and argument
printk(message, marg).
Previous single matched output use of message/marg:
- reschedule_timeout(MAXTIMEOUT, "request done %d", uptodate);
+ reschedule_timeout(MAXTIMEOUT, "request done", uptodate);
vs now:
$ grep reschedule_timeout drivers/block/floppy.c
static void __reschedule_timeout(int drive, const char *message, int marg)
static void reschedule_timeout(int drive, const char *message, int marg)
__reschedule_timeout(drive, message, marg);
__reschedule_timeout(drive, "lock fdc", 0);
reschedule_timeout(current_reqD, "floppy start", 0);
reschedule_timeout(MAXTIMEOUT, "do wakeup", 0);
reschedule_timeout(MAXTIMEOUT, "request done", uptodate);
reschedule_timeout(current_reqD, "redo fd request", 0);
reschedule_timeout(MAXTIMEOUT, "floppy init", MAXTIMEOUT);
Arguably, that single use could be something like:
char msg_buf[sizeof("request done ") + 20];
snprintf(msg_buf, sizeof(msg_buf), "request_done %d", uptodate);
reschedule_timeout(MAXTIMEOUT, msg_buf);
(uptodate should be 0, 1 or 2)
with the now unused marg argument removed from
reschedule_timeout and __reschedule_timeout.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists