From 2d6bf67be33c28991fc9ab439a9fa28962ec8dd8 Mon Sep 17 00:00:00 2001 From: Tomasz Kramkowski Date: Sat, 25 Mar 2017 10:54:23 +0000 Subject: usb: cleanup usb.c --- lib/cm4.h | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 lib/cm4.h (limited to 'lib') diff --git a/lib/cm4.h b/lib/cm4.h new file mode 100644 index 0000000..7c1c774 --- /dev/null +++ b/lib/cm4.h @@ -0,0 +1,10 @@ +#ifndef LIB_CM4_H +#define LIB_CM4_H + +#define CLRPEND(n) REG_32(0xE000E280 + 4 * (n)) +#define ISR_CLRPEND(i) CLRPEND((i) / 32) = BV((i) % 32); + +#define SETENA(n) REG_32(0xE000E100 + 4 * (n)) +#define ISR_SETENA(i) SETENA((i) / 32) = BV((i) % 32); + +#endif /* LIB_CM4_H */ -- cgit v1.2.3-54-g00ecf