add TargetClass support
[project/usbmode.git] / switch.h
index 441e6a3ac559f5e93b04964932ba59eb934f8fd9..e4993267bbe112773ad50bae47cc2ff8b0bb0363 100644 (file)
--- a/switch.h
+++ b/switch.h
@@ -7,12 +7,14 @@
 struct usbdev_data {
        struct libusb_device_descriptor desc;
        struct libusb_config_descriptor *config;
+       libusb_device *dev;
        libusb_device_handle *devh;
        struct blob_attr *info;
        int interface;
        int msg_endpoint;
        int response_endpoint;
        int release_delay;
+       int dev_class;
        bool need_response;
 
        char idstr[10];
@@ -22,6 +24,7 @@ struct usbdev_data {
 extern char **messages;
 extern int *message_len;
 extern int n_messages;
+extern struct libusb_context *usb;
 
 void handle_switch(struct usbdev_data *data);