[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <164512418472.16921.4231263161341190140.tip-bot2@tip-bot2>
Date: Thu, 17 Feb 2022 18:56:24 -0000
From: "tip-bot2 for Masahiro Yamada" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Masahiro Yamada <masahiroy@...nel.org>,
"Peter Zijlstra (Intel)" <peterz@...radead.org>, x86@...nel.org,
linux-kernel@...r.kernel.org
Subject: [tip: locking/core] jump_label: Avoid unneeded casts in
STATIC_KEY_INIT_{TRUE,FALSE}
The following commit has been merged into the locking/core branch of tip:
Commit-ID: fe65deb56e552a8c9bf7f27860dbdeac12a36116
Gitweb: https://git.kernel.org/tip/fe65deb56e552a8c9bf7f27860dbdeac12a36116
Author: Masahiro Yamada <masahiroy@...nel.org>
AuthorDate: Mon, 14 Feb 2022 01:57:16 +09:00
Committer: Peter Zijlstra <peterz@...radead.org>
CommitterDate: Wed, 16 Feb 2022 15:57:58 +01:00
jump_label: Avoid unneeded casts in STATIC_KEY_INIT_{TRUE,FALSE}
Commit 3821fd35b58d ("jump_label: Reduce the size of struct static_key")
introduced the union to struct static_key.
It is more natual to set JUMP_TYPE_* to the .type field without casting.
Signed-off-by: Masahiro Yamada <masahiroy@...nel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@...radead.org>
Link: https://lkml.kernel.org/r/20220213165717.2354046-1-masahiroy@kernel.org
---
include/linux/jump_label.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/linux/jump_label.h b/include/linux/jump_label.h
index 48b9b2a..6924e68 100644
--- a/include/linux/jump_label.h
+++ b/include/linux/jump_label.h
@@ -251,10 +251,10 @@ extern void static_key_disable_cpuslocked(struct static_key *key);
*/
#define STATIC_KEY_INIT_TRUE \
{ .enabled = { 1 }, \
- { .entries = (void *)JUMP_TYPE_TRUE } }
+ { .type = JUMP_TYPE_TRUE } }
#define STATIC_KEY_INIT_FALSE \
{ .enabled = { 0 }, \
- { .entries = (void *)JUMP_TYPE_FALSE } }
+ { .type = JUMP_TYPE_FALSE } }
#else /* !CONFIG_JUMP_LABEL */
Powered by blists - more mailing lists