From: Ozgur <ozgur@goosey.org>
To: Philippe Loctaux <loctauxphilippe@gmail.com>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>
Cc: "devel@driverdev.osuosl.org" <devel@driverdev.osuosl.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 2/2] Staging: most: aim-sound: sound.c: removed unnecessary parentheses
Date: Fri, 29 Dec 2017 02:19:56 +0300 [thread overview]
Message-ID: <227541514503196@web8o.yandex.ru> (raw)
In-Reply-To: <20171228230650.12973-3-loctauxphilippe@gmail.com>
29.12.2017, 02:07, "Philippe Loctaux" <loctauxphilippe@gmail.com>:
> Removed unnecessary parentheses in a if statement.
>
> Signed-off-by: Philippe Loctaux <loctauxphilippe@gmail.com>
> ---
> drivers/staging/most/aim-sound/sound.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/most/aim-sound/sound.c b/drivers/staging/most/aim-sound/sound.c
> index ab2b0d833..0e79a4898 100644
> --- a/drivers/staging/most/aim-sound/sound.c
> +++ b/drivers/staging/most/aim-sound/sound.c
> @@ -166,7 +166,7 @@ static struct channel *get_channel(struct most_interface *iface,
> struct channel *channel, *tmp;
>
> list_for_each_entry_safe(channel, tmp, &dev_list, list) {
> - if ((channel->iface == iface) && (channel->id == channel_id))
> + if (channel->iface == iface && channel->id == channel_id)
> return channel;
> }
Hello,
I think this patch is not good, the code will not work. Please should understand in && operator and () why used with C.
Ozgur
> --
> 2.15.1
next prev parent reply other threads:[~2017-12-28 23:20 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-28 23:06 [PATCH 0/2] Staging: most: aim-sound: sound.c: coding style Philippe Loctaux
2017-12-28 23:06 ` [PATCH 1/2] Staging: most: aim-sound: sound.c: fixed an alignment issue Philippe Loctaux
2018-01-08 15:35 ` Greg KH
2017-12-28 23:06 ` [PATCH 2/2] Staging: most: aim-sound: sound.c: removed unnecessary parentheses Philippe Loctaux
2017-12-28 23:19 ` Ozgur [this message]
2017-12-29 14:50 ` Philippe Loctaux
2018-01-08 15:35 ` Greg KH
2017-12-28 23:14 ` [PATCH 0/2] Staging: most: aim-sound: sound.c: coding style Ozgur
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=227541514503196@web8o.yandex.ru \
--to=ozgur@goosey.org \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=loctauxphilippe@gmail.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox