Commit 401c7be2 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab Committed by Jonathan Corbet

usb/bulk-streams.txt: convert to ReST and add to driver-api book

This document describe some USB core functions. Add it to the
driver-api book.
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
Acked-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarJonathan Corbet <corbet@lwn.net>
parent 79e0c2e6
USB bulk streams
~~~~~~~~~~~~~~~~
Background Background
========== ==========
...@@ -25,7 +28,9 @@ time. ...@@ -25,7 +28,9 @@ time.
Driver implications Driver implications
=================== ===================
int usb_alloc_streams(struct usb_interface *interface, ::
int usb_alloc_streams(struct usb_interface *interface,
struct usb_host_endpoint **eps, unsigned int num_eps, struct usb_host_endpoint **eps, unsigned int num_eps,
unsigned int num_streams, gfp_t mem_flags); unsigned int num_streams, gfp_t mem_flags);
...@@ -53,7 +58,7 @@ controller driver, and may change in the future. ...@@ -53,7 +58,7 @@ controller driver, and may change in the future.
Picking new Stream IDs to use Picking new Stream IDs to use
============================ =============================
Stream ID 0 is reserved, and should not be used to communicate with devices. If Stream ID 0 is reserved, and should not be used to communicate with devices. If
usb_alloc_streams() returns with a value of N, you may use streams 1 though N. usb_alloc_streams() returns with a value of N, you may use streams 1 though N.
...@@ -68,9 +73,9 @@ Clean up ...@@ -68,9 +73,9 @@ Clean up
======== ========
If a driver wishes to stop using streams to communicate with the device, it If a driver wishes to stop using streams to communicate with the device, it
should call should call::
void usb_free_streams(struct usb_interface *interface, void usb_free_streams(struct usb_interface *interface,
struct usb_host_endpoint **eps, unsigned int num_eps, struct usb_host_endpoint **eps, unsigned int num_eps,
gfp_t mem_flags); gfp_t mem_flags);
......
...@@ -7,6 +7,7 @@ Linux USB API ...@@ -7,6 +7,7 @@ Linux USB API
usb usb
gadget gadget
anchors anchors
bulk-streams
writing_usb_driver writing_usb_driver
writing_musb_glue_layer writing_musb_glue_layer
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment