From owner-svn-src-all@FreeBSD.ORG Tue May 13 13:46:39 2014 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 91E1DBC4; Tue, 13 May 2014 13:46:39 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7DE5727EA; Tue, 13 May 2014 13:46:39 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s4DDkdfs096015; Tue, 13 May 2014 13:46:39 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s4DDkcqS096010; Tue, 13 May 2014 13:46:38 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201405131346.s4DDkcqS096010@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 13 May 2014 13:46:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r265949 - head/sys/dev/usb/controller X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 May 2014 13:46:39 -0000 Author: hselasky Date: Tue May 13 13:46:38 2014 New Revision: 265949 URL: http://svnweb.freebsd.org/changeset/base/265949 Log: - Isochronous transfers should use the alternate next transfer descriptor upon receiving a short packet, in host and device mode. - Correct some comments. Modified: head/sys/dev/usb/controller/at91dci.c head/sys/dev/usb/controller/atmegadci.c head/sys/dev/usb/controller/avr32dci.c head/sys/dev/usb/controller/musb_otg.c head/sys/dev/usb/controller/uss820dci.c Modified: head/sys/dev/usb/controller/at91dci.c ============================================================================== --- head/sys/dev/usb/controller/at91dci.c Tue May 13 13:20:23 2014 (r265948) +++ head/sys/dev/usb/controller/at91dci.c Tue May 13 13:46:38 2014 (r265949) @@ -898,7 +898,8 @@ at91dci_setup_standard_chain(struct usb_ temp.td = NULL; temp.td_next = xfer->td_start[0]; temp.offset = 0; - temp.setup_alt_next = xfer->flags_int.short_frames_ok; + temp.setup_alt_next = xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr; temp.did_stall = !xfer->flags_int.control_stall; sc = AT9100_DCI_BUS2SC(xfer->xroot->bus); @@ -1124,7 +1125,8 @@ at91dci_standard_done_sub(struct usb_xfe } /* Check for short transfer */ if (len > 0) { - if (xfer->flags_int.short_frames_ok) { + if (xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr) { /* follow alt next */ if (td->alt_next) { td = td->obj_next; Modified: head/sys/dev/usb/controller/atmegadci.c ============================================================================== --- head/sys/dev/usb/controller/atmegadci.c Tue May 13 13:20:23 2014 (r265948) +++ head/sys/dev/usb/controller/atmegadci.c Tue May 13 13:46:38 2014 (r265949) @@ -804,7 +804,8 @@ atmegadci_setup_standard_chain(struct us temp.td = NULL; temp.td_next = xfer->td_start[0]; temp.offset = 0; - temp.setup_alt_next = xfer->flags_int.short_frames_ok; + temp.setup_alt_next = xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr; temp.did_stall = !xfer->flags_int.control_stall; sc = ATMEGA_BUS2SC(xfer->xroot->bus); @@ -1010,7 +1011,8 @@ atmegadci_standard_done_sub(struct usb_x } /* Check for short transfer */ if (len > 0) { - if (xfer->flags_int.short_frames_ok) { + if (xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr) { /* follow alt next */ if (td->alt_next) { td = td->obj_next; @@ -1380,9 +1382,9 @@ atmegadci_do_poll(struct usb_bus *bus) } /*------------------------------------------------------------------------* - * at91dci bulk support - * at91dci control support - * at91dci interrupt support + * atmegadci bulk support + * atmegadci control support + * atmegadci interrupt support *------------------------------------------------------------------------*/ static void atmegadci_device_non_isoc_open(struct usb_xfer *xfer) @@ -1419,7 +1421,7 @@ static const struct usb_pipe_methods atm }; /*------------------------------------------------------------------------* - * at91dci full speed isochronous support + * atmegadci full speed isochronous support *------------------------------------------------------------------------*/ static void atmegadci_device_isoc_fs_open(struct usb_xfer *xfer) @@ -1505,7 +1507,7 @@ static const struct usb_pipe_methods atm }; /*------------------------------------------------------------------------* - * at91dci root control support + * atmegadci root control support *------------------------------------------------------------------------* * Simulate a hardware HUB by handling all the necessary requests. *------------------------------------------------------------------------*/ Modified: head/sys/dev/usb/controller/avr32dci.c ============================================================================== --- head/sys/dev/usb/controller/avr32dci.c Tue May 13 13:20:23 2014 (r265948) +++ head/sys/dev/usb/controller/avr32dci.c Tue May 13 13:46:38 2014 (r265949) @@ -771,7 +771,8 @@ avr32dci_setup_standard_chain(struct usb temp.td = NULL; temp.td_next = xfer->td_start[0]; temp.offset = 0; - temp.setup_alt_next = xfer->flags_int.short_frames_ok; + temp.setup_alt_next = xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr; temp.did_stall = !xfer->flags_int.control_stall; sc = AVR32_BUS2SC(xfer->xroot->bus); @@ -979,7 +980,8 @@ avr32dci_standard_done_sub(struct usb_xf } /* Check for short transfer */ if (len > 0) { - if (xfer->flags_int.short_frames_ok) { + if (xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr) { /* follow alt next */ if (td->alt_next) { td = td->obj_next; @@ -1310,9 +1312,9 @@ avr32dci_do_poll(struct usb_bus *bus) } /*------------------------------------------------------------------------* - * at91dci bulk support - * at91dci control support - * at91dci interrupt support + * avr32dci bulk support + * avr32dci control support + * avr32dci interrupt support *------------------------------------------------------------------------*/ static void avr32dci_device_non_isoc_open(struct usb_xfer *xfer) @@ -1349,7 +1351,7 @@ static const struct usb_pipe_methods avr }; /*------------------------------------------------------------------------* - * at91dci full speed isochronous support + * avr32dci full speed isochronous support *------------------------------------------------------------------------*/ static void avr32dci_device_isoc_fs_open(struct usb_xfer *xfer) @@ -1434,7 +1436,7 @@ static const struct usb_pipe_methods avr }; /*------------------------------------------------------------------------* - * at91dci root control support + * avr32dci root control support *------------------------------------------------------------------------* * Simulate a hardware HUB by handling all the necessary requests. *------------------------------------------------------------------------*/ Modified: head/sys/dev/usb/controller/musb_otg.c ============================================================================== --- head/sys/dev/usb/controller/musb_otg.c Tue May 13 13:20:23 2014 (r265948) +++ head/sys/dev/usb/controller/musb_otg.c Tue May 13 13:46:38 2014 (r265949) @@ -2403,7 +2403,8 @@ musbotg_setup_standard_chain(struct usb_ temp.td = NULL; temp.td_next = xfer->td_start[0]; temp.offset = 0; - temp.setup_alt_next = xfer->flags_int.short_frames_ok; + temp.setup_alt_next = xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr; temp.did_stall = !xfer->flags_int.control_stall; temp.channel = -1; temp.dev_addr = dev_addr; @@ -2714,7 +2715,8 @@ musbotg_standard_done_sub(struct usb_xfe } /* Check for short transfer */ if (len > 0) { - if (xfer->flags_int.short_frames_ok) { + if (xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr) { /* follow alt next */ if (td->alt_next) { td = td->obj_next; Modified: head/sys/dev/usb/controller/uss820dci.c ============================================================================== --- head/sys/dev/usb/controller/uss820dci.c Tue May 13 13:20:23 2014 (r265948) +++ head/sys/dev/usb/controller/uss820dci.c Tue May 13 13:46:38 2014 (r265949) @@ -875,7 +875,8 @@ uss820dci_setup_standard_chain(struct us temp.td = NULL; temp.td_next = xfer->td_start[0]; temp.offset = 0; - temp.setup_alt_next = xfer->flags_int.short_frames_ok; + temp.setup_alt_next = xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr; temp.did_stall = !xfer->flags_int.control_stall; sc = USS820_DCI_BUS2SC(xfer->xroot->bus); @@ -1120,7 +1121,8 @@ uss820dci_standard_done_sub(struct usb_x } /* Check for short transfer */ if (len > 0) { - if (xfer->flags_int.short_frames_ok) { + if (xfer->flags_int.short_frames_ok || + xfer->flags_int.isochronous_xfr) { /* follow alt next */ if (td->alt_next) { td = td->obj_next; @@ -1543,7 +1545,7 @@ uss820dci_do_poll(struct usb_bus *bus) } /*------------------------------------------------------------------------* - * at91dci bulk support + * uss820dci bulk support *------------------------------------------------------------------------*/ static void uss820dci_device_bulk_open(struct usb_xfer *xfer) @@ -1580,7 +1582,7 @@ static const struct usb_pipe_methods uss }; /*------------------------------------------------------------------------* - * at91dci control support + * uss820dci control support *------------------------------------------------------------------------*/ static void uss820dci_device_ctrl_open(struct usb_xfer *xfer) @@ -1617,7 +1619,7 @@ static const struct usb_pipe_methods uss }; /*------------------------------------------------------------------------* - * at91dci interrupt support + * uss820dci interrupt support *------------------------------------------------------------------------*/ static void uss820dci_device_intr_open(struct usb_xfer *xfer) @@ -1654,7 +1656,7 @@ static const struct usb_pipe_methods uss }; /*------------------------------------------------------------------------* - * at91dci full speed isochronous support + * uss820dci full speed isochronous support *------------------------------------------------------------------------*/ static void uss820dci_device_isoc_fs_open(struct usb_xfer *xfer) @@ -1736,7 +1738,7 @@ static const struct usb_pipe_methods uss }; /*------------------------------------------------------------------------* - * at91dci root control support + * uss820dci root control support *------------------------------------------------------------------------* * Simulate a hardware HUB by handling all the necessary requests. *------------------------------------------------------------------------*/