From: "tip-bot2 for Borislav Petkov" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Borislav Petkov <bp@suse.de>,
"Peter Zijlstra (Intel)" <peterz@infradead.org>,
x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: locking/core] x86/kvm/svm: Force-inline GHCB accessors
Date: Mon, 04 Apr 2022 17:46:49 -0000 [thread overview]
Message-ID: <164909440907.389.708776734897898729.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20220324183607.31717-3-bp@alien8.de>
The following commit has been merged into the locking/core branch of tip:
Commit-ID: 6b91ec4ad290a808a894e7d3448eb82d0b8ef8d5
Gitweb: https://git.kernel.org/tip/6b91ec4ad290a808a894e7d3448eb82d0b8ef8d5
Author: Borislav Petkov <bp@suse.de>
AuthorDate: Wed, 23 Mar 2022 21:52:44 +01:00
Committer: Borislav Petkov <bp@suse.de>
CommitterDate: Mon, 04 Apr 2022 10:13:20 +02:00
x86/kvm/svm: Force-inline GHCB accessors
In order to fix:
vmlinux.o: warning: objtool: __sev_es_nmi_complete()+0x4c: call to ghcb_set_sw_exit_code() leaves .noinstr.text section
Signed-off-by: Borislav Petkov <bp@suse.de>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20220324183607.31717-3-bp@alien8.de
---
arch/x86/include/asm/svm.h | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/arch/x86/include/asm/svm.h b/arch/x86/include/asm/svm.h
index f70a510..e255039 100644
--- a/arch/x86/include/asm/svm.h
+++ b/arch/x86/include/asm/svm.h
@@ -444,23 +444,23 @@ struct vmcb {
(offsetof(struct vmcb_save_area, field) / sizeof(u64))
#define DEFINE_GHCB_ACCESSORS(field) \
- static inline bool ghcb_##field##_is_valid(const struct ghcb *ghcb) \
+ static __always_inline bool ghcb_##field##_is_valid(const struct ghcb *ghcb) \
{ \
return test_bit(GHCB_BITMAP_IDX(field), \
(unsigned long *)&ghcb->save.valid_bitmap); \
} \
\
- static inline u64 ghcb_get_##field(struct ghcb *ghcb) \
+ static __always_inline u64 ghcb_get_##field(struct ghcb *ghcb) \
{ \
return ghcb->save.field; \
} \
\
- static inline u64 ghcb_get_##field##_if_valid(struct ghcb *ghcb) \
+ static __always_inline u64 ghcb_get_##field##_if_valid(struct ghcb *ghcb) \
{ \
return ghcb_##field##_is_valid(ghcb) ? ghcb->save.field : 0; \
} \
\
- static inline void ghcb_set_##field(struct ghcb *ghcb, u64 value) \
+ static __always_inline void ghcb_set_##field(struct ghcb *ghcb, u64 value) \
{ \
__set_bit(GHCB_BITMAP_IDX(field), \
(unsigned long *)&ghcb->save.valid_bitmap); \
next prev parent reply other threads:[~2022-04-04 22:08 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-24 18:36 [PATCH 0/3] Some trivial noinstr fixes Borislav Petkov
2022-03-24 18:36 ` [PATCH 1/3] task_stack, x86/cea: Force-inline stack helpers Borislav Petkov
2022-04-04 17:46 ` [tip: locking/core] " tip-bot2 for Borislav Petkov
2022-03-24 18:36 ` [PATCH 2/3] x86/kvm/svm: Force-inline GHCB accessors Borislav Petkov
2022-04-04 17:46 ` tip-bot2 for Borislav Petkov [this message]
2022-03-24 18:36 ` [PATCH 3/3] x86/mm: Force-inline __phys_addr_nodebug() Borislav Petkov
2022-04-04 17:46 ` [tip: locking/core] " tip-bot2 for Borislav Petkov
2022-03-25 7:44 ` [PATCH 0/3] Some trivial noinstr fixes Peter Zijlstra
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=164909440907.389.708776734897898729.tip-bot2@tip-bot2 \
--to=tip-bot2@linutronix.de \
--cc=bp@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.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®