From: Steffen Trumtrar <s.trumtrar@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Steffen Trumtrar <s.trumtrar@pengutronix.de>
Subject: [PATCH v4 6/8] ARM: socfpga: achilles: guard macros with braces
Date: Mon, 1 Aug 2022 14:07:06 +0200 [thread overview]
Message-ID: <20220801120708.2511165-6-s.trumtrar@pengutronix.de> (raw)
In-Reply-To: <20220801120708.2511165-1-s.trumtrar@pengutronix.de>
Macro definitions should be guarded with braces for safer use.
Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
---
arch/arm/boards/reflex-achilles/lowlevel.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/arch/arm/boards/reflex-achilles/lowlevel.c b/arch/arm/boards/reflex-achilles/lowlevel.c
index 2efb9aaea0..ec8c126c2a 100644
--- a/arch/arm/boards/reflex-achilles/lowlevel.c
+++ b/arch/arm/boards/reflex-achilles/lowlevel.c
@@ -23,15 +23,16 @@
#define BAREBOX_PART 0
#define BITSTREAM_PART 1
#define BAREBOX1_OFFSET SZ_1M
-#define BAREBOX2_OFFSET BAREBOX1_OFFSET + SZ_512K
-#define BAREBOX3_OFFSET BAREBOX2_OFFSET + SZ_512K
-#define BAREBOX4_OFFSET BAREBOX3_OFFSET + SZ_512K
+#define BAREBOX2_OFFSET (BAREBOX1_OFFSET + SZ_512K)
+#define BAREBOX3_OFFSET (BAREBOX2_OFFSET + SZ_512K)
+#define BAREBOX4_OFFSET (BAREBOX3_OFFSET + SZ_512K)
+// Offset from the start of the second partition on the eMMC.
#define BITSTREAM1_OFFSET 0x0
-#define BITSTREAM2_OFFSET BITSTREAM1_OFFSET + SZ_32M
+#define BITSTREAM2_OFFSET (BITSTREAM1_OFFSET + SZ_32M)
extern char __dtb_z_socfpga_arria10_achilles_start[];
-#define ARRIA10_STACKTOP ARRIA10_OCRAM_ADDR + SZ_256K
+#define ARRIA10_STACKTOP (ARRIA10_OCRAM_ADDR + SZ_256K)
ENTRY_FUNCTION_WITHSTACK(start_socfpga_achilles_xload, ARRIA10_STACKTOP, r0, r1, r2)
{
--
2.30.2
next prev parent reply other threads:[~2022-08-01 12:19 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-01 12:07 [PATCH v4 1/8] scripts: socfgpa_xml_to_config: document pincfg Steffen Trumtrar
2022-08-01 12:07 ` [PATCH v4 2/8] ARM: socfpga: achilles: remove cargo-cult Steffen Trumtrar
2022-08-01 12:07 ` [PATCH v4 3/8] ARM: socfpga: achilles: use dtbz instead of dtb Steffen Trumtrar
2022-08-01 12:07 ` [PATCH v4 4/8] ARM: socfpga: achilles: use ENTRY_FUNCTION_WITHSTACK Steffen Trumtrar
2022-08-01 12:07 ` [PATCH v4 5/8] ARM: socfpga: achilles: replace use of magicvalue Steffen Trumtrar
2022-08-01 12:07 ` Steffen Trumtrar [this message]
2022-08-01 12:07 ` [PATCH v4 7/8] ARM: socfpga: add support for Enclustra AA1 Steffen Trumtrar
2022-08-01 12:07 ` [PATCH v4 8/8] ARM: socfpga: defconfig: add aa1 Steffen Trumtrar
2022-08-08 13:10 ` [PATCH v4 1/8] scripts: socfgpa_xml_to_config: document pincfg 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=20220801120708.2511165-6-s.trumtrar@pengutronix.de \
--to=s.trumtrar@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