From: "Omar Yiğitcan Mengü" <menguomary@gmail.com>
To: Viresh Kumar <vireshk@kernel.org>,
Johan Hovold <johan@kernel.org>, Alex Elder <elder@kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Dan Carpenter" <error27@gmail.com>,
greybus-dev@lists.linaro.org, linux-staging@lists.linux.dev,
"Omar Yiğitcan Mengü" <menguomary@gmail.com>
Subject: [PATCH v2] staging: greybus: bootrom: fix firmware size endianness in debug log
Date: Fri, 4 Dec 2026 21:25:25 +0300 [thread overview]
Message-ID: <20261204182526.414-1-menguomary@gmail.com> (raw)
In gb_bootrom_firmware_size_request(), size_response->size is a __le32
field populated with cpu_to_le32(bootrom->fw->size). Printing
size_response->size directly with %u outputs a byte-swapped value on
big-endian hosts.
Print bootrom->fw->size directly with %zu instead so the logged size is
always in host byte order.
Signed-off-by: Omar Yiğitcan Mengü <menguomary@gmail.com>
---
Changes in v2:
- Resend using git send-email to avoid line wrapping.
drivers/staging/greybus/bootrom.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/greybus/bootrom.c b/drivers/staging/greybus/bootrom.c
index fb1fbd3f7b9..4e225084851 100644
--- a/drivers/staging/greybus/bootrom.c
+++ b/drivers/staging/greybus/bootrom.c
@@ -222,8 +222,8 @@ static int gb_bootrom_firmware_size_request(struct gb_operation *op)
size_response = op->response->payload;
size_response->size = cpu_to_le32(bootrom->fw->size);
- dev_dbg(dev, "%s: firmware size %u bytes\n",
- __func__, size_response->size);
+ dev_dbg(dev, "%s: firmware size %zu bytes\n",
+ __func__, bootrom->fw->size);
unlock:
mutex_unlock(&bootrom->mutex);
--
2.53.0
reply other threads:[~2026-12-04 18:25 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20261204182526.414-1-menguomary@gmail.com \
--to=menguomary@gmail.com \
--cc=elder@kernel.org \
--cc=error27@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=greybus-dev@lists.linaro.org \
--cc=johan@kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=vireshk@kernel.org \
/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