Commit 3de64651 authored by Oliver Neukum's avatar Oliver Neukum Committed by Greg Kroah-Hartman

[PATCH] USB: fix irq urb in hpusbscsi

this fixes the completion handler for the interrupt urb in hpusbscsi.
parent db74e1e9
......@@ -306,7 +306,10 @@ DEBUG("Getting status byte %d \n",hpusbscsi->scsi_state_byte);
if(unlikely(u->status < 0)) {
if (likely(hpusbscsi->state != HP_STATE_FREE))
handle_usb_error(hpusbscsi);
return;
if (u->status == -ECONNRESET || u->status == -ENOENT || u->status == -ESHUTDOWN)
return;
else
goto resub;
}
scsi_state = hpusbscsi->scsi_state_byte;
......@@ -348,6 +351,8 @@ DEBUG("Getting status byte %d \n",hpusbscsi->scsi_state_byte);
TRACE_STATE;
break;
}
resub:
usb_submit_urb(u, GFP_ATOMIC);
}
static void simple_command_callback(struct urb *u, struct pt_regs *regs)
......@@ -427,7 +432,7 @@ static void simple_done (struct urb *u, struct pt_regs *regs)
hpusbscsi->state = HP_STATE_WAIT;
} else {
issue_request_sense(hpusbscsi);
}
}
}
} else {
if (likely(hpusbscsi->scallback != NULL))
......
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