[PATCH v6 13/19] riscv: Fix race conditions when initializing IPI