/* get_urb_status_from_qtd - get the completed urb status from qTD status @urb: completed urb @status: qTD status  */
static int get_urb_status_from_qtd(struct urb *urb, u32 status)
/* get_urb_status_from_qtd - get the completed urb status from qTD status @urb: completed urb @status: qTD status  */
static int get_urb_status_from_qtd(struct urb *urb, u32 status)
{
	if (status & QTD_STS_HALTED) {
		if (status & QTD_STS_DBE)
			return usb_pipein(urb->pipe) ? -ENOSR : -ECOMM;
		else if (status & QTD_STS_BABBLE)
			return -EOVERFLOW;
		else if (status & QTD_STS_RCE)
			return -ETIME;
		return -EPIPE;
	}
	if (usb_pipein(urb->pipe)
	    && (urb->transfer_flags & URB_SHORT_NOT_OK)
	    && urb->actual_length < urb->transfer_buffer_length)
		return -EREMOTEIO;
	return 0;
}