[PATCH 5/7] netX: XPEC firmware is always of attribute const
Juergen Beisert
jbe at pengutronix.de
Fri Apr 27 05:32:23 EDT 2012
Signed-off-by: Juergen Beisert <jbe at pengutronix.de>
---
arch/arm/mach-netx/generic.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/arch/arm/mach-netx/generic.c b/arch/arm/mach-netx/generic.c
index f9d643f..5ce7a0d 100644
--- a/arch/arm/mach-netx/generic.c
+++ b/arch/arm/mach-netx/generic.c
@@ -45,9 +45,10 @@ static int xc_check_ptr(int xcno, unsigned long adr, unsigned int size)
return -1;
}
-static int xc_patch(int xcno, void *patch, int count)
+static int xc_patch(int xcno, const void *patch, int count)
{
- unsigned int adr, val, *p = patch;
+ unsigned int adr, val;
+ const unsigned int *p = patch;
int i;
for (i = 0; i < count; i++) {
@@ -69,11 +70,11 @@ static void memset32(void *s, int c, int n)
*t++ = 0;
}
-static void memcpy32(void *trg, void *src, int size)
+static void memcpy32(void *trg, const void *src, int size)
{
int i;
u32 *t = trg;
- u32 *s = src;
+ const u32 *s = src;
for (i = 0; i < (size >> 2); i++)
*t++ = *s++;
}
--
1.7.10
More information about the barebox
mailing list