summaryrefslogtreecommitdiff
path: root/drivers/usb/host/ehci-sched.c
diff options
context:
space:
mode:
authordavid-b@pacbell.net <david-b@pacbell.net>2005-08-13 18:44:58 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2005-09-08 16:28:36 -0700
commitd0384200f6b608e77fb5ddf7dfae1bf0e42c1c6e (patch)
tree4ab0d9bcf70a42a2c75b7a4aca7a757e7085ee94 /drivers/usb/host/ehci-sched.c
parente09711aef4180002241c7f2eab37390ddf40d6a0 (diff)
[PATCH] ehci: add tt_usecs
This adds the field tt_usecs to ehci_qh and ehci_iso_stream, and sets it appropriately when setting them up as periodic endpoints. It records the transation translator's think_time (added in last patch) plus the downstream (i.e. low or full speed) bustime of the transfer associated with each interrupt or iso frame, as calculated by usb_calc_bus_time. Signed-off-by: Dan Streetman <ddstreet@ieee.org> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/ehci-sched.c')
-rw-r--r--drivers/usb/host/ehci-sched.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/usb/host/ehci-sched.c b/drivers/usb/host/ehci-sched.c
index 4c972b57c7c3..ccc7300baa6d 100644
--- a/drivers/usb/host/ehci-sched.c
+++ b/drivers/usb/host/ehci-sched.c
@@ -700,6 +700,7 @@ iso_stream_init (
} else {
u32 addr;
+ int think_time;
addr = dev->ttport << 24;
if (!ehci_is_TDI(ehci)
@@ -709,6 +710,9 @@ iso_stream_init (
addr |= epnum << 8;
addr |= dev->devnum;
stream->usecs = HS_USECS_ISO (maxp);
+ think_time = dev->tt ? dev->tt->think_time : 0;
+ stream->tt_usecs = NS_TO_US (think_time + usb_calc_bus_time (
+ dev->speed, is_input, 1, maxp));
if (is_input) {
u32 tmp;