All of lore.kernel.org
 help / color / mirror / Atom feed
From: Julien Grall <julien@xen.org>
To: Jan Beulich <jbeulich@suse.com>,
	"xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>
Cc: "Roger Pau Monné" <roger.pau@citrix.com>,
	"Andrew Cooper" <andrew.cooper3@citrix.com>,
	"George Dunlap" <george.dunlap@citrix.com>,
	"Ian Jackson" <iwj@xenproject.org>,
	"Stefano Stabellini" <sstabellini@kernel.org>,
	"Wei Liu" <wl@xen.org>
Subject: Re: [PATCH v2 1/4] x86: verify function type (and maybe attribute) in switch_stack_and_jump()
Date: Mon, 21 Dec 2020 16:23:06 +0000	[thread overview]
Message-ID: <896456a9-16cb-2549-f3a1-e431d5e6479c@xen.org> (raw)
In-Reply-To: <792c442d-c05a-7a00-c807-b94a54bca94f@suse.com>

Hi Jan,

On 15/12/2020 16:11, Jan Beulich wrote:
> It is imperative that the functions passed here are taking no arguments,
> return no values, and don't return in the first place. While the type
> can be checked uniformly, the attribute check is limited to gcc 9 and
> newer (no clang support for this so far afaict).
> 
> Note that I didn't want to have the "true" fallback "implementation" of
> __builtin_has_attribute(..., __noreturn__) generally available, as
> "true" may not be a suitable fallback in other cases.
> 
> Note further that the noreturn addition to startup_cpu_idle_loop()'s
> declaration requires adding unreachable() to Arm's
> switch_stack_and_jump(), or else the build would break. I suppose this
> should have been there already.
> 
> For vmx_asm_do_vmentry() along with adding the attribute, also restrict
> its scope.
> 
> Signed-off-by: Jan Beulich <jbeulich@suse.com>
> Reviewed-by: Juergen Gross <jgross@suse.com>

For the Arm bits:

Acked-by: Julien Grall <jgrall@amazon.com>

Cheers,

-- 
Julien Grall


  parent reply	other threads:[~2020-12-21 16:23 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-15 16:09 [PATCH v2 0/4] x86: XSA-348 follow-up Jan Beulich
2020-12-15 16:11 ` [PATCH v2 1/4] x86: verify function type (and maybe attribute) in switch_stack_and_jump() Jan Beulich
2020-12-15 16:28   ` Wei Liu
2020-12-21 16:23   ` Julien Grall [this message]
2020-12-15 16:12 ` [PATCH v2 2/4] x86: clobber registers in switch_stack_and_jump() when !LIVEPATCH Jan Beulich
2020-12-15 16:28   ` Wei Liu
2020-12-15 16:12 ` [PATCH v2 3/4] x86/PV: avoid double stack reset during schedule tail handling Jan Beulich
2020-12-15 16:29   ` Wei Liu
2020-12-15 16:13 ` [PATCH v2 4/4] livepatch: adjust a stale comment Jan Beulich
2020-12-15 16:34   ` Konrad Rzeszutek Wilk

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=896456a9-16cb-2549-f3a1-e431d5e6479c@xen.org \
    --to=julien@xen.org \
    --cc=andrew.cooper3@citrix.com \
    --cc=george.dunlap@citrix.com \
    --cc=iwj@xenproject.org \
    --cc=jbeulich@suse.com \
    --cc=roger.pau@citrix.com \
    --cc=sstabellini@kernel.org \
    --cc=wl@xen.org \
    --cc=xen-devel@lists.xenproject.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.