From: Sergei Shtylyov <sshtylyov-hkdhdckH98+B+jHODAdFcQ@public.gmane.org>
To: "Gupta, Ajay Kumar" <ajay.gupta-l0cyMroinI0@public.gmane.org>
Cc: "linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"felipe.balbi-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org"
<felipe.balbi-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org>,
"david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org"
<david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org>,
"Subbrathnam,
Swaminathan" <swami.iyer-l0cyMroinI0@public.gmane.org>,
"B, Ravi" <ravibabu-l0cyMroinI0@public.gmane.org>
Subject: Re: [PATCH] musb: fix ISOC Tx programming for CPPI DMAs
Date: Fri, 28 Aug 2009 17:06:45 +0400 [thread overview]
Message-ID: <4A97D665.90306@ru.mvista.com> (raw)
In-Reply-To: <4A97CA80.7010600-hkdhdckH98+B+jHODAdFcQ@public.gmane.org>
Hello, I wrote:
>>>>> This part is being done at musb_host_rx()
>>>> You're doing it in musb_host_tx() actually. Although musb_host_rx()
>>>> is also broken WRT the isochronous transfers.
>>>>> doing next packet programming within same urb and *not* starting next
>>>> urb. Thus musb_start_urb() doesn't come into this path.
>>>> What? Read the code, please -- musb_start_urb() call should always
>>>> precede musb_host_tx() which handles the DMA interrupt. Unless
>>>> something
>>>> clears DMAReqEnab after musb_start_urb() call, setting it only once
>>>> should work.
>>> musb_start_urb() call does precede musb_host_tx() but when urb is
>>> *completed*.
>> I think you are aware that there are multiple packets within same
>> isochronous urb and musb_start_urb() programs only for first packet.
>> ============================================================
>> case USB_ENDPOINT_XFER_ISOC:
>> qh->iso_idx = 0;
>> qh->frame = 0;
>> offset = urb->iso_frame_desc[0].offset;
>> len = urb->iso_frame_desc[0].length;
>> ============================================================
> Sure. What I'm still not aware of is where and how the TXCSR DMA bits
> are cleared after the first fragment. Hopefully, testing will reveal
> this...
I really should have stared at the code a bit more myself. Now that I
have the sad truth has dawned on me... :-/
My patch "USB: musb: bugfixes for multi-packet TXDMA support" (commit
c7bbc056a92476b3b3d70a8df7cc746ac5d56de7) inevitably causes the DMA bits to
be cleared because we're using DMA mode 1 regardless of whether this is
isochronous transfer or no. (We could really use mode 0 for isochronous
transfer and save the hassle when filtering out DMA completion interrupt in
musb_host_tx().)
So, I now have to ACK your patch (which could use a better description
though) and strew my head with ashes. All this also must mean that I have
managed to break ISO Tx DMA in the internal tree, where I added the
abovementioned patch after the one that fixed it (the order of the patches
in the community tree is reverse). I probably did not retest USB audio back
then...
WBR, Sergei
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2009-08-28 13:06 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-28 5:58 [PATCH] musb: fix ISOC Tx programming for CPPI DMAs Ajay Kumar Gupta
2009-08-28 9:23 ` Sergei Shtylyov
2009-08-28 9:29 ` Sergei Shtylyov
2009-08-28 9:44 ` Gupta, Ajay Kumar
2009-08-28 9:46 ` Gupta, Ajay Kumar
2009-08-28 10:02 ` Sergei Shtylyov
[not found] ` <4A97AB42.4070008-hkdhdckH98+B+jHODAdFcQ@public.gmane.org>
2009-08-28 10:11 ` Subbrathnam, Swaminathan
[not found] ` <FCCFB4CDC6E5564B9182F639FC35608702F9A45083-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2009-08-28 13:27 ` Sergei Shtylyov
2009-08-28 10:12 ` Sergei Shtylyov
2009-08-28 10:28 ` Gupta, Ajay Kumar
2009-08-28 10:35 ` Gupta, Ajay Kumar
2009-08-28 12:16 ` Sergei Shtylyov
[not found] ` <4A97CA80.7010600-hkdhdckH98+B+jHODAdFcQ@public.gmane.org>
2009-08-28 13:06 ` Sergei Shtylyov [this message]
2009-08-28 13:23 ` Sergei Shtylyov
2009-08-28 10:46 ` Sergei Shtylyov
2009-08-28 14:24 ` Sergei Shtylyov
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=4A97D665.90306@ru.mvista.com \
--to=sshtylyov-hkdhdckh98+b+jhodadfcq@public.gmane.org \
--cc=ajay.gupta-l0cyMroinI0@public.gmane.org \
--cc=david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org \
--cc=felipe.balbi-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org \
--cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=ravibabu-l0cyMroinI0@public.gmane.org \
--cc=swami.iyer-l0cyMroinI0@public.gmane.org \
/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