Home | History | Annotate | Download | only in linux

Lines Matching refs:urb

50  *	with one or more transfer descriptors (TDs) per urb
653 * URB support, for asynchronous request completions
657 * urb->transfer_flags:
660 #define URB_ISO_ASAP 0x0002 /* iso-only, urb->start_frame
662 #define URB_NO_TRANSFER_DMA_MAP 0x0004 /* urb->transfer_dma valid on submit */
663 #define URB_NO_SETUP_DMA_MAP 0x0008 /* urb->setup_dma valid on submit */
676 struct urb;
679 typedef void (*usb_complete_t)(struct urb *, struct pt_regs *);
682 * struct urb - USB Request Block
683 * @urb_list: For use by current owner of the URB.
696 * to tell whether the URB was unlinked; detailed status for
698 * @transfer_flags: A variety of flags may be used to affect how URB
700 * kinds of URB can use different flags.
737 * @complete: Completion handler. This URB is passed as the parameter to the
739 * it likes with the URB, including resubmitting or freeing it.
790 * to poll for transfers. After the URB has been submitted, the interval
826 * be examined before the URB is returned to the completion handler.
833 * is updated even when the URB terminated with an error or was unlinked.
841 * when the urb is owned by the hcd, that is, since the call to
844 struct urb
846 /* private: usb core and host controller only fields in the urb */
847 struct kref kref; /* reference count of the URB */
848 spinlock_t lock; /* lock for the URB */
854 /* public: documented fields in the urb that can be used by drivers */
855 struct list_head urb_list; /* list head for use by the urb's
881 * usb_fill_control_urb - initializes a control urb
882 * @urb: pointer to the urb to initialize.
883 * @dev: pointer to the struct usb_device for this urb.
889 * @context: what to set the urb context to.
891 * Initializes a control urb with the proper information needed to submit
894 static inline void usb_fill_control_urb (struct urb *urb,
903 spin_lock_init(&urb->lock);
904 urb->dev = dev;
905 urb->pipe = pipe;
906 urb->setup_packet = setup_packet;
907 urb->transfer_buffer = transfer_buffer;
908 urb->transfer_buffer_length = buffer_length;
909 urb->complete = complete;
910 urb->context = context;
914 * usb_fill_bulk_urb - macro to help initialize a bulk urb
915 * @urb: pointer to the urb to initialize.
916 * @dev: pointer to the struct usb_device for this urb.
921 * @context: what to set the urb context to.
923 * Initializes a bulk urb with the proper information needed to submit it
926 static inline void usb_fill_bulk_urb (struct urb *urb,
934 spin_lock_init(&urb->lock);
935 urb->dev = dev;
936 urb->pipe = pipe;
937 urb->transfer_buffer = transfer_buffer;
938 urb->transfer_buffer_length = buffer_length;
939 urb->complete = complete;
940 urb->context = context;
944 * usb_fill_int_urb - macro to help initialize a interrupt urb
945 * @urb: pointer to the urb to initialize.
946 * @dev: pointer to the struct usb_device for this urb.
951 * @context: what to set the urb context to.
952 * @interval: what to set the urb interval to, encoded like
955 * Initializes a interrupt urb with the proper information needed to submit
961 static inline void usb_fill_int_urb (struct urb *urb,
970 spin_lock_init(&urb->lock);
971 urb->dev = dev;
972 urb->pipe = pipe;
973 urb->transfer_buffer = transfer_buffer;
974 urb->transfer_buffer_length = buffer_length;
975 urb->complete = complete;
976 urb->context = context;
978 urb->interval = 1 << (interval - 1);
980 urb->interval = interval;
981 urb->start_frame = -1;
984 extern void usb_init_urb(struct urb *urb);
985 extern struct urb *usb_alloc_urb(int iso_packets, gfp_t mem_flags);
986 extern void usb_free_urb(struct urb *urb);
988 extern struct urb *usb_get_urb(struct urb *urb);
989 extern int usb_submit_urb(struct urb *urb, gfp_t mem_flags);
990 extern int usb_unlink_urb(struct urb *urb);
991 extern void usb_kill_urb(struct urb *urb);
1000 struct urb *usb_buffer_map (struct urb *urb);
1001 void usb_buffer_dmasync (struct urb *urb);
1002 void usb_buffer_unmap (struct urb *urb);
1083 struct urb **urbs;