Re: + drivers-block-floppyc-use-pr_level.patch added to -mm tree

From: Jiri Slaby
Date: Wed Jan 27 2010 - 09:21:23 EST


On 01/27/2010 03:09 PM, Joe Perches wrote:
> On Wed, 2010-01-27 at 10:31 +0100, Jiri Slaby wrote:
>> On 01/27/2010 01:37 AM, akpm@xxxxxxxxxxxxxxxxxxxx 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.

Then you need to document it in the changelog. The patch does something
completely different to what is stated in the changelog.

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

So if I understand correctly, it now prints the third argument every time.

--
js
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/