From: Segher Boessenkool <segher@kernel.crashing.org>
To: Nick Desaulniers <ndesaulniers@google.com>
Cc: Borislav Petkov <bp@alien8.de>, X86 ML <x86@kernel.org>,
Michael Matz <matz@suse.de>,
linux-toolchains@vger.kernel.org,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] x86/sev: Mark snp_abort() noreturn
Date: Wed, 24 Aug 2022 14:43:49 -0500 [thread overview]
Message-ID: <20220824194349.GB25951@gate.crashing.org> (raw)
In-Reply-To: <CAKwvOdm+yFhZ2pYLJ5vpj1YyNJmG=UVF4cTz_m+0UfDGNGsRbQ@mail.gmail.com>
On Wed, Aug 24, 2022 at 11:44:35AM -0700, Nick Desaulniers wrote:
> On Wed, Aug 24, 2022 at 10:33 AM Segher Boessenkool
> <segher@kernel.crashing.org> wrote:
> > On Wed, Aug 24, 2022 at 05:24:20PM +0200, Borislav Petkov wrote:
> > > Mark both the function prototype and definition as noreturn in order to
> > > prevent the compiler from doing transformations which confuse objtool
> > > like so:
> > >
> > > vmlinux.o: warning: objtool: sme_enable+0x71: unreachable instruction
> >
> > Would -Wmissing-noreturn have caught this?
>
> Oh, that's shiny. Is that relatively new?
Relatively, yes.
commit 0ca3fb0a168e9db2bd5405855d3932f62b08b7c9
Author: Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
Date: Tue Oct 20 07:32:08 1998 +0000
New warning, `missing-noreturn':
The alias -Wsuggest-attribute=noreturn is newer:
commit 94ee697923f5a93881edbc5e1b3f810b290f0fc7
Author: Manuel López-Ibáñez <manu@gcc.gnu.org>
Date: Sun Apr 29 09:15:30 2012 +0000
* common.opt (Wmissing-noreturn): Alias of -Wsuggest-attribute=noret
Segher
next prev parent reply other threads:[~2022-08-24 19:51 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-24 15:24 [PATCH] x86/sev: Mark snp_abort() noreturn Borislav Petkov
2022-08-24 15:38 ` Peter Zijlstra
2022-08-24 15:48 ` Borislav Petkov
2022-08-24 16:16 ` Peter Zijlstra
2022-08-24 16:43 ` [PATCH v2] " Borislav Petkov
2022-08-24 17:29 ` [PATCH] " Segher Boessenkool
2022-08-24 18:23 ` Borislav Petkov
2022-08-24 18:44 ` Nick Desaulniers
2022-08-24 19:43 ` Segher Boessenkool [this message]
2022-08-24 20:45 ` Peter Zijlstra
2022-08-24 22:41 ` Segher Boessenkool
2022-08-25 6:41 ` Peter Zijlstra
2022-08-25 12:29 ` Michael Matz
2022-08-25 12:58 ` Segher Boessenkool
2022-08-25 13:12 ` David Laight
2022-08-30 4:48 ` Josh Poimboeuf
2022-08-30 4:46 ` Josh Poimboeuf
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=20220824194349.GB25951@gate.crashing.org \
--to=segher@kernel.crashing.org \
--cc=bp@alien8.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-toolchains@vger.kernel.org \
--cc=matz@suse.de \
--cc=ndesaulniers@google.com \
--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;
as well as URLs for NNTP newsgroup(s).