diff options
Diffstat (limited to 'fw/fe310/eos/net.c')
-rw-r--r-- | fw/fe310/eos/net.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fw/fe310/eos/net.c b/fw/fe310/eos/net.c index 167a879..4d9aadf 100644 --- a/fw/fe310/eos/net.c +++ b/fw/fe310/eos/net.c @@ -311,6 +311,10 @@ static void net_start(void) { SPI1_REG(SPI_REG_CSID) = eos_spi_csid(EOS_SPI_DEV_NET); } +static void net_stop(void) { + eos_intr_set_handler(INT_SPI1_BASE, NULL); +} + int eos_net_init(uint8_t wakeup_cause) { int i; @@ -400,6 +404,7 @@ void eos_net_stop(void) { if (!done) asm volatile ("wfi"); set_csr(mstatus, MSTATUS_MIE); } + net_stop(); } int eos_net_sleep(uint32_t timeout) { |