diff --git a/ch32v003fun/ch32v003fun.c b/ch32v003fun/ch32v003fun.c index 92b0bd2176c2ed8420848857da4222bf75c42fa9..014f0e4751e222f02ffae27c3451f38dc02c102e 100644 --- a/ch32v003fun/ch32v003fun.c +++ b/ch32v003fun/ch32v003fun.c @@ -783,7 +783,8 @@ void handle_reset() csrw 0x804, a3\n\ la a0, InterruptVector\n\ or a0, a0, a3\n\ - csrw mtvec, a0\n" ); + csrw mtvec, a0\n" + : : : "a0", "a3", "memory"); // Careful: Use registers to prevent overwriting of self-data. // This clears out BSS.