From: Sascha Hauer <s.hauer@pengutronix.de>
To: Barebox List <barebox@lists.infradead.org>
Subject: [PATCH 3/4] pblimage: use roundup() from kernel.h
Date: Tue, 19 Dec 2023 14:00:39 +0100 [thread overview]
Message-ID: <20231219130040.4115-4-s.hauer@pengutronix.de> (raw)
In-Reply-To: <20231219130040.4115-1-s.hauer@pengutronix.de>
We already have roundup() defined in linux/kernel.h, so use it instead
of adding a local definition.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
scripts/pblimage.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/pblimage.c b/scripts/pblimage.c
index d0a589f2fe..e8108bbb17 100644
--- a/scripts/pblimage.c
+++ b/scripts/pblimage.c
@@ -14,12 +14,12 @@
#include <getopt.h>
#include <endian.h>
#include <byteswap.h>
+#include <linux/kernel.h>
#include "common.h"
#include "common.c"
#include "../crypto/crc32.c"
-#define roundup(x, y) ((((x) + ((y) - 1)) / (y)) * (y))
#define PBL_ACS_CONT_CMD 0x81000000
#define PBL_ADDR_24BIT_MASK 0x00ffffff
--
2.39.2
next prev parent reply other threads:[~2023-12-19 13:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-19 13:00 [PATCH 0/4] Layerscape LS1028a pblimage support Sascha Hauer
2023-12-19 13:00 ` [PATCH 1/4] pblimage: drop PowerPC support Sascha Hauer
2023-12-19 13:00 ` [PATCH 2/4] pblimage: simplify a bit Sascha Hauer
2023-12-19 13:00 ` Sascha Hauer [this message]
2023-12-19 13:00 ` [PATCH 4/4] pblimage: Add LS1028a support Sascha Hauer
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=20231219130040.4115-4-s.hauer@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.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