public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: akepner@sgi.com
Cc: Tony Luck <tony.luck@intel.com>,
	Grant Grundler <grundler@parisc-linux.org>,
	Jesse Barnes <jbarnes@virtuousgeek.org>,
	Jes Sorensen <jes@sgi.com>,
	Randy Dunlap <randy.dunlap@oracle.com>,
	Roland Dreier <rdreier@cisco.com>,
	David Miller <davem@davemloft.net>,
	Muli Ben-Yehuda <muli@il.ibm.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [RFC/PARTIAL PATCH 0/3] dma: passing "attributes" to dma_map_* routines
Date: Tue, 08 Jan 2008 10:27:08 -0600	[thread overview]
Message-ID: <1199809628.3534.34.camel@localhost.localdomain> (raw)
In-Reply-To: <20080108023222.GP23661@sgi.com>

On Mon, 2008-01-07 at 21:32 -0500, akepner@sgi.com wrote:
>         The following patchset allows additional "attributes" to be 
>         passed to dma_map_*/dma_unmap_* implementations. (The reason 
>         why this is useful/necessary has been mentioned several
>         times, 
>         most recently here:
>         http://marc.info/?l=linux-kernel&m=119258541412724&w=2.)
>         
>         This is incomplete in that only ia64 and x86_64 are supported
>         - 
>         the purpose is mainly to give us something specific to
>         discuss. 

I'm already on record saying I don't think attributes in the generic
code is the right approach.  All of the attributes I can see adding are
bus specific (even to the extent that PCIe ones wouldn't apply to PCI
for instance).  I really think the right approach is to sort out the
attribute infrastructure and not try to overload the generic DMA API.  I
can certainly see that we might like to use it to take advantage of
other PCIe attributes (where available, of course).

Ultimately, it might be the best implementation course to pass the
attributes in to the dma_map routines, but I can't see them being
generic, they'd still be bus specific, so the correct way is to have a
bus specific attribute setup routine and pass some sort of opaque
attribute handle (or even just use the existing dma handle).

>         The approach here is to change the dma_map_* interface so 
>         that the last argument is an u32 which encodes the direction 
>         of the dma and, optionally, other attributes. Changing the 
>         interface is a bit intrusive, but callers of dma_map_* don't 
>         need to be modified.
>         
>         There are 3 patches:
>         
>         [1/3] dma: create linux/dma-direction.h 
>         [2/3] dma: ia64/sn2 allow "attributes" to be used by dma_map_*
>         [2/3] dma: x86_64 allow "attributes" to be used by dma_map_*

James

P.S. please update my email address: the @steeleye.com one no longer
works now.


  reply	other threads:[~2008-01-08 16:27 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-08  2:32 [RFC/PARTIAL PATCH 0/3] dma: passing "attributes" to dma_map_* routines akepner
2008-01-08 16:27 ` James Bottomley [this message]
2008-01-08 17:42   ` Roland Dreier
2008-01-08 17:54     ` James Bottomley
2008-01-08 18:05       ` Roland Dreier
2008-01-08 18:21         ` James Bottomley
2008-01-09  0:55           ` akepner
2008-01-09 21:00           ` Roland Dreier
2008-01-09 21:05             ` akepner
2008-01-09 21:30             ` James Bottomley
2008-01-11 18:20               ` Grant Grundler
2008-01-08 18:13   ` akepner
2008-01-08 17:50 ` Christoph Hellwig
2008-01-08 17:55   ` Roland Dreier
2008-01-08 18:23   ` akepner

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=1199809628.3534.34.camel@localhost.localdomain \
    --to=james.bottomley@hansenpartnership.com \
    --cc=akepner@sgi.com \
    --cc=davem@davemloft.net \
    --cc=grundler@parisc-linux.org \
    --cc=jbarnes@virtuousgeek.org \
    --cc=jes@sgi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=muli@il.ibm.com \
    --cc=randy.dunlap@oracle.com \
    --cc=rdreier@cisco.com \
    --cc=tony.luck@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox