aboutsummaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/g_zero.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/gadget/g_zero.h')
-rw-r--r--drivers/usb/gadget/g_zero.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/usb/gadget/g_zero.h b/drivers/usb/gadget/g_zero.h
index 19ec50a42a74..15f180904f8a 100644
--- a/drivers/usb/gadget/g_zero.h
+++ b/drivers/usb/gadget/g_zero.h
@@ -8,6 +8,8 @@
#define GZERO_BULK_BUFLEN 4096
#define GZERO_QLEN 32
+#define GZERO_ISOC_INTERVAL 4
+#define GZERO_ISOC_MAXPACKET 1024
struct usb_zero_options {
unsigned pattern;
@@ -27,6 +29,15 @@ struct f_ss_opts {
unsigned isoc_mult;
unsigned isoc_maxburst;
unsigned bulk_buflen;
+
+ /*
+ * Read/write access to configfs attributes is handled by configfs.
+ *
+ * This is to protect the data from concurrent access by read/write
+ * and create symlink/remove symlink.
+ */
+ struct mutex lock;
+ int refcnt;
};
struct f_lb_opts {