linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Frode Isaksen <fisaksen@bewan.com>
To: weissg@vienna.at
Cc: linux-kernel@vger.kernel.org
Subject: PATCH: usb-ohci: interrupt out with urb->interval 0
Date: Wed, 16 Apr 2003 17:45:04 +0200	[thread overview]
Message-ID: <6451EBA9-7022-11D7-8F05-003065EF6010@bewan.com> (raw)

In the usb-ohci driver, the interrupt out transfer is always 
rescheduled, even if the urb->interval is set to 0 to signal a one-shot 
transfer.
The other usb drivers (usb-uhci,uhci) allows one-shot interrupt out 
transfers.
Tested with kernel 2.4.21 and previous kernels.

Thanks,
Frode

--- drivers/usb/usb-ohci.c.orig	2003-04-16 15:42:46.000000000 +0200
+++ drivers/usb/usb-ohci.c	2003-04-16 15:45:41.000000000 +0200
@@ -490,12 +490,17 @@
  				usb_pipeout (urb->pipe)
  					? PCI_DMA_TODEVICE
  					: PCI_DMA_FROMDEVICE);
-			urb->complete (urb);
+			if (urb->interval) {
+				urb->complete (urb);

-			/* implicitly requeued */
-  			urb->actual_length = 0;
-			urb->status = -EINPROGRESS;
-			td_submit_urb (urb);
+				/* implicitly requeued */
+				urb->actual_length = 0;
+				urb->status = -EINPROGRESS;
+				td_submit_urb (urb);
+			} else {
+				urb_rm_priv(urb);
+				urb->complete (urb);
+			}
    			break;
    			
  		case PIPE_ISOCHRONOUS:


             reply	other threads:[~2003-04-16 15:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-16 15:45 Frode Isaksen [this message]
2003-04-18  7:39 ` PATCH: usb-ohci: interrupt out with urb->interval 0 Greg KH
2003-04-21  8:07 David Glance

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6451EBA9-7022-11D7-8F05-003065EF6010@bewan.com \
    --to=fisaksen@bewan.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=weissg@vienna.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).