From: Olav Morken <olav...@gmail.com> The AT32UC3A0512ES chip has a bug when disabling interrupts. As a workaround, two NOPs can be inserted.
Signed-off-by: Gunnar Rangoy <gun...@rangoy.com> Signed-off-by: Paul Driveklepp <pauldrivekl...@gmail.com> Signed-off-by: Olav Morken <olav...@gmail.com> --- lib_avr32/interrupts.c | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/lib_avr32/interrupts.c b/lib_avr32/interrupts.c index 28df20d..bbbc490 100644 --- a/lib_avr32/interrupts.c +++ b/lib_avr32/interrupts.c @@ -35,5 +35,12 @@ int disable_interrupts(void) sr = sysreg_read(SR); asm volatile("ssrf %0" : : "n"(SYSREG_GM_OFFSET)); +#ifdef CONFIG_AT32UC3A0xxx + /* Two NOPs are required after masking interrupts on the + * AT32UC3A0512ES. See errata 41.4.5.5. */ + asm("nop"); + asm("nop"); +#endif + return !SYSREG_BFEXT(GM, sr); } -- 1.6.0.4 _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot