linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] x86/kaslr: Return true/false (not 1/0) from bool functions
@ 2022-04-21 20:25 Jiapeng Chong
  2022-11-19 16:45 ` [tip: x86/cleanups] x86/kaslr: Fix process_mem_region()'s return value tip-bot2 for Jiapeng Chong
  0 siblings, 1 reply; 2+ messages in thread
From: Jiapeng Chong @ 2022-04-21 20:25 UTC (permalink / raw)
  To: tglx
  Cc: mingo, bp, dave.hansen, x86, hpa, linux-kernel, Jiapeng Chong,
	Abaci Robot

Fix the following coccicheck warning:

./arch/x86/boot/compressed/kaslr.c:670:8-9: WARNING: return of 0/1 in
function 'process_mem_region' with return type bool.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
---
 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 4a3f223973f4..43995c59e652 100644
--- a/arch/x86/boot/compressed/kaslr.c
+++ b/arch/x86/boot/compressed/kaslr.c
@@ -667,7 +667,7 @@ static bool process_mem_region(struct mem_vector *region,
 		}
 	}
 #endif
-	return 0;
+	return false;
 }
 
 #ifdef CONFIG_EFI
-- 
2.20.1.7.g153144c


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

* [tip: x86/cleanups] x86/kaslr: Fix process_mem_region()'s return value
  2022-04-21 20:25 [PATCH] x86/kaslr: Return true/false (not 1/0) from bool functions Jiapeng Chong
@ 2022-11-19 16:45 ` tip-bot2 for Jiapeng Chong
  0 siblings, 0 replies; 2+ messages in thread
From: tip-bot2 for Jiapeng Chong @ 2022-11-19 16:45 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: Abaci Robot, Jiapeng Chong, Borislav Petkov, x86, linux-kernel

The following commit has been merged into the x86/cleanups branch of tip:

Commit-ID:     ee92fa03918d114d3ac9c36a8bf2c032ede75a3b
Gitweb:        https://git.kernel.org/tip/ee92fa03918d114d3ac9c36a8bf2c032ede75a3b
Author:        Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
AuthorDate:    Fri, 22 Apr 2022 04:25:56 +08:00
Committer:     Borislav Petkov <bp@suse.de>
CommitterDate: Sat, 19 Nov 2022 17:35:10 +01:00

x86/kaslr: Fix process_mem_region()'s return value

Fix the following coccicheck warning:

  ./arch/x86/boot/compressed/kaslr.c:670:8-9: WARNING: return of 0/1 in
  function 'process_mem_region' with return type bool.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Link: https://lore.kernel.org/r/20220421202556.129799-1-jiapeng.chong@linux.alibaba.com
---
 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 e476bcb..454757f 100644
--- a/arch/x86/boot/compressed/kaslr.c
+++ b/arch/x86/boot/compressed/kaslr.c
@@ -668,7 +668,7 @@ static bool process_mem_region(struct mem_vector *region,
 		}
 	}
 #endif
-	return 0;
+	return false;
 }
 
 #ifdef CONFIG_EFI

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

end of thread, other threads:[~2022-11-19 16:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-21 20:25 [PATCH] x86/kaslr: Return true/false (not 1/0) from bool functions Jiapeng Chong
2022-11-19 16:45 ` [tip: x86/cleanups] x86/kaslr: Fix process_mem_region()'s return value tip-bot2 for Jiapeng Chong

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