From: ibm-acpi@hmh.eng.br
To: Kees Cook <keescook@chromium.org>,
"Gustavo A. R. Silva" <gustavo@embeddedor.com>
Cc: Darren Hart <dvhart@infradead.org>,
Andy Shevchenko <andy@infradead.org>,
Thinkpad-acpi devel ML <ibm-acpi-devel@lists.sourceforge.net>,
Platform Driver <platform-driver-x86@vger.kernel.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] platform/x86: thinkpad_acpi: Mark expected switch fall-throughs
Date: Wed, 24 Apr 2019 20:55:05 -0400 [thread overview]
Message-ID: <13ba6003-ff33-4e5b-b88e-ef93bc68dc48@www.fastmail.com> (raw)
In-Reply-To: <CAGXu5jKRO45m1TRDPA09sv0j+cZCC8e1w+oQty4YfOttKP3FYA@mail.gmail.com>
On Wed, Apr 24, 2019, at 16:05, Kees Cook wrote:
> On Wed, Apr 24, 2019 at 11:15 AM Gustavo A. R. Silva
> <gustavo@embeddedor.com> wrote:
> >
> > In preparation to enabling -Wimplicit-fallthrough, mark switch
> > cases where we are expecting to fall through.
> >
> > This patch fixes the following warnings:
> >
> > drivers/platform/x86/thinkpad_acpi.c: In function ‘thermal_get_sensor’:
> > drivers/platform/x86/thinkpad_acpi.c:6316:6: warning: this statement may fall through [-Wimplicit-fallthrough=]
> > if (idx >= 8 && idx <= 15) {
> > ^
> > drivers/platform/x86/thinkpad_acpi.c:6322:2: note: here
> > case TPACPI_THERMAL_TPEC_8:
> > ^~~~
> > drivers/platform/x86/thinkpad_acpi.c: In function ‘hotkey_notify’:
> > drivers/platform/x86/thinkpad_acpi.c:4208:7: warning: this statement may fall through [-Wimplicit-fallthrough=]
> > if (tp_features.hotkey_wlsw &&
> > ^
> > drivers/platform/x86/thinkpad_acpi.c:4216:3: note: here
> > default:
> > ^~~~~~~
> >
> > Warning level 3 was used: -Wimplicit-fallthrough=3
> >
> > Notice that, in this particular case, the code comments are modified
> > in accordance with what GCC is expecting to find.
> >
> > This patch is part of the ongoing efforts to enable
> > -Wimplicit-fallthrough.
> >
> > Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
>
> Reviewed-by: Kees Cook <keescook@chromium.org>
Acked-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
next prev parent reply other threads:[~2019-04-25 0:55 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-24 18:15 [PATCH] platform/x86: thinkpad_acpi: Mark expected switch fall-throughs Gustavo A. R. Silva
2019-04-24 19:05 ` Kees Cook
2019-04-25 0:55 ` ibm-acpi [this message]
2019-05-01 20:43 ` Gustavo A. R. Silva
2019-05-06 12:22 ` Andy Shevchenko
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=13ba6003-ff33-4e5b-b88e-ef93bc68dc48@www.fastmail.com \
--to=ibm-acpi@hmh.eng.br \
--cc=andy@infradead.org \
--cc=dvhart@infradead.org \
--cc=gustavo@embeddedor.com \
--cc=ibm-acpi-devel@lists.sourceforge.net \
--cc=keescook@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=platform-driver-x86@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).