From: Sander Speetjens <sander.speetjens@gmail.com>
To: Florian Fainelli <florian.fainelli@broadcom.com>,
Broadcom internal kernel review list
<bcm-kernel-feedback-list@broadcom.com>,
Eric Anholt <eric@anholt.net>, Stefan Wahren <wahrenst@gmx.net>,
Stephen Boyd <sboyd@kernel.org>,
Nicolas Saenz Julienne <nsaenz@kernel.org>
Cc: linux-rpi-kernel@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, sander.speetjens@gmail.com
Subject: [PATCH 4/6] firmware: raspberrypi: Remove unnecessary braces in transaction helper
Date: Sat, 07 Nov 2026 17:38:08 +0100 [thread overview]
Message-ID: <20261107-fix-raspberrypi-firmware-v1-4-707362c710cd@gmail.com> (raw)
In-Reply-To: <20261107-fix-raspberrypi-firmware-v1-0-707362c710cd@gmail.com>
Braces are not needed around the single-statement arms of the
wait_for_completion_timeout() check.
Signed-off-by: Sander Speetjens <sander.speetjens@gmail.com>
---
drivers/firmware/raspberrypi.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/firmware/raspberrypi.c b/drivers/firmware/raspberrypi.c
index 04163c3f385d..d9a569a6dae7 100644
--- a/drivers/firmware/raspberrypi.c
+++ b/drivers/firmware/raspberrypi.c
@@ -60,11 +60,10 @@ rpi_firmware_transaction(struct rpi_firmware *fw, u32 chan, u32 data)
reinit_completion(&fw->c);
ret = mbox_send_message(fw->chan, &message);
if (ret >= 0) {
- if (wait_for_completion_timeout(&fw->c, HZ)) {
+ if (wait_for_completion_timeout(&fw->c, HZ))
ret = 0;
- } else {
+ else
ret = -ETIMEDOUT;
- }
} else {
dev_err(fw->cl.dev, "mbox_send_message returned %d\n", ret);
}
--
2.56.0
next prev parent reply other threads:[~2026-11-07 16:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-07 16:38 [PATCH 0/6] firmware: raspberrypi: Style cleanups and registration error handling Sander Speetjens
2026-11-07 16:38 ` [PATCH 1/6] firmware: raspberrypi: Add blank line after declaration in response_callback Sander Speetjens
2026-11-07 16:38 ` [PATCH 2/6] firmware: raspberrypi: Fix indentation of return statement Sander Speetjens
2026-11-07 16:38 ` [PATCH 3/6] firmware: raspberrypi: Add blank line after declaration in probe error path Sander Speetjens
2026-11-07 16:38 ` Sander Speetjens [this message]
2026-11-07 16:38 ` [PATCH 5/6] firmware: raspberrypi: Document memory barriers in property list path Sander Speetjens
2026-11-07 16:38 ` [PATCH 6/6] firmware: raspberrypi: Handle device registration errors Sander Speetjens
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=20261107-fix-raspberrypi-firmware-v1-4-707362c710cd@gmail.com \
--to=sander.speetjens@gmail.com \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=eric@anholt.net \
--cc=florian.fainelli@broadcom.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=nsaenz@kernel.org \
--cc=sboyd@kernel.org \
--cc=wahrenst@gmx.net \
/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
all inboxes | Powered by JetHome®