Received: by 2002:a25:ca44:0:0:0:0:0 with SMTP id a65csp2585152ybg; Fri, 31 Jul 2020 04:34:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzwOe7GWPDfJJ1fiEFpk2+fJA0RozKbc4rhFdx9aFvvchWdSHS6D3WDaTCqZhj5Ly6xKqeu X-Received: by 2002:a17:906:af6a:: with SMTP id os10mr136038ejb.355.1596195252067; Fri, 31 Jul 2020 04:34:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596195252; cv=none; d=google.com; s=arc-20160816; b=XgP9ged7un4SFAkrCDjpcAmTL/D3jDG9WKyTWd8PeEuZfPVbfVIOLVq+i4EPGpXdBe Dw7TGOkTkVdGs/cg98tb6LA4pHKbU76gn8w6aQq4kBDZqj8Bw5JuOauabmYP+1E1CVZF gJm+EYhzJZghWhew1XaDP1yDXVvB8H34HM7FsVHDsHqUHOtIqh6ycyUSJb3U3sB4PQi2 IbejuN85+wxu86fgnuDuakRem05DfW01U1g3Jf1Rc7Fc6b4fsaxzaQaOGkNeBZhA8Hbp kpO6XG2FwrSD8CtCPaleYH77i0IsFzbCEIVuZf6oh8/WmR6ZMogQCyRmjjUFV41kQUXs M3qg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=mpZwL9ptFKxq7FoZCH1xjumTWQNcssejfeTwP6RoxpQ=; b=icV3MIxuvY9sapggRq2cXB6ISr2AsM6S96PMIH5r9W/7poz9PQDqRmawgvprEYzyA1 On21JkHzxjbtNT100UA5Gj838Q33ACbQ7QyzBpGCl2i5wXQrbLPTlhLcEAJZ7my1Ovps nEO+FdmBQZXVhRn5z/jSMwyUX4fGf6geW8zSqsrVSXYODW9szq3sIQMzo/+yfVISDZWb vBZ9vZquMtUWkb7GXamETcKiA0N7gHf3kIezrYAWXq8kfWxEd7tw4TXlPBMz9DnNIHGu LrY04SyY4xCDoXlurmkVO6NXSpQ3WrrJ046zFgfPyamI8ABSkLOaEUGGDrV1uS5Au7U+ KXCA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g12si2320413ejr.622.2020.07.31.04.33.48; Fri, 31 Jul 2020 04:34:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732704AbgGaLdi (ORCPT + 99 others); Fri, 31 Jul 2020 07:33:38 -0400 Received: from mail-oi1-f195.google.com ([209.85.167.195]:40075 "EHLO mail-oi1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732104AbgGaLdi (ORCPT ); Fri, 31 Jul 2020 07:33:38 -0400 Received: by mail-oi1-f195.google.com with SMTP id u24so16553690oiv.7; Fri, 31 Jul 2020 04:33:37 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=mpZwL9ptFKxq7FoZCH1xjumTWQNcssejfeTwP6RoxpQ=; b=diuHMLwFGE03iB6FycWL3gzVKV7vJzuDP40K9hGRPOQcLzQIi9LpAbE+bb+iu1Zva7 b7hj6RtcnDvzlg7h3eYbSZvJLmYlNeNiRCKL900jpKHwv5KXYbY7L3g/VaYc1GjEyoJz EE8UibbNHAQ2xvP8l3MH4L5l0FT4XlCfQzCJza6pD2tBjS5oTSksRX8gkBKX5BTHbyAj SNrwrRNcYA3QhnfE9ylEFohlC84WnJz2erwTT4CWf6vKCMDutiNwj6fk+z3+F0SBtbNO EugJdjKvoeNHJYWBqakqrimVl0NheHFYPhWy6JR2X2uYm3YS8xkhOyZaGfRIrMZeD5Ah eHbA== X-Gm-Message-State: AOAM530dUNDrNfQUhFqddHrZ4wxeJDT4smiaX9qYbSJjy0kPyRTht2Sh oStEZMDE27hETN8WPbTTQSjTqHdUHemGtOqXmik= X-Received: by 2002:aca:a88e:: with SMTP id r136mr2704600oie.110.1596195217368; Fri, 31 Jul 2020 04:33:37 -0700 (PDT) MIME-Version: 1.0 References: <1596166744-2954-1-git-send-email-neal.liu@mediatek.com> <1596166744-2954-2-git-send-email-neal.liu@mediatek.com> In-Reply-To: <1596166744-2954-2-git-send-email-neal.liu@mediatek.com> From: "Rafael J. Wysocki" Date: Fri, 31 Jul 2020 13:33:24 +0200 Message-ID: Subject: Re: [PATCH] acpi: fix 'return' with no value build warning To: Neal Liu Cc: "Rafael J. Wysocki" , Len Brown , Daniel Lezcano , Thierry Reding , Jonathan Hunter , Jacob Pan , Matthias Brugger , Sami Tolvanen , ACPI Devel Maling List , Linux PM , linux-tegra , Linux ARM , "moderated list:ARM/Mediatek SoC..." , lkml , wsd_upstream Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 31, 2020 at 5:39 AM Neal Liu 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 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(); > } > --