* [PATCH] x86: add REQUIRED_MASK8
@ 2008-11-14 21:20 Simon Arlott
2008-11-20 2:47 ` Yang, Sheng
0 siblings, 1 reply; 2+ messages in thread
From: Simon Arlott @ 2008-11-14 21:20 UTC (permalink / raw)
To: Linux Kernel Mailing List, trivial; +Cc: sheng.yang
commit e38e05a85828dac23540cd007df5f20985388afc increased NCAPINTS to 9
but didn't add REQUIRED_MASK8 resulting in the following sparse warnings:
arch/x86/boot/cpustr.h:311:5: warning: undefined preprocessor identifier 'REQUIRED_MASK8'
arch/x86/boot/cpustr.h:314:5: warning: undefined preprocessor identifier 'REQUIRED_MASK8'
arch/x86/boot/cpustr.h:317:5: warning: undefined preprocessor identifier 'REQUIRED_MASK8'
arch/x86/boot/cpustr.h:320:5: warning: undefined preprocessor identifier 'REQUIRED_MASK8'
arch/x86/boot/cpustr.h:323:5: warning: undefined preprocessor identifier 'REQUIRED_MASK8'
Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Cc: Sheng Yang <sheng.yang@intel.com>
---
arch/x86/boot/cpucheck.c | 1 +
arch/x86/include/asm/cpufeature.h | 3 ++-
arch/x86/include/asm/required-features.h | 1 +
3 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/arch/x86/boot/cpucheck.c b/arch/x86/boot/cpucheck.c
index 4d3ff03..41559bf 100644
--- a/arch/x86/boot/cpucheck.c
+++ b/arch/x86/boot/cpucheck.c
@@ -44,6 +44,7 @@ static const u32 req_flags[NCAPINTS] =
0, /* REQUIRED_MASK5 not implemented in this file */
REQUIRED_MASK6,
0, /* REQUIRED_MASK7 not implemented in this file */
+ 0 /* REQUIRED_MASK8 not implemented in this file */
};
#define A32(a, b, c, d) (((d) << 24)+((c) << 16)+((b) << 8)+(a))
diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h
index cfdf8c2..9761800 100644
--- a/arch/x86/include/asm/cpufeature.h
+++ b/arch/x86/include/asm/cpufeature.h
@@ -178,7 +178,8 @@ extern const char * const x86_power_flags[32];
(((bit)>>5)==4 && (1UL<<((bit)&31) & REQUIRED_MASK4)) || \
(((bit)>>5)==5 && (1UL<<((bit)&31) & REQUIRED_MASK5)) || \
(((bit)>>5)==6 && (1UL<<((bit)&31) & REQUIRED_MASK6)) || \
- (((bit)>>5)==7 && (1UL<<((bit)&31) & REQUIRED_MASK7)) ) \
+ (((bit)>>5)==7 && (1UL<<((bit)&31) & REQUIRED_MASK7)) || \
+ (((bit)>>5)==8 && (1UL<<((bit)&31) & REQUIRED_MASK8)) ) \
? 1 : \
test_cpu_cap(c, bit))
diff --git a/arch/x86/include/asm/required-features.h b/arch/x86/include/asm/required-features.h
index d5cd6c5..0baa45d 100644
--- a/arch/x86/include/asm/required-features.h
+++ b/arch/x86/include/asm/required-features.h
@@ -78,5 +78,6 @@
#define REQUIRED_MASK5 0
#define REQUIRED_MASK6 0
#define REQUIRED_MASK7 0
+#define REQUIRED_MASK8 0
#endif /* _ASM_X86_REQUIRED_FEATURES_H */
--
1.6.0.3
--
Simon Arlott
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] x86: add REQUIRED_MASK8
2008-11-14 21:20 [PATCH] x86: add REQUIRED_MASK8 Simon Arlott
@ 2008-11-20 2:47 ` Yang, Sheng
0 siblings, 0 replies; 2+ messages in thread
From: Yang, Sheng @ 2008-11-20 2:47 UTC (permalink / raw)
To: Simon Arlott; +Cc: Linux Kernel Mailing List, trivial@kernel.org
On Saturday 15 November 2008 05:20:16 Simon Arlott wrote:
> commit e38e05a85828dac23540cd007df5f20985388afc increased NCAPINTS to 9
> but didn't add REQUIRED_MASK8 resulting in the following sparse warnings:
>
> arch/x86/boot/cpustr.h:311:5: warning: undefined preprocessor identifier
> 'REQUIRED_MASK8' arch/x86/boot/cpustr.h:314:5: warning: undefined
> preprocessor identifier 'REQUIRED_MASK8' arch/x86/boot/cpustr.h:317:5:
> warning: undefined preprocessor identifier 'REQUIRED_MASK8'
> arch/x86/boot/cpustr.h:320:5: warning: undefined preprocessor identifier
> 'REQUIRED_MASK8' arch/x86/boot/cpustr.h:323:5: warning: undefined
> preprocessor identifier 'REQUIRED_MASK8'
Thanks for the fixing! :)
>
> Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
> Cc: Sheng Yang <sheng.yang@intel.com>
Reviewed-by: Sheng Yang <sheng.yang@intel.com>
--
regards
Yang, Sheng
> ---
> arch/x86/boot/cpucheck.c | 1 +
> arch/x86/include/asm/cpufeature.h | 3 ++-
> arch/x86/include/asm/required-features.h | 1 +
> 3 files changed, 4 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/boot/cpucheck.c b/arch/x86/boot/cpucheck.c
> index 4d3ff03..41559bf 100644
> --- a/arch/x86/boot/cpucheck.c
> +++ b/arch/x86/boot/cpucheck.c
> @@ -44,6 +44,7 @@ static const u32 req_flags[NCAPINTS] =
> 0, /* REQUIRED_MASK5 not implemented in this file */
> REQUIRED_MASK6,
> 0, /* REQUIRED_MASK7 not implemented in this file */
> + 0 /* REQUIRED_MASK8 not implemented in this file */
> };
>
> #define A32(a, b, c, d) (((d) << 24)+((c) << 16)+((b) << 8)+(a))
> diff --git a/arch/x86/include/asm/cpufeature.h
> b/arch/x86/include/asm/cpufeature.h index cfdf8c2..9761800 100644
> --- a/arch/x86/include/asm/cpufeature.h
> +++ b/arch/x86/include/asm/cpufeature.h
> @@ -178,7 +178,8 @@ extern const char * const x86_power_flags[32];
> (((bit)>>5)==4 && (1UL<<((bit)&31) & REQUIRED_MASK4)) || \
> (((bit)>>5)==5 && (1UL<<((bit)&31) & REQUIRED_MASK5)) || \
> (((bit)>>5)==6 && (1UL<<((bit)&31) & REQUIRED_MASK6)) || \
> - (((bit)>>5)==7 && (1UL<<((bit)&31) & REQUIRED_MASK7)) ) \
> + (((bit)>>5)==7 && (1UL<<((bit)&31) & REQUIRED_MASK7)) || \
> + (((bit)>>5)==8 && (1UL<<((bit)&31) & REQUIRED_MASK8)) ) \
> ? 1 : \
> test_cpu_cap(c, bit))
>
> diff --git a/arch/x86/include/asm/required-features.h
> b/arch/x86/include/asm/required-features.h index d5cd6c5..0baa45d 100644
> --- a/arch/x86/include/asm/required-features.h
> +++ b/arch/x86/include/asm/required-features.h
> @@ -78,5 +78,6 @@
> #define REQUIRED_MASK5 0
> #define REQUIRED_MASK6 0
> #define REQUIRED_MASK7 0
> +#define REQUIRED_MASK8 0
>
> #endif /* _ASM_X86_REQUIRED_FEATURES_H */
> --
> 1.6.0.3
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-11-20 2:50 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-14 21:20 [PATCH] x86: add REQUIRED_MASK8 Simon Arlott
2008-11-20 2:47 ` Yang, Sheng
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox