-
Notifications
You must be signed in to change notification settings - Fork 66
Expand file tree
/
Copy pathcircle_patch.diff
More file actions
62 lines (53 loc) · 1.73 KB
/
Copy pathcircle_patch.diff
File metadata and controls
62 lines (53 loc) · 1.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
diff --git a/addon/linux/bug.h b/addon/linux/bug.h
index 6b80534d..656accef 100644
--- a/addon/linux/bug.h
+++ b/addon/linux/bug.h
@@ -9,7 +9,7 @@
extern "C" {
#endif
-#define BUG_ON(exp) assert (!(exp))
+#define BUG_ON(exp) ;
#define BUG() assert (0)
void __warn (const char *file, const int line);
diff --git a/include/circle/sysconfig.h b/include/circle/sysconfig.h
index 566e6eb7..fed5f043 100644
--- a/include/circle/sysconfig.h
+++ b/include/circle/sysconfig.h
@@ -155,7 +155,7 @@
// single core applications, because this may slow down the system
// because multiple cores may compete for bus time without use.
-//#define ARM_ALLOW_MULTI_CORE
+#define ARM_ALLOW_MULTI_CORE
#endif
@@ -236,7 +236,7 @@
// used for other purposes. This option has no influence on the
// Raspberry Pi 4 and 5.
-//#define USE_USB_FIQ
+#define USE_USB_FIQ
#ifdef USE_USB_FIQ
#define USE_USB_SOF_INTR
@@ -251,7 +251,7 @@
#ifndef NO_SCREEN_DMA_BURST_LENGTH
#ifndef SCREEN_DMA_BURST_LENGTH
-#define SCREEN_DMA_BURST_LENGTH 2
+#define NO_SCREEN_DMA_BURST_LENGTH
#endif
#endif
diff --git a/lib/usb/usbkeyboard.cpp b/lib/usb/usbkeyboard.cpp
index 05fe2fab..cd375e9a 100644
--- a/lib/usb/usbkeyboard.cpp
+++ b/lib/usb/usbkeyboard.cpp
@@ -61,8 +61,12 @@ boolean CUSBKeyboardDevice::Configure (void)
// which has to be ignored.
const TUSBDeviceDescriptor *pDeviceDesc = GetDevice ()->GetDeviceDescriptor ();
assert (pDeviceDesc != 0);
+ const TUSBHIDDescriptor *pHIDDesc =
+ (const TUSBHIDDescriptor *) GetDescriptor (DESCRIPTOR_HID);
if ( pDeviceDesc->idVendor == 0x1C59
- && pDeviceDesc->idProduct == 0x99)
+ && pDeviceDesc->idProduct == 0x99
+ && pHIDDesc != 0
+ && pHIDDesc->wReportDescriptorLength == 78)
{
m_nReportSize++;
}