struct buf_anchor {
struct urb *urb;
struct list_head list;
- struct completion urb_compl;
};
/**
spin_unlock_irqrestore(lock, flags);
if (likely(urb)) {
mbo = urb->context;
- if (!irqs_disabled()) {
- usb_kill_urb(urb);
- } else {
- usb_unlink_urb(urb);
- wait_for_completion(&anchor->urb_compl);
- }
+ usb_kill_urb(urb);
if ((mbo) && (mbo->complete)) {
mbo->status = status;
mbo->processed_length = 0;
if ((urb->status == -ENOENT) || (urb->status == -ECONNRESET) ||
(!mdev->is_channel_healthy[channel])) {
spin_unlock_irqrestore(lock, flags);
- complete(&anchor->urb_compl);
return;
}
if ((urb->status == -ENOENT) || (urb->status == -ECONNRESET) ||
(!mdev->is_channel_healthy[channel])) {
spin_unlock_irqrestore(lock, flags);
- complete(&anchor->urb_compl);
return;
}
}
anchor->urb = urb;
- init_completion(&anchor->urb_compl);
mbo->priv = anchor;
if ((mdev->padding_active[channel]) &&