linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* md: Use existed macro instead of number
@ 2012-02-24  7:00 kedacomkernel
  2012-02-26 22:57 ` NeilBrown
  0 siblings, 1 reply; 2+ messages in thread
From: kedacomkernel @ 2012-02-24  7:00 UTC (permalink / raw)
  To: Neil Brown; +Cc: linux-raid

From d5905ed3c5355a13e954057856733f8ad64a86ac Mon Sep 17 00:00:00 2001
From: majianpeng <majianpeng@gmail.com>
Date: Fri, 24 Feb 2012 22:49:45 +0800
Subject: [PATCH] md: Use existed macro instead of number


Signed-off-by: majianpeng <majianpeng@gmail.com>
---
 include/linux/raid/md_p.h |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/include/linux/raid/md_p.h b/include/linux/raid/md_p.h
index 6f6df86..7c3577c 100644
--- a/include/linux/raid/md_p.h
+++ b/include/linux/raid/md_p.h
@@ -281,6 +281,8 @@ struct mdp_superblock_1 {
 					    * active device with same 'role'.
 					    * 'recovery_offset' is also set.
 					    */
-#define	MD_FEATURE_ALL			(1|2|4|8|16)
-
+#define	MD_FEATURE_ALL			(MD_FEATURE_BITMAP_OFFSET | MD_FEATURE_RECOVERY_OFFSET | \
+					MD_FEATURE_RESHAPE_ACTIVE | MD_FEATURE_BAD_BLOCKS | \
+					MD_FEATURE_REPLACEMENT)
+
 #endif 
-- 
1.7.5.4

 				
--------------
kedacomkernel
2012-02-24


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

* Re: md: Use existed macro instead of number
  2012-02-24  7:00 md: Use existed macro instead of number kedacomkernel
@ 2012-02-26 22:57 ` NeilBrown
  0 siblings, 0 replies; 2+ messages in thread
From: NeilBrown @ 2012-02-26 22:57 UTC (permalink / raw)
  To: kedacomkernel; +Cc: linux-raid

[-- Attachment #1: Type: text/plain, Size: 1972 bytes --]

On Fri, 24 Feb 2012 15:00:21 +0800 "kedacomkernel" <kedacomkernel@gmail.com>
wrote:

> >From d5905ed3c5355a13e954057856733f8ad64a86ac Mon Sep 17 00:00:00 2001
> From: majianpeng <majianpeng@gmail.com>
> Date: Fri, 24 Feb 2012 22:49:45 +0800
> Subject: [PATCH] md: Use existed macro instead of number
> 
> 
> Signed-off-by: majianpeng <majianpeng@gmail.com>
> ---
>  include/linux/raid/md_p.h |    6 ++++--
>  1 files changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/include/linux/raid/md_p.h b/include/linux/raid/md_p.h
> index 6f6df86..7c3577c 100644
> --- a/include/linux/raid/md_p.h
> +++ b/include/linux/raid/md_p.h
> @@ -281,6 +281,8 @@ struct mdp_superblock_1 {
>  					    * active device with same 'role'.
>  					    * 'recovery_offset' is also set.
>  					    */
> -#define	MD_FEATURE_ALL			(1|2|4|8|16)
> -
> +#define	MD_FEATURE_ALL			(MD_FEATURE_BITMAP_OFFSET | MD_FEATURE_RECOVERY_OFFSET | \
> +					MD_FEATURE_RESHAPE_ACTIVE | MD_FEATURE_BAD_BLOCKS | \
> +					MD_FEATURE_REPLACEMENT)
> +
>  #endif 

Applied, thanks.
Though I reformatted it a bit.

NeilBrown

commit 473a5bfef64c6c328bc110f28ba6c32fe4d4508a
Author: majianpeng <majianpeng@gmail.com>
Date:   Mon Feb 27 09:56:59 2012 +1100

    md: Use existed macros instead of numbers
    
    Signed-off-by: majianpeng <majianpeng@gmail.com>
    Signed-off-by: NeilBrown <neilb@suse.de>

diff --git a/include/linux/raid/md_p.h b/include/linux/raid/md_p.h
index 6f6df86..8c0a3ad 100644
--- a/include/linux/raid/md_p.h
+++ b/include/linux/raid/md_p.h
@@ -281,6 +281,10 @@ struct mdp_superblock_1 {
 					    * active device with same 'role'.
 					    * 'recovery_offset' is also set.
 					    */
-#define	MD_FEATURE_ALL			(1|2|4|8|16)
+#define	MD_FEATURE_ALL			(MD_FEATURE_BITMAP_OFFSET	\
+					|MD_FEATURE_RECOVERY_OFFSET	\
+					|MD_FEATURE_RESHAPE_ACTIVE	\
+					|MD_FEATURE_BAD_BLOCKS		\
+					|MD_FEATURE_REPLACEMENT)
 
 #endif 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

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

end of thread, other threads:[~2012-02-26 22:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-24  7:00 md: Use existed macro instead of number kedacomkernel
2012-02-26 22:57 ` NeilBrown

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).