From: Dan Carpenter <dan.carpenter@oracle.com>
To: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Cc: stefan.wahren@i2se.com, devel@driverdev.osuosl.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
phil@raspberrypi.org, linux-kernel@vger.kernel.org,
Eric Anholt <eric@anholt.net>,
linux-rpi-kernel@lists.infradead.org,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2 2/3] staging: vchiq: revert "switch to wait_for_completion_killable"
Date: Mon, 6 May 2019 18:20:39 +0300 [thread overview]
Message-ID: <20190506152039.GT2239@kadam> (raw)
In-Reply-To: <20190506144030.29056-3-nsaenzjulienne@suse.de>
On Mon, May 06, 2019 at 04:40:29PM +0200, Nicolas Saenz Julienne wrote:
> @@ -1740,7 +1740,8 @@ parse_rx_slots(struct vchiq_state *state)
> &service->bulk_rx : &service->bulk_tx;
>
> DEBUG_TRACE(PARSE_LINE);
> - if (mutex_lock_killable(&service->bulk_mutex)) {
> + if (mutex_lock_killable(
> + &service->bulk_mutex) != 0) {
This series does't add != 0 consistently... Personally, I would prefer
we just leave it out. I use != 0 for two things. 1) When I'm talking
about the number zero.
if (len == 0) {
Or with strcmp():
if (strcmp(a, b) == 0) { // a equals b
if (strcmp(a, b) < 0) { // a less than b.
But here zero means no errors, so I would just leave it out...
regards,
dan carpenter
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Cc: linux-kernel@vger.kernel.org, phil@raspberrypi.org,
stefan.wahren@i2se.com, Eric Anholt <eric@anholt.net>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-rpi-kernel@lists.infradead.org,
linux-arm-kernel@lists.infradead.org, devel@driverdev.osuosl.org
Subject: Re: [PATCH v2 2/3] staging: vchiq: revert "switch to wait_for_completion_killable"
Date: Mon, 6 May 2019 18:20:39 +0300 [thread overview]
Message-ID: <20190506152039.GT2239@kadam> (raw)
In-Reply-To: <20190506144030.29056-3-nsaenzjulienne@suse.de>
On Mon, May 06, 2019 at 04:40:29PM +0200, Nicolas Saenz Julienne wrote:
> @@ -1740,7 +1740,8 @@ parse_rx_slots(struct vchiq_state *state)
> &service->bulk_rx : &service->bulk_tx;
>
> DEBUG_TRACE(PARSE_LINE);
> - if (mutex_lock_killable(&service->bulk_mutex)) {
> + if (mutex_lock_killable(
> + &service->bulk_mutex) != 0) {
This series does't add != 0 consistently... Personally, I would prefer
we just leave it out. I use != 0 for two things. 1) When I'm talking
about the number zero.
if (len == 0) {
Or with strcmp():
if (strcmp(a, b) == 0) { // a equals b
if (strcmp(a, b) < 0) { // a less than b.
But here zero means no errors, so I would just leave it out...
regards,
dan carpenter
next prev parent reply other threads:[~2019-05-06 15:21 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-06 14:40 [PATCH v2 0/3] staging: vchiq: use interruptible waits Nicolas Saenz Julienne
2019-05-06 14:40 ` Nicolas Saenz Julienne
2019-05-06 14:40 ` [PATCH v2 1/3] staging: vchiq_2835_arm: revert "quit using custom down_interruptible()" Nicolas Saenz Julienne
2019-05-06 14:40 ` Nicolas Saenz Julienne
2019-05-06 14:40 ` [PATCH v2 2/3] staging: vchiq: revert "switch to wait_for_completion_killable" Nicolas Saenz Julienne
2019-05-06 14:40 ` Nicolas Saenz Julienne
2019-05-06 15:20 ` Dan Carpenter [this message]
2019-05-06 15:20 ` Dan Carpenter
2019-05-06 15:59 ` Nicolas Saenz Julienne
2019-05-06 15:59 ` Nicolas Saenz Julienne
2019-05-06 16:28 ` Stefan Wahren
2019-05-06 16:28 ` Stefan Wahren
2019-05-07 5:54 ` Dan Carpenter
2019-05-07 5:54 ` Dan Carpenter
2019-05-06 14:40 ` [PATCH v2 3/3] staging: vchiq: make wait events interruptible Nicolas Saenz Julienne
2019-05-06 14:40 ` Nicolas Saenz Julienne
2019-05-06 18:12 ` [PATCH v2 0/3] staging: vchiq: use interruptible waits Stefan Wahren
2019-05-06 18:12 ` Stefan Wahren
2019-05-06 18:51 ` Nicolas Saenz Julienne
2019-05-06 18:51 ` Nicolas Saenz Julienne
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=20190506152039.GT2239@kadam \
--to=dan.carpenter@oracle.com \
--cc=devel@driverdev.osuosl.org \
--cc=eric@anholt.net \
--cc=gregkh@linuxfoundation.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=nsaenzjulienne@suse.de \
--cc=phil@raspberrypi.org \
--cc=stefan.wahren@i2se.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 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.