From d834303f5e642266874b1c99be04dcb9149fefb1 Mon Sep 17 00:00:00 2001 From: Vegard Storheil Eriksen Date: Fri, 15 Jan 2021 13:04:35 +0100 Subject: interrupt: Removed mf_vectors. --- interrupt/interrupt.h | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'interrupt/interrupt.h') diff --git a/interrupt/interrupt.h b/interrupt/interrupt.h index 80ccb76..0851c87 100644 --- a/interrupt/interrupt.h +++ b/interrupt/interrupt.h @@ -120,26 +120,6 @@ namespace Interrupt { inline void set_priority(IRQ n, uint8_t priority) { NVIC.IPR[n] = priority; } - - struct MFP { - void (*func_p)(void*); - void* instance_p; - }; - - extern MFP mf_vectors[]; - - template - inline void set_handler(IRQ n, void (T::*f)(), T* i) { - MFP& mfp = mf_vectors[16 + n]; - mfp.func_p = reinterpret_cast(f); - mfp.instance_p = i; - } - - template - inline void enable(IRQ n, void (T::*f)(), T* i) { - set_handler(n, f, i); - enable(n); - } }; template -- cgit v1.2.3