linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: "Gustavo A. R. Silva" <gustavo@embeddedor.com>
Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
	Kees Cook <keescook@chromium.org>
Subject: Re: [PATCH] PCI: Mark expected switch fall-through
Date: Fri, 2 Aug 2019 08:48:01 -0500	[thread overview]
Message-ID: <20190802134801.GK151852@google.com> (raw)
In-Reply-To: <20190802012248.GA22622@embeddedor>

On Thu, Aug 01, 2019 at 08:22:48PM -0500, Gustavo A. R. Silva wrote:
> Mark switch cases where we are expecting to fall through.
> 
> This patch fixes the following warning (Building: allmodconfig i386):
> 
> drivers/pci/hotplug/ibmphp_res.c: In function ‘update_bridge_ranges’:
> drivers/pci/hotplug/ibmphp_res.c:1943:16: warning: this statement may fall through [-Wimplicit-fallthrough=]
>        function = 0x8;
>        ~~~~~~~~~^~~~~
> drivers/pci/hotplug/ibmphp_res.c:1944:6: note: here
>       case PCI_HEADER_TYPE_MULTIBRIDGE:
>       ^~~~
> 
> Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>

Applied with Kees' reviewed-by to pci/misc for v5.4, thanks, Gustavo!

> ---
>  drivers/pci/hotplug/ibmphp_res.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/pci/hotplug/ibmphp_res.c b/drivers/pci/hotplug/ibmphp_res.c
> index 5e8caf7a4452..1e1ba66cfd1e 100644
> --- a/drivers/pci/hotplug/ibmphp_res.c
> +++ b/drivers/pci/hotplug/ibmphp_res.c
> @@ -1941,6 +1941,7 @@ static int __init update_bridge_ranges(struct bus_node **bus)
>  						break;
>  					case PCI_HEADER_TYPE_BRIDGE:
>  						function = 0x8;
> +						/* Fall through */
>  					case PCI_HEADER_TYPE_MULTIBRIDGE:
>  						/* We assume here that only 1 bus behind the bridge
>  						   TO DO: add functionality for several:
> -- 
> 2.22.0
> 

      parent reply	other threads:[~2019-08-02 13:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-02  1:22 [PATCH] PCI: Mark expected switch fall-through Gustavo A. R. Silva
2019-08-02  5:10 ` Kees Cook
2019-08-02 13:48 ` Bjorn Helgaas [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=20190802134801.GK151852@google.com \
    --to=helgaas@kernel.org \
    --cc=gustavo@embeddedor.com \
    --cc=keescook@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.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).