From 5b74fd2352297c6f97042b42b946f04c3d55ba11 Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Tue, 13 Jul 2010 00:46:25 +0200 Subject: gcc: add __ramdata definition Data used in RAM functions should also be stored in RAM. This definition is needed because gcc will place static data which are never modified to .rodata section. --- AT91SAM7S256/Source/stdconst.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'AT91SAM7S256/Source/stdconst.h') diff --git a/AT91SAM7S256/Source/stdconst.h b/AT91SAM7S256/Source/stdconst.h index 07ffd87..bf8f052 100644 --- a/AT91SAM7S256/Source/stdconst.h +++ b/AT91SAM7S256/Source/stdconst.h @@ -64,6 +64,9 @@ typedef char* PSZ; #ifdef __GNUC__ #define __ramfunc __attribute__ ((section (".fastrun"), optimize ("no-jump-tables"))) +#define __ramdata __attribute__ ((section (".data"))) +#else +#define __ramdata #endif #endif -- cgit v1.2.3