hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/usb/class/cdc-acm.h
....@@ -66,12 +66,12 @@
6666 #define ACM_NR 16
6767
6868 struct acm_wb {
69
- unsigned char *buf;
69
+ u8 *buf;
7070 dma_addr_t dmah;
71
- int len;
72
- int use;
71
+ unsigned int len;
7372 struct urb *urb;
7473 struct acm *instance;
74
+ bool use;
7575 };
7676
7777 struct acm_rb {
....@@ -110,6 +110,7 @@
110110 unsigned long flags;
111111 # define EVENT_TTY_WAKEUP 0
112112 # define EVENT_RX_STALL 1
113
+# define ACM_THROTTLED 2
113114 # define ACM_ERROR_DELAY 3
114115 unsigned long urbs_in_error_delay; /* these need to be restarted after a delay */
115116 struct usb_cdc_line_coding line; /* bits, stop, parity */
....@@ -126,22 +127,17 @@
126127 unsigned int ctrl_caps; /* control capabilities from the class specific header */
127128 unsigned int susp_count; /* number of suspended interfaces */
128129 unsigned int combined_interfaces:1; /* control and data collapsed */
129
- unsigned int throttled:1; /* actually throttled */
130
- unsigned int throttle_req:1; /* throttle requested */
131130 u8 bInterval;
132131 struct usb_anchor delayed; /* writes queued for a device about to be woken */
133132 unsigned long quirks;
134133 };
135134
136
-#define CDC_DATA_INTERFACE_TYPE 0x0a
137
-
138135 /* constants describing various quirks and errors */
139136 #define NO_UNION_NORMAL BIT(0)
140137 #define SINGLE_RX_URB BIT(1)
141138 #define NO_CAP_LINE BIT(2)
142
-#define NO_DATA_INTERFACE BIT(4)
143
-#define IGNORE_DEVICE BIT(5)
144
-#define QUIRK_CONTROL_LINE_STATE BIT(6)
145
-#define CLEAR_HALT_CONDITIONS BIT(7)
146
-#define SEND_ZERO_PACKET BIT(8)
147
-#define DISABLE_ECHO BIT(9)
139
+#define IGNORE_DEVICE BIT(3)
140
+#define QUIRK_CONTROL_LINE_STATE BIT(4)
141
+#define CLEAR_HALT_CONDITIONS BIT(5)
142
+#define SEND_ZERO_PACKET BIT(6)
143
+#define DISABLE_ECHO BIT(7)