diff options
author | Chris Johns <chrisj@rtems.org> | 2014-12-01 14:55:23 +1100 |
---|---|---|
committer | Chris Johns <chrisj@rtems.org> | 2014-12-01 14:55:23 +1100 |
commit | dd309b10544bfceda968ac847ad34c3d90ca8281 (patch) | |
tree | 87460bf9b0a723359ede9eede8fcaa74aa355ab0 /c/src/lib/libbsp/m68k/mcf5235/startup/copyvectors.c | |
parent | libmisc/shell: Edit history hack is corrupting memory. Remove it. (diff) | |
download | rtems-dd309b10544bfceda968ac847ad34c3d90ca8281.tar.bz2 |
m68k/mcf5235: GCC 4.9.2 generates invalid code for Init5235.
Move the vector table copy out of the Init5235 source to avoid
stipping the GCC bug.
Fixes #2204.
Diffstat (limited to '')
-rw-r--r-- | c/src/lib/libbsp/m68k/mcf5235/startup/copyvectors.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/m68k/mcf5235/startup/copyvectors.c b/c/src/lib/libbsp/m68k/mcf5235/startup/copyvectors.c new file mode 100644 index 0000000000..2c54c31a44 --- /dev/null +++ b/c/src/lib/libbsp/m68k/mcf5235/startup/copyvectors.c @@ -0,0 +1,19 @@ +/* + * Move the copy out of the Init5235 file because gcc is broken. + */ + +#include <stdint.h> + +void CopyVectors(const uint32_t* old, uint32_t* new); + +void CopyVectors(const uint32_t* old, uint32_t* new) +{ + int v = 0; + while (v < 256) + { + *new = *old; + ++v; + ++new; + ++old; + } +} |