]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/usb.h
USB: make usbdevices export their device nodes instead of using a separate class
[linux-2.6-omap-h63xx.git] / include / linux / usb.h
index 87dc75a6cee14e00a755cc49f9dd50e567373e19..f9e4445d5b53fe00c06d9fa154059a2499d31402 100644 (file)
@@ -299,8 +299,9 @@ struct usb_bus {
        int bandwidth_int_reqs;         /* number of Interrupt requests */
        int bandwidth_isoc_reqs;        /* number of Isoc. requests */
 
+#ifdef CONFIG_USB_DEVICEFS
        struct dentry *usbfs_dentry;    /* usbfs dentry entry for the bus */
-
+#endif
        struct class_device *class_dev; /* class device for this bus */
 
 #if defined(CONFIG_USB_MON)
@@ -373,9 +374,12 @@ struct usb_device {
        char *serial;                   /* iSerialNumber string, if present */
 
        struct list_head filelist;
-       struct device *usbfs_dev;
+#ifdef CONFIG_USB_DEVICE_CLASS
+       struct device *usb_classdev;
+#endif
+#ifdef CONFIG_USB_DEVICEFS
        struct dentry *usbfs_dentry;    /* usbfs dentry entry for the device */
-
+#endif
        /*
         * Child devices - these can be either new devices
         * (if this is a hub device), or different instances
@@ -394,10 +398,12 @@ struct usb_device {
        struct delayed_work autosuspend; /* for delayed autosuspends */
        struct mutex pm_mutex;          /* protects PM operations */
 
-       unsigned autosuspend_delay;     /* in jiffies */
+       int autosuspend_delay;          /* in jiffies */
 
        unsigned auto_pm:1;             /* autosuspend/resume in progress */
        unsigned do_remote_wakeup:1;    /* remote wakeup should be enabled */
+       unsigned autosuspend_disabled:1; /* autosuspend and autoresume */
+       unsigned autoresume_disabled:1;  /*  disabled by the user */
 #endif
 };
 #define        to_usb_device(d) container_of(d, struct usb_device, dev)