Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzi...
[cascardo/linux.git] / include / linux / usb.h
index 24300d8..bd69b65 100644 (file)
@@ -20,6 +20,7 @@
 #include <linux/completion.h>  /* for struct completion */
 #include <linux/sched.h>       /* for current && schedule_timeout */
 #include <linux/mutex.h>       /* for struct mutex */
+#include <linux/pm_runtime.h>  /* for runtime PM */
 
 struct usb_device;
 struct usb_driver;
@@ -313,6 +314,10 @@ struct usb_bus {
        int busnum;                     /* Bus number (in order of reg) */
        const char *bus_name;           /* stable id (PCI slot_name etc) */
        u8 uses_dma;                    /* Does the host controller use DMA? */
+       u8 uses_pio_for_control;        /*
+                                        * Does the host controller use PIO
+                                        * for control transfers?
+                                        */
        u8 otg_port;                    /* 0, or number of OTG/HNP port */
        unsigned is_b_host:1;           /* true during some HNP roleswitches */
        unsigned b_hnp_enable:1;        /* OTG: did A-Host enable HNP? */
@@ -407,8 +412,6 @@ struct usb_tt;
  * @quirks: quirks of the whole device
  * @urbnum: number of URBs submitted for the whole device
  * @active_duration: total time device is not suspended
- * @last_busy: time of last use
- * @autosuspend_delay: in jiffies
  * @connect_time: time device was first connected
  * @do_remote_wakeup:  remote wakeup should be enabled
  * @reset_resume: needs reset instead of resume
@@ -481,8 +484,6 @@ struct usb_device {
        unsigned long active_duration;
 
 #ifdef CONFIG_PM
-       unsigned long last_busy;
-       int autosuspend_delay;
        unsigned long connect_time;
 
        unsigned do_remote_wakeup:1;
@@ -527,7 +528,7 @@ extern void usb_autopm_put_interface_no_suspend(struct usb_interface *intf);
 
 static inline void usb_mark_last_busy(struct usb_device *udev)
 {
-       udev->last_busy = jiffies;
+       pm_runtime_mark_last_busy(&udev->dev);
 }
 
 #else