From: Stefan Roese <sr@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] bootcounter_ram: Fix misaligned cache warning
Date: Fri, 18 Nov 2016 17:21:52 +0100 [thread overview]
Message-ID: <20161118162152.28948-2-sr@denx.de> (raw)
In-Reply-To: <20161118162152.28948-1-sr@denx.de>
This patch fixes the warning about misaligned cache on Armada XP:
CACHE: Misaligned operation at range [7ffff000, 7fffffac]
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Valentin Longchamp <valentin.longchamp@keymile.com>
---
drivers/bootcount/bootcount_ram.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/bootcount/bootcount_ram.c b/drivers/bootcount/bootcount_ram.c
index e0d2669..ad4cc56 100644
--- a/drivers/bootcount/bootcount_ram.c
+++ b/drivers/bootcount/bootcount_ram.c
@@ -37,7 +37,8 @@ void bootcount_store(ulong a)
/* Make sure the data is written to RAM */
flush_dcache_range((ulong)&save_addr[0],
- (ulong)&save_addr[REPEAT_PATTERN + OFFS_PATTERN]);
+ (((ulong)&save_addr[REPEAT_PATTERN + OFFS_PATTERN] &
+ ~(ARCH_DMA_MINALIGN - 1)) + ARCH_DMA_MINALIGN));
}
ulong bootcount_load(void)
--
2.10.2
next prev parent reply other threads:[~2016-11-18 16:21 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-18 16:21 [U-Boot] [PATCH] sata: sata_mv: Fix misaligned cache warnings Stefan Roese
2016-11-18 16:21 ` Stefan Roese [this message]
2016-11-21 14:01 ` [U-Boot] [PATCH] bootcounter_ram: Fix misaligned cache warning Tom Rini
2016-11-29 1:02 ` [U-Boot] " Tom Rini
2016-12-05 12:55 ` [U-Boot] [PATCH] sata: sata_mv: Fix misaligned cache warnings Stefan Roese
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=20161118162152.28948-2-sr@denx.de \
--to=sr@denx.de \
--cc=u-boot@lists.denx.de \
/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