[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMuHMdW4Onwp+-eaGDLrqHRqZcHgWjHLRJ1r-gcAh4tYRkNPtQ@mail.gmail.com>
Date: Wed, 15 Feb 2017 09:14:30 +0100
From: Geert Uytterhoeven <geert@...ux-m68k.org>
To: Greg KH <gregkh@...uxfoundation.org>
Cc: Arushi Singhal <arushisinghal19971997@...il.com>,
driverdevel <devel@...verdev.osuosl.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] staging: fwserial: replace 'a' with '(a)' to avoid
precedence issues
On Tue, Feb 14, 2017 at 7:08 PM, Greg KH <gregkh@...uxfoundation.org> wrote:
> On Tue, Feb 14, 2017 at 11:26:20PM +0530, Arushi Singhal wrote:
>> Macro argument 'a' may be better as '(a)' to avoid precedence issues as
>> reported by checkpatch.pl
>>
>> Signed-off-by: Arushi Singhal <arushisinghal19971997@...il.com>
>> ---
>> drivers/staging/fwserial/fwserial.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/staging/fwserial/fwserial.c b/drivers/staging/fwserial/fwserial.c
>> index 41a49c8194e5..bdfc0a8c7af3 100644
>> --- a/drivers/staging/fwserial/fwserial.c
>> +++ b/drivers/staging/fwserial/fwserial.c
>> @@ -98,7 +98,7 @@ struct fwtty_transaction {
>> };
>> };
>>
>> -#define to_device(a, b) (a->b)
>> +#define to_device((a), b) (a->b)
>
> Really?
Actually compiling files should be a requirement for submitting patches,
cfr. the response from kbuild test report.
The parentheses should be added to the second "a" instead ;-)
> Why do we even have this macro at all? Can it just be removed?
Definitely. Would be much easier to read.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
Powered by blists - more mailing lists