mirror of
https://github.com/apache/nuttx.git
synced 2026-06-08 18:37:46 +08:00
esp32c3: Fix WDT incorrect interrupt enable/disable
This commit is contained in:
committed by
Petro Karashchenko
parent
9340d6e0d7
commit
119dabaf73
@@ -754,7 +754,7 @@ static int32_t esp32c3_wdt_setisr(struct esp32c3_wdt_dev_s *dev,
|
||||
* then deallocate it.
|
||||
*/
|
||||
|
||||
up_disable_irq(wdt->cpuint);
|
||||
up_disable_irq(wdt->irq);
|
||||
irq_detach(wdt->irq);
|
||||
esp32c3_teardown_irq(wdt->periph, wdt->cpuint);
|
||||
wdt->cpuint = -ENOMEM;
|
||||
@@ -818,7 +818,7 @@ static int32_t esp32c3_wdt_setisr(struct esp32c3_wdt_dev_s *dev,
|
||||
|
||||
/* Enable the CPU interrupt that is linked to the WDT. */
|
||||
|
||||
up_enable_irq(wdt->cpuint);
|
||||
up_enable_irq(wdt->irq);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user