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

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Joe Perches
Date: Friday, April 23, 2010 - 9:00 am

On Fri, 2010-04-23 at 17:15 +0200, Alessandro Ghedini wrote:

Hi Alessandro.

Almost there...  One more pass and it should be good to go.


This is more difficult to read and less standard than

	if (!hw->wlandev->hwremoved &&
	    !test_bit(WORK_RX_HALT, &hw->usb_flags)) {

Please change it.


Try not to make function calls use separate lines for each argument
unless you've got a specific reason like a comment for each arg or
something.


Please don't split the format strings.
As Richard Kennedy said, it makes grep less convenient.

Put the format on the same line as the printk and
use a newer checkpatch.pl.

I think all these should become single line

	pr_<level>(fmt, args that fit before col 80);

or multiple lines like:

	pr_<level>(fmt,
		   args until col 80,
		   more args if necessary);

That may be a personal nit though.

cheers, Joe

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] Staging: wlan-ng: fix many style issues in hfa384x ..., Alessandro Ghedini, (Fri Apr 23, 8:15 am)
Re: [PATCH] Staging: wlan-ng: fix many style issues in hfa ..., Joe Perches, (Fri Apr 23, 9:00 am)