All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Sebastian Wankerl <sisewank@cip.cs.fau.de>
Cc: linux-kernel@i4.informatik.uni-erlangen.de,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org,
	Sebastian Wankerl 
	<sisewank@faui49man10.informatik.uni-erlangen.de>
Subject: Re: [PATCH 1/3] wlan-ng/prism2mgmt.c: added parenthesis to macro
Date: Mon, 17 Dec 2012 17:00:04 +0300	[thread overview]
Message-ID: <20121217140004.GQ5083@mwanda> (raw)
In-Reply-To: <1355751483-7059-1-git-send-email-sisewank@cip.cs.fau.de>

On Mon, Dec 17, 2012 at 02:38:01PM +0100, Sebastian Wankerl wrote:
> From: Sebastian Wankerl <sisewank@faui49man10.informatik.uni-erlangen.de>
> 
> Signed-off-by: Sebastian Wankerl <sisewank@cip.cs.fau.de> 
> Signed-off-by: Sebastian Ehrenfels <qi50dube@cip.cs.fau.de> 
> 
> ---
>  drivers/staging/wlan-ng/prism2mgmt.c |   25 +++++++++++++++----------
>  1 file changed, 15 insertions(+), 10 deletions(-)
> 
> diff --git a/drivers/staging/wlan-ng/prism2mgmt.c b/drivers/staging/wlan-ng/prism2mgmt.c
> index 4efa9bc..62b94b0 100644
> --- a/drivers/staging/wlan-ng/prism2mgmt.c
> +++ b/drivers/staging/wlan-ng/prism2mgmt.c
> @@ -415,11 +415,14 @@ int prism2mgmt_scan_results(wlandevice_t *wlandev, void *msgp)
>  			break;
>  
>  #define REQBASICRATE(N) \
> -	if ((count >= N) && DOT11_RATE5_ISBASIC_GET(item->supprates[(N)-1])) { \
> -		req->basicrate ## N .data = item->supprates[(N)-1]; \
> -		req->basicrate ## N .status = \
> -			P80211ENUM_msgitem_status_data_ok; \
> -	}
> +	do { \
> +		if ((count >= N) && DOT11_RATE5_ISBASIC_GET( \
> +			item->supprates[(N)-1])) { \

This is a very confusing way to indent.  The proper way is:

	do {                                                                \
		if (count >= N &&                                           \
		    DOT11_RATE5_ISBASIC_GET(item->supprates[(N)-1])) {      \

The "DOT11_RATE5_ISBASIC_GET(item->supprates[(N)-1])" call should be
on one line if possible.

The start 'c' in count and the 'D' in DOT11_ should be in the same
column.  You will need to add some space characters to make this
work.

> +			req->basicrate ## N .data = item->supprates[(N)-1]; \
> +			req->basicrate ## N .status = \
> +				P80211ENUM_msgitem_status_data_ok; \
> +		} \

regards,
dan carpenter

  parent reply	other threads:[~2012-12-17 14:02 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-17 13:38 [PATCH 1/3] wlan-ng/prism2mgmt.c: added parenthesis to macro Sebastian Wankerl
2012-12-17 13:38 ` [PATCH 2/3] wlan-ng/prism2mgmt.c: formated too long lines Sebastian Wankerl
2012-12-17 14:08   ` Dan Carpenter
2012-12-17 13:38 ` [PATCH 3/3] wlan-ng/prism2mgmt.c Replace printk(...) with netdev_warn, netdev_err Sebastian Wankerl
2012-12-17 14:13   ` Dan Carpenter
2012-12-17 14:00 ` Dan Carpenter [this message]
2012-12-18 21:47   ` [PATCH 1/3] wlan-ng/prism2mgmt.c: added parenthesis to macro Sebastian Ehrenfels
2013-01-17 20:58 ` Greg Kroah-Hartman
2013-01-17 23:07   ` [i4passt_all] " Sebastian Ehrenfels
2013-01-17 23:07     ` Sebastian Ehrenfels
2013-01-18 21:02       ` Greg Kroah-Hartman
2013-01-17 23:07     ` [PATCH 2/3] wlan-ng/prism2mgmt.c: formated too long lines Sebastian Ehrenfels
2013-01-18 21:00       ` Greg Kroah-Hartman
2013-01-17 23:07     ` [PATCH 3/3] wlan-ng/prism2mgmt.c Replace printk(...) with netdev_warn, netdev_err Sebastian Ehrenfels
2013-01-18 21:01       ` Greg Kroah-Hartman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121217140004.GQ5083@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@i4.informatik.uni-erlangen.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sisewank@cip.cs.fau.de \
    --cc=sisewank@faui49man10.informatik.uni-erlangen.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.