lkml.org 
[lkml]   [2004]   [Jul]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] Improve pci_alloc_consistent wrapper on preemptive kernels
From
Date
On Fri, 2004-07-30 at 16:20, Andrew Morton wrote:
> Sounds sane. But the default version in asm-generic/dma-mapping.h needs to
> be fixed up:
>
> static inline void *
> dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *dma_handle,
> int flag)
> {
> BUG_ON(dev->bus != &pci_bus_type);
>
> return pci_alloc_consistent(to_pci_dev(dev), size, dma_handle);
> }
>
> If we stick with this model, we'll still need a new pci_alloc_consistent_gfp().

Theoretically, that was just to help architectures that didn't want to
implement the dma_ functions. If we make dma_alloc_coherent() the
preferred implementation, we just remove this because now all arch's
will have to implement dma_alloc_coherent anyway.

James


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:04    [W:0.157 / U:0.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site