Re: [PATCH] Staging: wlan-ng: fix many style warnings in hfa384x_usb.c

From: Richard Kennedy
Date: Fri Apr 23 2010 - 05:19:20 EST


On 22/04/10 16:49, Alessandro Ghedini wrote:
> This patch fixes most of the style warnings found with checkpatch.pl in the
> hfa384x_usb.c file.
>
> Signed-off-by: Alessandro Ghedini <al3xbio@xxxxxxxxx>
> ---

> if (result2 != 0) {
> - printk(KERN_ERR
> - "cmd_initialize() failed on two attempts, results %d and %d\n",
> + printk(KERN_ERR "cmd_initialize() failed on two" \
> + "attempts, results %d and %d\n",
> result1, result2);

Hi Alessandro,

I'm not keen on splitting up printk strings. It makes it more difficult
to grep for them. It's nice and easy if you can just copy most of the
log message into grep and get to the correct bit of code.

> usb_kill_urb(&hw->rx_urb);
> goto done;
> } else {
> pr_debug("First cmd_initialize() failed (result %d),\n",
> result1);
> - pr_debug
> - ("but second attempt succeeded. All should be ok\n");
> + pr_debug("but second attempt succeeded. " \
> + "All should be ok\n");
> }
> } else if (result2 != 0) {
> printk(KERN_WARNING
> - "First cmd_initialize() succeeded, but second attempt failed (result=%d)\n",
> + "First cmd_initialize() succeeded, but second " \
> + "attempt failed (result=%d)\n",
> result2);
> printk(KERN_WARNING
> "Most likely the card will be functional\n");
> @@ -3382,8 +3384,9 @@ retry:
> * our request has been acknowledged. Odd,
> * but our OUT URB is still alive...
> */
> - pr_debug
> - ("Causality violation: please reboot Universe, or email linux-wlan-devel@xxxxxxxxxxxxxxxxxxxx\n");
> + pr_debug("Causality violation: please reboot " \
> + "Universe, or email " \
> + "linux-wlan-devel@xxxxxxxxxxxxxxxxxxxx\n");
> ctlx->state = CTLX_RESP_COMPLETE;
> break;

There has already been a patch for this -- I don't know if it's stuck in
Greg's queue or it got lost, but that mailing list is now dead so we can
just drop the second half of that message.

regards
Richard
--
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/