Re: [PATCH 0/3] dma-mapping:remove CONFIG_HAVE_DMA_ATTRS

From: FUJITA Tomonori
Date: Sun Jul 05 2009 - 22:29:32 EST


On Sun, 5 Jul 2009 20:44:18 +0800
Ming Lei <tom.leiming@xxxxxxxxx> wrote:

> On Sun, 5 Jul 2009 13:19:36 +0200
> Arnd Bergmann <arnd@xxxxxxxx> wrote:
>
> > On Saturday 04 July 2009, tom.leiming@xxxxxxxxx wrote:
> > > 2,Disabling CONFIG_HAVE_DMA_ATTRS may lead to a compile failure;
> >
> > I'm not sure I understand this point. CONFIG_HAVE_DMA_ATTRS tells
> > the common code whether the architecture understands dma attributes.
>
> If a new arch does not define CONFIG_HAVE_DMA_ATTRS but uses
> dma-mapping-common.h, it will lead to a compile failure.

Yeah, architectures that use dma-mapping-common.h need to define
CONFIG_HAVE_DMA_ATTRS because dma-mapping-common.h needs to handle
architectures that need CONFIG_HAVE_DMA_ATTRS.


Your idea doesn't sound good to me.

I think that it's better to define CONFIG_HAVE_DMA_ATTRS in the
consistent way; defining arch's Kconfig. Defining
CONFIG_HAVE_DMA_ATTRS in two different ways and inventing another
define such as ARCH_USE_DMA_MAPPING_COMMON is just confusing.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/