diff options
Diffstat (limited to 'include/linux/usb/gadget.h')
-rw-r--r-- | include/linux/usb/gadget.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/linux/usb/gadget.h b/include/linux/usb/gadget.h index 0460a746480c..bbf45d500b6d 100644 --- a/include/linux/usb/gadget.h +++ b/include/linux/usb/gadget.h | |||
@@ -598,6 +598,7 @@ static inline int usb_gadget_clear_selfpowered(struct usb_gadget *gadget) | |||
598 | /** | 598 | /** |
599 | * usb_gadget_vbus_connect - Notify controller that VBUS is powered | 599 | * usb_gadget_vbus_connect - Notify controller that VBUS is powered |
600 | * @gadget:The device which now has VBUS power. | 600 | * @gadget:The device which now has VBUS power. |
601 | * Context: can sleep | ||
601 | * | 602 | * |
602 | * This call is used by a driver for an external transceiver (or GPIO) | 603 | * This call is used by a driver for an external transceiver (or GPIO) |
603 | * that detects a VBUS power session starting. Common responses include | 604 | * that detects a VBUS power session starting. Common responses include |
@@ -636,6 +637,7 @@ static inline int usb_gadget_vbus_draw(struct usb_gadget *gadget, unsigned mA) | |||
636 | /** | 637 | /** |
637 | * usb_gadget_vbus_disconnect - notify controller about VBUS session end | 638 | * usb_gadget_vbus_disconnect - notify controller about VBUS session end |
638 | * @gadget:the device whose VBUS supply is being described | 639 | * @gadget:the device whose VBUS supply is being described |
640 | * Context: can sleep | ||
639 | * | 641 | * |
640 | * This call is used by a driver for an external transceiver (or GPIO) | 642 | * This call is used by a driver for an external transceiver (or GPIO) |
641 | * that detects a VBUS power session ending. Common responses include | 643 | * that detects a VBUS power session ending. Common responses include |
@@ -792,19 +794,20 @@ struct usb_gadget_driver { | |||
792 | /** | 794 | /** |
793 | * usb_gadget_register_driver - register a gadget driver | 795 | * usb_gadget_register_driver - register a gadget driver |
794 | * @driver:the driver being registered | 796 | * @driver:the driver being registered |
797 | * Context: can sleep | ||
795 | * | 798 | * |
796 | * Call this in your gadget driver's module initialization function, | 799 | * Call this in your gadget driver's module initialization function, |
797 | * to tell the underlying usb controller driver about your driver. | 800 | * to tell the underlying usb controller driver about your driver. |
798 | * The driver's bind() function will be called to bind it to a | 801 | * The driver's bind() function will be called to bind it to a |
799 | * gadget before this registration call returns. It's expected that | 802 | * gadget before this registration call returns. It's expected that |
800 | * the bind() functions will be in init sections. | 803 | * the bind() functions will be in init sections. |
801 | * This function must be called in a context that can sleep. | ||
802 | */ | 804 | */ |
803 | int usb_gadget_register_driver(struct usb_gadget_driver *driver); | 805 | int usb_gadget_register_driver(struct usb_gadget_driver *driver); |
804 | 806 | ||
805 | /** | 807 | /** |
806 | * usb_gadget_unregister_driver - unregister a gadget driver | 808 | * usb_gadget_unregister_driver - unregister a gadget driver |
807 | * @driver:the driver being unregistered | 809 | * @driver:the driver being unregistered |
810 | * Context: can sleep | ||
808 | * | 811 | * |
809 | * Call this in your gadget driver's module cleanup function, | 812 | * Call this in your gadget driver's module cleanup function, |
810 | * to tell the underlying usb controller that your driver is | 813 | * to tell the underlying usb controller that your driver is |
@@ -813,7 +816,6 @@ int usb_gadget_register_driver(struct usb_gadget_driver *driver); | |||
813 | * to unbind() and clean up any device state, before this procedure | 816 | * to unbind() and clean up any device state, before this procedure |
814 | * finally returns. It's expected that the unbind() functions | 817 | * finally returns. It's expected that the unbind() functions |
815 | * will in in exit sections, so may not be linked in some kernels. | 818 | * will in in exit sections, so may not be linked in some kernels. |
816 | * This function must be called in a context that can sleep. | ||
817 | */ | 819 | */ |
818 | int usb_gadget_unregister_driver(struct usb_gadget_driver *driver); | 820 | int usb_gadget_unregister_driver(struct usb_gadget_driver *driver); |
819 | 821 | ||