Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 30 Jan 2015 08:25:58 +0900 (JST)
From:      Kohji Okuno <okuno.kohji@jp.panasonic.com>
To:        hps@selasky.org
Cc:        freebsd-usb@freebsd.org
Subject:   Re: [Bug?] Control Transfers in xHCI
Message-ID:  <20150130.082558.455141361554256806.okuno.kohji@jp.panasonic.com>
In-Reply-To: <54CA9144.4030601@selasky.org>
References:  <54CA4BE3.2090706@selasky.org> <20150129195714.GA3683@dchagin.static.corbina.net> <54CA9144.4030601@selasky.org>

next in thread | previous in thread | raw e-mail | index | archive | help
From: Hans Petter Selasky <hps@selasky.org>
Subject: Re: [Bug?] Control Transfers in xHCI
Date: Thu, 29 Jan 2015 21:00:04 +0100
> On 01/29/15 20:57, Chagin Dmitry wrote:
>> On Thu, Jan 29, 2015 at 04:04:03PM +0100, Hans Petter Selasky wrote:
>>> On 01/29/15 13:25, Kohji Okuno wrote:
>>>> Hi HPS,
>>>>
>>>> I found a bug in xHCI device driver.
>>>>
>>>> Acording to extensible-host-controler-interface-usb-xhci.pdf:"3.2.9
>>>> Control Transfers"...
>>>>
>>>> A Data Stage TD consists of a Data Stage TRB followed by zero or more
>>>> Normal TRBs. If the data is not physically contiguous, Normal TRBs may
>>>> be chained to the Data Stage TRB.
>>>>
>>>>
>>>> But, in the current imprementation, when two or more TRBs are needed,
>>>> the device driver set XHCI_TRB_TYPE_DATA_STAGE to all TRBs.
>>>> This is the violation of the spec.
>>>>
>>>> In my minor xHCI, I encountered strange bubble error in a control
>>>> transfer. After I changed as the following, I succeeded its control
>>>> transfer.
>>>>
>>>> Would you check the following (****)?
>>>>
>>>
>>> Hi Kohji,
>>>
>>> You are correct there is a bug, but your patch is not correct.
>>>
>>> In FreeBSD we allow SETUP and DATA stages to be done as separate jobs.
>>> That means at the entry of creating a new DATA chain, we need to check
>>> if it is there first DATA packet or not.
>>>
>>> Can you test the attached patch and see if it works for you?
>>>
>> patch is lost somewhere, Hans.
>>
> 
> Trying again.
> 
> I think Kohji got it.
> 
> --HPS

Hi, HPS,

Thank you for your commet.
I will test your patch next week.

Thanks,
 Kohji Okuno



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20150130.082558.455141361554256806.okuno.kohji>