From: "Rafael J. Wysocki" <rafael@kernel.org>
To: Neal Liu <neal.liu@mediatek.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
Len Brown <lenb@kernel.org>,
Daniel Lezcano <daniel.lezcano@linaro.org>,
Thierry Reding <thierry.reding@gmail.com>,
Jonathan Hunter <jonathanh@nvidia.com>,
Jacob Pan <jacob.jun.pan@linux.intel.com>,
Matthias Brugger <matthias.bgg@gmail.com>,
Sami Tolvanen <samitolvanen@google.com>,
ACPI Devel Maling List <linux-acpi@vger.kernel.org>,
Linux PM <linux-pm@vger.kernel.org>,
linux-tegra <linux-tegra@vger.kernel.org>,
Linux ARM <linux-arm-kernel@lists.infradead.org>,
"moderated list:ARM/Mediatek SoC..."
<linux-mediatek@lists.infradead.org>,
lkml <linux-kernel@vger.kernel.org>,
wsd_upstream <wsd_upstream@mediatek.com>
Subject: Re: [PATCH] acpi: fix 'return' with no value build warning
Date: Fri, 31 Jul 2020 13:33:24 +0200 [thread overview]
Message-ID: <CAJZ5v0gk9a-PVr4+zerNWdBORyC563K8XgUdgxENAQ+Y5-85tg@mail.gmail.com> (raw)
In-Reply-To: <1596166744-2954-2-git-send-email-neal.liu@mediatek.com>
On Fri, Jul 31, 2020 at 5:39 AM Neal Liu <neal.liu@mediatek.com> wrote:
>
> Fixing CFI issue which introduced by commit efe9711214e6 is
> incomplete.
> Add return value to fix return-type build warning.
>
> Signed-off-by: Neal Liu <neal.liu@mediatek.com>
Applied with edited subject and changelog, but ->
> ---
> drivers/acpi/processor_idle.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/acpi/processor_idle.c b/drivers/acpi/processor_idle.c
> index 6ffb6c9..6870020 100644
> --- a/drivers/acpi/processor_idle.c
> +++ b/drivers/acpi/processor_idle.c
> @@ -664,11 +664,11 @@ static int acpi_idle_enter_s2idle(struct cpuidle_device *dev,
> struct acpi_processor *pr = __this_cpu_read(processors);
>
> if (unlikely(!pr))
> - return;
> + return -EFAULT;
-> there is no point returning an error code here, so I've made it
just return 0.
>
> if (pr->flags.bm_check) {
> acpi_idle_enter_bm(pr, cx, false);
> - return;
> + return 0;
> } else {
> ACPI_FLUSH_CPU_CACHE();
> }
> --
next prev parent reply other threads:[~2020-07-31 11:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-31 3:39 acpi: fix 'return' with no value build warning Neal Liu
2020-07-31 3:39 ` [PATCH] " Neal Liu
2020-07-31 11:33 ` Rafael J. Wysocki [this message]
2020-08-03 2:40 ` Neal Liu
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=CAJZ5v0gk9a-PVr4+zerNWdBORyC563K8XgUdgxENAQ+Y5-85tg@mail.gmail.com \
--to=rafael@kernel.org \
--cc=daniel.lezcano@linaro.org \
--cc=jacob.jun.pan@linux.intel.com \
--cc=jonathanh@nvidia.com \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=matthias.bgg@gmail.com \
--cc=neal.liu@mediatek.com \
--cc=rjw@rjwysocki.net \
--cc=samitolvanen@google.com \
--cc=thierry.reding@gmail.com \
--cc=wsd_upstream@mediatek.com \
/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).