All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Beulich <jbeulich@suse.com>
To: victorm.lira@amd.com
Cc: "Nicola Vetrini" <nicola.vetrini@bugseng.com>,
	"Andrew Cooper" <andrew.cooper3@citrix.com>,
	"Anthony PERARD" <anthony.perard@vates.tech>,
	"Michal Orzel" <michal.orzel@amd.com>,
	"Julien Grall" <julien@xen.org>,
	"Roger Pau Monné" <roger.pau@citrix.com>,
	"Stefano Stabellini" <sstabellini@kernel.org>,
	"Federico Serafini" <federico.serafini@bugseng.com>,
	"Bertrand Marquis" <bertrand.marquis@arm.com>,
	xen-devel@lists.xenproject.org
Subject: Re: [PATCH 3/3] xen/x86: add missing noreturn attributes
Date: Thu, 5 Jun 2025 09:24:01 +0200	[thread overview]
Message-ID: <0575e9d0-ff37-4f66-8ee3-e8c3675f9cc4@suse.com> (raw)
In-Reply-To: <20250604235034.1595881-3-victorm.lira@amd.com>

On 05.06.2025 01:49, victorm.lira@amd.com wrote:
> From: Nicola Vetrini <nicola.vetrini@bugseng.com>
> 
> The marked functions never return to their caller, but
> lack the `noreturn' attribute, therefore causing a violation
> of MISRA C Rule 2.1: "A project shall not contain unreachable code".
> 
> No functional change.
> 
> Signed-off-by: Nicola Vetrini <nicola.vetrini@bugseng.com>
> Signed-off-by: Victor Lira <victorm.lira@amd.com>

I expect the comment on patch 1 applies to some or all of the cases here,
too. For example, I expect that even if efi_arch_halt() wasn't inlined into
its sole caller, the compiler would also be able to infer noreturn from the
infinite loop there.

Jan


  reply	other threads:[~2025-06-05  7:24 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-04 23:49 [PATCH 1/3] xen/keyhandler: add missing noreturn attribute victorm.lira
2025-06-04 23:49 ` [PATCH 2/3] xen/arm: add missing noreturn attributes victorm.lira
2025-06-04 23:49   ` [PATCH 3/3] xen/x86: " victorm.lira
2025-06-05  7:24     ` Jan Beulich [this message]
2025-06-05  7:17 ` [PATCH 1/3] xen/keyhandler: add missing noreturn attribute Jan Beulich
2025-06-05 12:22   ` Nicola Vetrini
2025-06-05 12:26     ` Nicola Vetrini
2025-06-05 13:27       ` Jan Beulich
2025-06-06  0:09         ` Stefano Stabellini
2025-06-06  6:47           ` Jan Beulich

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=0575e9d0-ff37-4f66-8ee3-e8c3675f9cc4@suse.com \
    --to=jbeulich@suse.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=anthony.perard@vates.tech \
    --cc=bertrand.marquis@arm.com \
    --cc=federico.serafini@bugseng.com \
    --cc=julien@xen.org \
    --cc=michal.orzel@amd.com \
    --cc=nicola.vetrini@bugseng.com \
    --cc=roger.pau@citrix.com \
    --cc=sstabellini@kernel.org \
    --cc=victorm.lira@amd.com \
    --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.