bsps: Fix rtems_interrupt_server_delete()

The ISR lock must be destroyed to prevent memory corruption if RTEMS_PROFILING
and RTEMS_SMP is enabled.

Close #4189.
This commit is contained in:
Sebastian Huber
2020-10-19 17:39:10 +02:00
parent 0af682cf5d
commit 1dbdf94e67

View File

@@ -682,6 +682,8 @@ static void bsp_interrupt_server_destroy_helper(void *arg)
rtems_chain_extract_unprotected(&s->node); rtems_chain_extract_unprotected(&s->node);
bsp_interrupt_unlock(); bsp_interrupt_unlock();
rtems_interrupt_lock_destroy(&s->lock);
if (s->destroy != NULL) { if (s->destroy != NULL) {
(*s->destroy)(s); (*s->destroy)(s);
} }