All of lore.kernel.org
 help / color / mirror / Atom feed
From: Keir Fraser <keir@xensource.com>
To: Jan Beulich <jbeulich@novell.com>,
	Herbert Xu <herbert@gondor.apana.org.au>,
	Keir Fraser <keir@xensource.com>
Cc: Xen Development Mailing List <xen-devel@lists.xensource.com>,
	Calvin Webster <cwebster@ec.rr.com>
Subject: Re: [LINUX] dma: Use swiotlb mask for coherent mappings too
Date: Wed, 20 Dec 2006 11:55:10 +0000	[thread overview]
Message-ID: <C1AED51E.6A2B%keir@xensource.com> (raw)
In-Reply-To: <4589319B.76E4.0078.0@novell.com>

We could fall back to swiotlb_alloc/free_coherent?

I took the patch but renamed io_tlb_dma_bits to dma_bits. This makes more
sense for users anyway I think -- they're unlikely to care whether
allocations go thru swiotlb or not, they just want to specify what device
limitation they require the kernel to handle by whatever means it chooses.
So now it's 'dma_bits=' rather than 'io_tlb_dma_bits=', which happens to
neatly be the same as the Xen boot parameter's name.

 -- Keir

On 20/12/06 11:50, "Jan Beulich" <jbeulich@novell.com> wrote:

> As we're going to have a swiotlb_{alloc,free}_coherent implementation after
> the sync
> with lib/swiotlb.c anyway, wouldn't it make sense to have
> dma_{alloc,free}_coherent
> call the former rather than setting up things by itself? If course, this will
> increase
> pressure on the swiotlb memory, but otoh it could reduce the likelihood of the
> contiguous region setup failing (especially if those are of non-zero order).
> 
> Jan
> 
>>>> Herbert Xu <herbert@gondor.apana.org.au> 20.12.06 06:14 >>>
> Hi Keir:
> 
> [LINUX] dma: Use swiotlb mask for coherent mappings too
> 
> The recent change to use a default DMA bit width of 30 bits (required
> by chips like the b44) only converted the streaming DMA primitives.
> The coherent mappings are still hard-coded to 31 bits.  This means that
> b44 still doesn't work under Xen.
> 
> This patch makes the io_tlb_dma_bits variable global and uses it for
> coherent memory mappings.
> 
> Thanks to Calvin Webster for providing a machine with a b44 and 2G
> of memory I've been able to verify that this finally makes the b44
> work under Xen.
> 
> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
> 
> Cheers,

  reply	other threads:[~2006-12-20 11:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-20  5:14 [LINUX] dma: Use swiotlb mask for coherent mappings too Herbert Xu
2006-12-20 11:50 ` Jan Beulich
2006-12-20 11:55   ` Keir Fraser [this message]
2006-12-20 12:38     ` Jan Beulich
2006-12-20 13:36       ` Keir Fraser

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=C1AED51E.6A2B%keir@xensource.com \
    --to=keir@xensource.com \
    --cc=cwebster@ec.rr.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=jbeulich@novell.com \
    --cc=xen-devel@lists.xensource.com \
    /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.