From: Andre Przywara Date: Sun, 8 Nov 2020 13:14:05 +0000 Subject: [PATCH 1/5] sunxi: Fix is_boot0_magic macro In-Reply-To: <20201108131409.14320-1-andre.przywara@arm.com> References: <20201108131409.14320-1-andre.przywara@arm.com> Message-ID: <20201108131409.14320-2-andre.przywara@arm.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de The is_boot0_magic macro is missing parentheses around the macro argument, breaking any usage with a more complex argument. Signed-off-by: Andre Przywara --- arch/arm/include/asm/arch-sunxi/spl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/include/asm/arch-sunxi/spl.h b/arch/arm/include/asm/arch-sunxi/spl.h index 8c916e8c752..6b3566f55e5 100644 --- a/arch/arm/include/asm/arch-sunxi/spl.h +++ b/arch/arm/include/asm/arch-sunxi/spl.h @@ -83,7 +83,7 @@ struct boot_file_head { /* Compile time check to assure proper alignment of structure */ typedef char boot_file_head_not_multiple_of_32[1 - 2*(sizeof(struct boot_file_head) % 32)]; -#define is_boot0_magic(addr) (memcmp((void *)addr, BOOT0_MAGIC, 8) == 0) +#define is_boot0_magic(addr) (memcmp((void *)(addr), BOOT0_MAGIC, 8) == 0) uint32_t sunxi_get_boot_device(void); -- 2.17.5