Re: [PATCH] remove DMA_nBIT_MASK macro

From: FUJITA Tomonori
Date: Thu May 07 2009 - 19:37:26 EST


On Thu, 7 May 2009 13:18:46 +0200
Ingo Molnar <mingo@xxxxxxx> wrote:

>
> * Yang Hongyang <yanghy@xxxxxxxxxxxxxx> wrote:
>
> > FUJITA Tomonori wrote:
> > > We replaced all DMA_nBIT_MASK macros with DMA_BIT_MASK(n) but why do
> > > we still keep DMA_nBIT_MASK macros in include/linux/dma-mapping.h?
> > >
> > > As long as these macros exist, people use them. The current git has
> > > two users and linux-next have other users.
> > >
> > > Is it better to remove DMA_nBIT_MASK macros completely now?
>
> Can you see a way to emit build warnings? If yes then that might be
> a better solution instead of breaking in-the-pipeline code.

Unfortunately, no. Since 2.6.24, include/linux/dma-mapping.h has the
warning:

/*
* NOTE: do not use the below macros in new code and do not add new definitions
* here.
*
* Instead, just open-code DMA_BIT_MASK(n) within your driver
*/

IMO, we give people enough time for migration.


> We missed the upstream window of removing the facilities altogether,
> we could certainly do that in the next merge window though.

Can you apply this patch to the tip? I want to have this patch in
linux-next to let new users of DMA-nBIT_MASK in linux-next know that
they use wrong macros.
--
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/