Messages in this thread Patch in this message | | | From | cgel.zte@gmail ... | Subject | [PATCH] x86/kaslr: fix boolreturn.cocci warning | Date | Mon, 1 Nov 2021 08:49:48 +0000 |
| |
From: Changcheng Deng <deng.changcheng@zte.com.cn>
./arch/x86/boot/compressed/kaslr.c: 671: 8-9: WARNING: return of 0/1 in function 'process_mem_region' with return type bool
Return statements in functions returning bool should use true/false instead of 1/0.
Reported-by: Zeal Robot <zealci@zte.com.cn> Signed-off-by: Changcheng Deng <deng.changcheng@zte.com.cn> --- arch/x86/boot/compressed/kaslr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/boot/compressed/kaslr.c b/arch/x86/boot/compressed/kaslr.c index 67c3208b668a..a4a10c7c5330 100644 --- a/arch/x86/boot/compressed/kaslr.c +++ b/arch/x86/boot/compressed/kaslr.c @@ -672,7 +672,7 @@ static bool process_mem_region(struct mem_vector *region, } } #endif - return 0; + return false; } #ifdef CONFIG_EFI -- 2.25.1
| |