netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Yang Hongyang <yanghy@cn.fujitsu.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	"David S. Miller" <davem@davemloft.net>,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	Borislav Petkov <petkovbb@googlemail.com>
Subject: Re: [PATCH 11/12]Remove defines of DMA_XXBIT_MASK micro
Date: Thu, 19 Feb 2009 09:14:03 +0100	[thread overview]
Message-ID: <20090219081403.GA5400@elte.hu> (raw)
In-Reply-To: <499D0221.9090407@cn.fujitsu.com>


* Yang Hongyang <yanghy@cn.fujitsu.com> wrote:

> Remove defines of DMA_XXBIT_MASK micro
> 
> Signed-off-by: Yang Hongyang<yanghy@cn.fujitsu.com>
> 
> ---
>  include/linux/dma-mapping.h |   20 +-------------------
>  1 files changed, 1 insertions(+), 19 deletions(-)
> 
> diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h
> index f238c7e..70f9c63 100644
> --- a/include/linux/dma-mapping.h
> +++ b/include/linux/dma-mapping.h
> @@ -13,27 +13,9 @@ enum dma_data_direction {
>  	DMA_NONE = 3,
>  };
>  
> +/*use DMA_BIT_MASK(n) within your driver instead of DMA_xxBIT_MASK*/
>  #define DMA_BIT_MASK(n)	(((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
>  
> -/*
> - * 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
> - */
> -#define DMA_64BIT_MASK	DMA_BIT_MASK(64)
> -#define DMA_48BIT_MASK	DMA_BIT_MASK(48)
> -#define DMA_47BIT_MASK	DMA_BIT_MASK(47)
> -#define DMA_40BIT_MASK	DMA_BIT_MASK(40)
> -#define DMA_39BIT_MASK	DMA_BIT_MASK(39)
> -#define DMA_35BIT_MASK	DMA_BIT_MASK(35)
> -#define DMA_32BIT_MASK	DMA_BIT_MASK(32)
> -#define DMA_31BIT_MASK	DMA_BIT_MASK(31)
> -#define DMA_30BIT_MASK	DMA_BIT_MASK(30)
> -#define DMA_29BIT_MASK	DMA_BIT_MASK(29)
> -#define DMA_28BIT_MASK	DMA_BIT_MASK(28)
> -#define DMA_24BIT_MASK	DMA_BIT_MASK(24)

Looks good beyond the s/micro/macro typo fix, but i'd suggest to 
keep these old defines for one more kernel cycle, then do a 
final removal of all remaining uses, in a single patch.

That way we'll save ourselves from quite a bit of unnecessary 
build breakages (as your patchset shows there's still a lot of 
users of the old macros), as these definitions get moved around, 
reintroduced, etc.

Conflict resolution becomes easier as well - if such a patch 
conflicts with some ongoing work then we can by avoid the 
conflict by just dropping that hunk and delaying that particular 
conversion to the 'final' stage.

	Ingo

  reply	other threads:[~2009-02-19  8:14 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-19  6:35 [PATCH 00/12]Next:Get rid of all the old micro DMA_XXBIT_MASK and use DMA_BIT_MASK(n) instead Yang Hongyang
2009-02-19  6:38 ` [PATCH 01/12]Replace all DMA_64BIT_MASK micro with DMA_BIT_MASK(64) Yang Hongyang
2009-02-19  6:40 ` [PATCH 02/12]Replace all DMA_48BIT_MASK micro with DMA_BIT_MASK(48) Yang Hongyang
2009-02-19  6:41 ` [PATCH 03/12]Replace all DMA_40BIT_MASK micro with DMA_BIT_MASK(40) Yang Hongyang
2009-02-19  6:44 ` [PATCH 04/12]Replace all DMA_39BIT_MASK micro with DMA_BIT_MASK(39) Yang Hongyang
2009-02-19  6:45 ` [PATCH 05/12]Replace all DMA_35BIT_MASK micro with DMA_BIT_MASK(35) Yang Hongyang
2009-02-19  6:46 ` [PATCH 06/12]Replace all DMA_32BIT_MASK micro with DMA_BIT_MASK(32) Yang Hongyang
2009-02-19  6:48 ` [PATCH 07/12]Replace all DMA_31BIT_MASK micro with DMA_BIT_MASK(31) Yang Hongyang
2009-02-19  6:49 ` [PATCH 00/12]Next:Get rid of all the old micro DMA_XXBIT_MASK and use DMA_BIT_MASK(n) instead Américo Wang
2009-02-19  8:52   ` Yang Hongyang
2009-02-19  6:49 ` [PATCH 08/12]Replace all DMA_30BIT_MASK micro with DMA_BIT_MASK(30) Yang Hongyang
2009-02-19  6:51 ` [PATCH 09/12]Replace all DMA_28BIT_MASK micro with DMA_BIT_MASK(28) Yang Hongyang
2009-02-19  6:53 ` [PATCH 10/12]Replace all DMA_24BIT_MASK micro with DMA_BIT_MASK(24) Yang Hongyang
2009-02-19  6:54 ` [PATCH 11/12]Remove defines of DMA_XXBIT_MASK micro Yang Hongyang
2009-02-19  8:14   ` Ingo Molnar [this message]
2009-02-19  8:56     ` Yang Hongyang
2009-02-19  9:32       ` [PATCHv2 00/11]Get rid of all the old macro DMA_nBIT_MASK and use DMA_BIT_MASK(n) instead Yang Hongyang
2009-02-19  9:36         ` [PATCHv2 01/11]Replace all DMA_64BIT_MASK macro with DMA_BIT_MASK(64) Yang Hongyang
2009-02-19  9:38         ` [PATCHv2 02/11]Replace all DMA_48BIT_MASK macro with DMA_BIT_MASK(48) Yang Hongyang
2009-02-19  9:40         ` [PATCHv2 03/11]Replace all DMA_40BIT_MASK macro with DMA_BIT_MASK(40) Yang Hongyang
2009-02-19  9:42         ` [PATCHv2 04/11]Replace all DMA_39BIT_MASK macro with DMA_BIT_MASK(39) Yang Hongyang
2009-02-19  9:43         ` [PATCHv2 05/11]Replace all DMA_35BIT_MASK macro with DMA_BIT_MASK(35) Yang Hongyang
2009-02-19  9:45         ` [PATCHv2 06/11]Replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) Yang Hongyang
2009-02-19 12:50           ` Stefan Richter
2009-02-19  9:47         ` [PATCHv2 07/11]Replace all DMA_31BIT_MASK macro with DMA_BIT_MASK(31) Yang Hongyang
2009-02-19  9:48         ` [PATCHv2 08/11]Replace all DMA_30BIT_MASK macro with DMA_BIT_MASK(30) Yang Hongyang
2009-02-19  9:50         ` [PATCHv2 09/11]Replace all DMA_28BIT_MASK macro with DMA_BIT_MASK(28) Yang Hongyang
2009-02-19  9:51         ` [PATCHv2 10/11]Replace all DMA_24BIT_MASK macro with DMA_BIT_MASK(24) Yang Hongyang
2009-02-19  9:53         ` [PATCHv2 11/11]Update the old macro DMA_nBIT_MASK related documentations Yang Hongyang
2009-02-19 12:47         ` [PATCHv2 00/11]Get rid of all the old macro DMA_nBIT_MASK and use DMA_BIT_MASK(n) instead Stefan Richter
2009-02-19 15:08           ` Ingo Molnar
2009-02-19 23:14             ` Andrew Morton
2009-02-20 10:29               ` Ingo Molnar
2009-02-19  6:55 ` [PATCH 12/12]Update related documentations Yang Hongyang

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=20090219081403.GA5400@elte.hu \
    --to=mingo@elte.hu \
    --cc=akpm@linux-foundation.org \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=petkovbb@googlemail.com \
    --cc=yanghy@cn.fujitsu.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;
as well as URLs for NNTP newsgroup(s).