summaryrefslogtreecommitdiff
path: root/firmware/usbstack/usb_core.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/usbstack/usb_core.c')
-rw-r--r--firmware/usbstack/usb_core.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/firmware/usbstack/usb_core.c b/firmware/usbstack/usb_core.c
index 8e32e3501f..63df173033 100644
--- a/firmware/usbstack/usb_core.c
+++ b/firmware/usbstack/usb_core.c
@@ -264,7 +264,6 @@ static struct usb_class_driver drivers[USB_NUM_DRIVERS] =
264}; 264};
265 265
266#ifdef USB_LEGACY_CONTROL_API 266#ifdef USB_LEGACY_CONTROL_API
267static struct usb_ctrlrequest active_request_buf;
268static struct usb_ctrlrequest* volatile active_request = NULL; 267static struct usb_ctrlrequest* volatile active_request = NULL;
269static void* volatile control_write_data = NULL; 268static void* volatile control_write_data = NULL;
270static volatile bool control_write_data_done = false; 269static volatile bool control_write_data_done = false;
@@ -1020,8 +1019,7 @@ void usb_core_control_complete(int status)
1020/* Only needed if the driver does not support the new API yet */ 1019/* Only needed if the driver does not support the new API yet */
1021void usb_core_legacy_control_request(struct usb_ctrlrequest* req) 1020void usb_core_legacy_control_request(struct usb_ctrlrequest* req)
1022{ 1021{
1023 memcpy(&active_request_buf, req, sizeof(*req)); 1022 active_request = req;
1024 active_request = &active_request_buf;
1025 control_write_data = NULL; 1023 control_write_data = NULL;
1026 control_write_data_done = false; 1024 control_write_data_done = false;
1027 1025