mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "tip-bot2 for Masahiro Yamada" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Masahiro Yamada <masahiroy@kernel.org>,
	"Peter Zijlstra (Intel)" <peterz@infradead.org>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: locking/core] jump_label: Avoid unneeded casts in STATIC_KEY_INIT_{TRUE,FALSE}
Date: Thu, 17 Feb 2022 18:56:24 -0000	[thread overview]
Message-ID: <164512418472.16921.4231263161341190140.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20220213165717.2354046-1-masahiroy@kernel.org>

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@kernel.org>
AuthorDate:    Mon, 14 Feb 2022 01:57:16 +09:00
Committer:     Peter Zijlstra <peterz@infradead.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@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.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 */
 

      parent reply	other threads:[~2022-02-17 18:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-13 16:57 [PATCH 1/2] jump_label: avoid " Masahiro Yamada
2022-02-13 16:57 ` [PATCH 2/2] jump_label: refactor #ifdef of struct static_key Masahiro Yamada
2022-02-17 18:56   ` [tip: locking/core] jump_label: Refactor " tip-bot2 for Masahiro Yamada
2022-02-18 19:07   ` [PATCH 2/2] jump_label: refactor " Jason Baron
2022-02-18 19:27     ` Josh Poimboeuf
2022-02-17 18:56 ` tip-bot2 for Masahiro Yamada [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=164512418472.16921.4231263161341190140.tip-bot2@tip-bot2 \
    --to=tip-bot2@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=peterz@infradead.org \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®