Skip to content

Commit 4f8cef5

Browse files
kbuild test robotIngo Molnar
authored andcommitted
x86/fpu: Fix boolreturn.cocci warnings
arch/x86/kernel/fpu/xstate.c:931:9-10: WARNING: return of 0/1 in function 'xfeatures_mxcsr_quirk' with return type bool Return statements in functions returning bool should use true/false instead of 1/0. Generated by: scripts/coccinelle/misc/boolreturn.cocci Signed-off-by: Fengguang Wu <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Cc: Andrew Morton <[email protected]> Cc: Andy Lutomirski <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: Dave Hansen <[email protected]> Cc: Eric Biggers <[email protected]> Cc: Fenghua Yu <[email protected]> Cc: Linus Torvalds <[email protected]> Cc: Oleg Nesterov <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Rik van Riel <[email protected]> Cc: Yu-cheng Yu <[email protected]> Cc: [email protected] Cc: [email protected] Link: http://lkml.kernel.org/r/20170306004553.GA25764@lkp-wsm-ep1 Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Ingo Molnar <[email protected]>
1 parent 0852b37 commit 4f8cef5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

arch/x86/kernel/fpu/xstate.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -929,12 +929,12 @@ int arch_set_user_pkey_access(struct task_struct *tsk, int pkey,
929929
static inline bool xfeatures_mxcsr_quirk(u64 xfeatures)
930930
{
931931
if (!(xfeatures & (XFEATURE_MASK_SSE|XFEATURE_MASK_YMM)))
932-
return 0;
932+
return false;
933933

934934
if (xfeatures & XFEATURE_MASK_FP)
935-
return 0;
935+
return false;
936936

937-
return 1;
937+
return true;
938938
}
939939

940940
/*

0 commit comments

Comments
 (0)