All of lore.kernel.org
 help / color / mirror / Atom feed
From: grygorii.strashko@ti.com (Grygorii Strashko)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 4/4] ARM: keystone: Use dma-ranges for dma_pfn_offset configuration
Date: Tue, 25 Feb 2014 18:05:56 +0200	[thread overview]
Message-ID: <530CBF64.3080407@ti.com> (raw)
In-Reply-To: <5443441.XzmmNp2M6v@wuerfel>

On 02/25/2014 04:37 PM, Arnd Bergmann wrote:
> On Tuesday 25 February 2014 17:19:59 Grygorii Strashko wrote:
>> The Keystone can work in two modes:
>> - LPAE disabled: In this case Platform bus notifier will not be called at all
>> and DMA range == MEM range (32 bits mode)
>
> The hardware setting doesn't change here, just the available memory, right?

Yes. The accessible RAM will be 0x8000 0000 - 0xFFFF FFFF -
the same as DMA range. But coherent DMA will not be supported.

So, no DMA bus offset required and actions in Platform bus notifier.

>
>> - LPAE enabled: In this case, I'll update code to treat absence of "dam-ranges"
>> property as "no dma possible" and clean up DMA mask. Is it ok?
>> In this mode "dam-ranges" prop has to be defined always to enable DMA.
>
> Ok, sounds good.
>
>> Empty "dma-ranges" can't be treated as "no translation required" because it is used
>> to move one level up while traversing DT to find the valid "dma-ranges" prop.
>> Used to handle child devices like:
>>
>>   bus {
>>          dma-ranges = <...>;
>>
>>          Dev A {
>>                  dma-ranges;
>>
>>                  child_dev_A1 { }
>>                  child_dev_A2 { }
>>
>> This is standard behavior for "[dma-]ranges".
>
> That is what I meant: "no translation required at this level". You still
> have to go up to the root in order to know the full translation.
>

Regards,
-grygorii

      reply	other threads:[~2014-02-25 16:05 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-24 20:53 [PATCH 0/4] ARM: mm: Use dma-ranges for dma address translation Santosh Shilimkar
2014-02-24 20:53 ` [PATCH 1/4] ARM: mm: Introduce archdata.dma_pfn_offset Santosh Shilimkar
2014-02-24 20:53 ` [PATCH 2/4] ARM: mm: Remove unsed dma_to_virt() Santosh Shilimkar
2014-02-24 20:53 ` [PATCH 3/4] ARM: dts: keystone: Use dma-ranges property Santosh Shilimkar
2014-02-24 20:53 ` [PATCH 4/4] ARM: keystone: Use dma-ranges for dma_pfn_offset configuration Santosh Shilimkar
2014-02-24 21:11   ` Arnd Bergmann
2014-02-24 21:38     ` Santosh Shilimkar
2014-02-25  8:35       ` Arnd Bergmann
2014-02-25 14:14       ` Grygorii Strashko
2014-02-25 13:37         ` Arnd Bergmann
2014-02-25 15:19           ` Grygorii Strashko
2014-02-25 14:37             ` Arnd Bergmann
2014-02-25 16:05               ` Grygorii Strashko [this message]

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=530CBF64.3080407@ti.com \
    --to=grygorii.strashko@ti.com \
    --cc=linux-arm-kernel@lists.infradead.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.