X-Git-Url: https://git.friedersdorff.com/?a=blobdiff_plain;f=vusb%2Fhost.c;h=901537bcb89bd3c94d5f88b6e24c667723c4884c;hb=cec254950509038ca9c805e87feea9091d77d29f;hp=05a1f29cd19716ed368f074a5ebe7ad47a63b086;hpb=1a7c3585ed9a68099e371b3180a404dd5d08ce1a;p=max%2Ftmk_keyboard.git diff --git a/vusb/host.c b/vusb/host.c index 05a1f29c..901537bc 100644 --- a/vusb/host.c +++ b/vusb/host.c @@ -1,3 +1,5 @@ +#include +#include #include "usbdrv.h" #include "usbconfig.h" #include "print.h" @@ -63,9 +65,12 @@ void host_add_code(uint8_t code) void host_swap_keyboard_report(void) { + uint8_t sreg = SREG; + cli(); report_keyboard_t *tmp = keyboard_report_prev; keyboard_report_prev = keyboard_report; keyboard_report = tmp; + SREG = sreg; } void host_clear_keyboard_report(void)