Subject: [PATCH 000/008] USB: serial: sierra driver urb handling improvements From: Elina Pasheva <epasheva@xxxxxxxxxxxxxxxxxx> The following series of 8 patches deal with improvement of urb handling in sierra driver. This series of patches superceeds the series of 3 patches sent on April 06, 2009 to Greg Kroah-Hartman and linux-kernel, in particular [PATCH 003/003]: USB: serial: sierra driver bug fixes in open/close and callbacks. Summary of the changes and code re-organization in this series of 8 patches: The memory for urbs is allocated and urbs are submitted only for the active interfaces (instead of pre-allocating these for all interfaces). This will save memory especially in the case of using composite devices. The code has been re-organized and functionality has been extracted from sierra_startup(), sierra_shutdown(), sierra_open(), sierra_close() and added in helper functions sierra_release_urb(), sierra_stop_rx_urbs(), sierra_submit_rx_urbs() and sierra_setup_urb() Please note that there is dependency between subsequent patches up to the final patch. All of the patches need to be applied to obtain a working product. [PATCH 001/008] adding sierra_release_urb() function: - Added function sierra_release_urb() to free an urb and its transfer buffer. This function is to be called by sierra_close() in subsequent patch. - Version number set to 1.3.8 - Removed unecessary include file reference and comment [PATCH 002/008]adding sierra_stop_rx_urbs() function: - Added function sierra_stop_rx_urbs() that takes care of the release of receive and interrupt urbs. This function is to be called by sierra_close() whenever an interface is de-activated. [PATCH 003/008] adding sierra_submit_rx_urbs() function: - Added new function sierra_submit_rx_urbs() that handles the submission of receive urbs and interrupt urbs (if any) during the interface activation. This function is to be called by sierra_open(). [PATCH 004/008] adding sierra_setup_urb() function: - Added new function sierra_setup_urb() that contains the functionality to allocate an urb, fill bulk urb abd release urb upon error. [PATCH 005/008] sierra_close() modifications: - Moved sierra_close() before sierra_open() to resolve dependencies introduced by the code reorganization. - Modified sierra_close() to call sierra_stop_rx_urbs() and sierra_release_urb() functions added in previous patch. [PATCH 006/008] sierra_open() modifications: - Modified sierra_open() to call sierra_setup_urb() and sierra_submit_rx_urbs() functions; note urbs are allocated and submitted for each activated interface. [PATCH 007/008] modifications in sierra_startup() and sierra_shutdown() functions: - Modified sierra_startup() so that allocation of urbs happens whenever an interface is activated (urb allocation is moved to sierra_open()). - Modified sierra_shutdown() so that urbs are freed whenever an interface is de-activated (urb freeing moved to sierra_close() as shown in previous patch from the series) - Removed unecessary data structure from sierra_port_private_data [PATCH 008/008] suppress log entry: - Suppress an entry in logs by not re-submitting an urb when usb_submit_urb() returns -EPERM, as this shows that usb_kill_urb() is running (as suggested by Oliver Neukum ) Signed-off-by: Elina Pasheva <epasheva@xxxxxxxxxxxxxxxxxx> --- -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html