public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC] dma: passing "attributes" to dma_map_* routines
@ 2007-12-18  0:17 akepner
  2007-12-18 16:50 ` Stefan Richter
  0 siblings, 1 reply; 12+ messages in thread
From: akepner @ 2007-12-18  0:17 UTC (permalink / raw)
  To: Andrew Morton, grundler, jbarnes, jes, randy.dunlap, rdreier,
	James.Bottomley, davem
  Cc: linux-kernel


Waaay back in October I sent some patches for passing additional 
attributes to the dma_map_* routines:

http://marc.info/?l=linux-kernel&m=119137949604365&w=2

This is somthing needed for ia64 Altix NUMA machines (as described 
in that thread).

Several folks objected to the approach I used - it was a bit of a 
hack - and so these patches were dropped. 

This time I'd like to get something resembling concensus before 
spending much time on this. 

Can you please comment on the options listed here, or suggest 
alternatives?

We could:

1) add an additional parameter to the dma_map_* routines, somthing 
   like:

     dma_map_single(struct device *dev, void *cpu_addr, size_t size,
                    enum dma_data_direction direction, u32 flags)
     ....

2) change the "direction" argument to be a field of bits:

     dma_map_single(struct device *dev, void *cpu_addr, size_t size,
                    u32 flags)
     ....

     where flags encodes the direction and optionally other attributes.

3) add new functions to the dma interface, e.g.:

     dma_map_single_attrs(struct device *dev, void *cpu_addr, size_t size,
                          enum dma_data_direction direction, u32 attrs)
     .....

1) and 2) are going to require many minor changes, and 3) is going 
to pollute the dma interface a bit. 

Other ideas?

-- 
Arthur


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2007-12-21 21:32 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-18  0:17 [RFC] dma: passing "attributes" to dma_map_* routines akepner
2007-12-18 16:50 ` Stefan Richter
2007-12-18 19:04   ` Roland Dreier
2007-12-18 20:07   ` akepner
2007-12-18 20:59     ` Stefan Richter
2007-12-18 21:09       ` Roland Dreier
2007-12-20 18:51       ` akepner
2007-12-20 19:06       ` akepner
2007-12-20 20:56     ` Benjamin Herrenschmidt
2007-12-21 18:00       ` akepner
2007-12-21 20:24         ` Stefan Richter
2007-12-21 21:31         ` Benjamin Herrenschmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox