All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Kridner <jkridner-hcmAuCOw+vXj4SYmN/TMmA@public.gmane.org>
To: beagleboard-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Cc: linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: USB DMA on Beagleboard xM (DM37x)
Date: Wed, 24 Aug 2011 07:35:43 -0700 (PDT)	[thread overview]
Message-ID: <30852752.1245.1314196543737.JavaMail.geo-discussion-forums@yqlo5> (raw)
In-Reply-To: <4f8e974b-a67d-4020-b39d-a3d7ca90fe42-3/KZq9SnIEE2swWmpKVAvmB/v6IoIuQBVpNB7YpNyf8@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 3913 bytes --]

>On Tuesday, August 23, 2011 1:33:43 PM UTC-4, Esaias wrote:
>Hello, 
>
>I have written a USB driver for the OTG controller (just to be used as 
>peripheral) for a USB Stack (Not using Linux). 
>The driver is able to Tx/Rx at High Speed but I am only getting a 
>throughput of 3MB/s. I think I need DMA to get a higher throughput, 
>however I can't find the documentation for the DMA in the USB 
>controller. I need to know where the registers are located. 
>
>So my questions: 
>1. Does BB xM uses CPPI 4.1 DMA? 

Depends on which kernel you are talking about, but my understanding is that 
it is *NOT* enabled in the mainline. There have been a few candidate patches 
floated, but nothing accepted yet. You can google for it. There was an issue 
that prevents you from using the DMA in both directions and thus there was a 
desire to use the sDMA (system DMA) for transfers in one of the directions.

My impression might be quite wrong based on [1].

>2. Where can I find the registers offsets for the DMA in the USB 
>controller? 
>

Here's the TI answer I got (yes, I work for TI, but I go through the typical 
support channels to get answers for the BeagleBoard community):

      You can refer to linux code for Mentor DMA implementation. For 
document you should Contact local TI team and get it after signing NDA 
needed for this document.


I see you got a bit of an answer from the TI e2e forums [1].  It would be 
great if you could reply back here as well with whatever you learn.

The individual registers seem to be defined in [4] or [5]. I wanted to find 
where the base was introduced to see if the whole driver was introduced 
together, but it doesn't look like it to me [3].

When lost in the code, it is time to revert to the TRM [7].  In the L4-Core 
Memory Space Mapping table, you can find the USB OTG controller base at 
0x480AB000, but that doesn't match the 0x4805e300 found in [3], which is 
just shown as RESERVED in the memory mapping table. :( 

[1] 
http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/537/p/129614/464698.aspx
[2] 
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=blob;f=drivers/usb/musb/cppi_dma.c;h=149f3f310a0a1f9903793ca5f56daaf1038a4024;hb=HEAD
[3] 
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=f4e4c324a5f81f18156499d1ade3732ba1f5b523
[4] 
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=blob;f=drivers/usb/musb/musb_regs.h;h=82410703dcd3c1d87e688007c52cd737675d03d6;hb=HEAD
[5] 
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=blob;f=drivers/usb/musb/cppi_dma.h;h=59bf949e589b85a086be064ffb037a77bedc7e24;hb=HEAD
[6] 
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=blob;f=drivers/usb/musb/musbhsdma.h;h=320fd4afb93f7cd31b05e26e125819ae03af95c2;hb=HEAD
[7] http://focus.ti.com/docs/prod/folders/print/dm3730.html (search for 
"technical reference manual")

>Any other information that might be helpful when adding this 
>functionality to my USB driver? 
>

If it is a Linux driver, include linux-omap (added to the CC) to the 
discussion. There are some USB experts there who might chime in if you are 
working on advancing the state of the mainline driver to include DMA 
support.  If you have sufficient time to devote to improving the performance 
of the driver for the community, I can be a contact to enable the NDA.


>Thanks, 
>
>- Esaias

-- 
You received this message because you are subscribed to the Google Groups "Beagle Board" group.
To view this discussion on the web visit https://groups.google.com/d/msg/beagleboard/-/JwWCwpQemOQJ.
To post to this group, send email to beagleboard-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to beagleboard+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
For more options, visit this group at http://groups.google.com/group/beagleboard?hl=en.


[-- Attachment #2: Type: text/html, Size: 4262 bytes --]

           reply	other threads:[~2011-08-24 14:35 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <4f8e974b-a67d-4020-b39d-a3d7ca90fe42-3/KZq9SnIEE2swWmpKVAvmB/v6IoIuQBVpNB7YpNyf8@public.gmane.org>]

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=30852752.1245.1314196543737.JavaMail.geo-discussion-forums@yqlo5 \
    --to=jkridner-hcmaucow+vxj4symn/tmma@public.gmane.org \
    --cc=beagleboard-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    --cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.