]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/usb_otg.h
[PATCH] md: Final stages of raid5 expand code
[linux-2.6-omap-h63xx.git] / include / linux / usb_otg.h
index c6683146e9b0fb09501ad1bb021efffb8bf31013..f827f6e203c219249b39cd41929a44aae6aa77e9 100644 (file)
@@ -63,6 +63,10 @@ struct otg_transceiver {
        int     (*set_power)(struct otg_transceiver *otg,
                                unsigned mA);
 
+       /* for non-OTG B devices: set transceiver into suspend mode */
+       int     (*set_suspend)(struct otg_transceiver *otg,
+                               int suspend);
+
        /* for B devices only:  start session with A-Host */
        int     (*start_srp)(struct otg_transceiver *otg);
 
@@ -107,6 +111,15 @@ otg_set_power(struct otg_transceiver *otg, unsigned mA)
        return otg->set_power(otg, mA);
 }
 
+static inline int
+otg_set_suspend(struct otg_transceiver *otg, int suspend)
+{
+       if (otg->set_suspend != NULL)
+               return otg->set_suspend(otg, suspend);
+       else
+               return 0;
+}
+
 static inline int
 otg_start_srp(struct otg_transceiver *otg)
 {