+ mutex_unlock (&usblp_mutex);
+}
+
+static int usblp_suspend (struct usb_interface *intf, pm_message_t message)
+{
+ struct usblp *usblp = usb_get_intfdata (intf);
+
+ /* this races against normal access and open */
+ mutex_lock (&usblp_mutex);
+ mutex_lock (&usblp->mut);
+ /* we take no more IO */
+ usblp->sleeping = 1;
+ usblp_unlink_urbs(usblp);
+ mutex_unlock (&usblp->mut);
+ mutex_unlock (&usblp_mutex);
+
+ return 0;
+}
+
+static int usblp_resume (struct usb_interface *intf)
+{
+ struct usblp *usblp = usb_get_intfdata (intf);
+ int r;
+
+ mutex_lock (&usblp_mutex);
+ mutex_lock (&usblp->mut);
+
+ usblp->sleeping = 0;
+ r = handle_bidir (usblp);
+
+ mutex_unlock (&usblp->mut);
+ mutex_unlock (&usblp_mutex);
+
+ return r;