public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Hanjun Guo <guohanjun@huawei.com>
To: <kernel.openeuler@huawei.com>
Cc: Toshi Kani <toshi.kani@hp.com>, Jiang Liu <jiang.liu@huawei.com>,
	<linux-ia64@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: [PATCH 3/4] ACPI: Untangle a return statement for better readability
Date: Wed, 10 Apr 2013 18:23:00 +0800	[thread overview]
Message-ID: <1365589381-5624-4-git-send-email-guohanjun@huawei.com> (raw)
In-Reply-To: <1365589381-5624-1-git-send-email-guohanjun@huawei.com>

From: Thomas Renninger <trenn@suse.de>

mainline inclusion
from mainline-3.6
upstream commit f3946fb6e50b750d34f445188fa6746d14596afa
category: cleanup

This patch is cleanup patch, but the next bugfix patch is
upon it.

--------------------------------------------------------

No functional change.

Signed-off-by: Thomas Renninger <trenn@suse.de>
Signed-off-by: Len Brown <len.brown@intel.com>
Integrated-by: Hanjun Guo <guohanjun@huawei.com>
---
 drivers/acpi/numa.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/acpi/numa.c b/drivers/acpi/numa.c
index e56f3be..2a63993 100644
--- a/drivers/acpi/numa.c
+++ b/drivers/acpi/numa.c
@@ -304,8 +304,10 @@ int __init acpi_numa_init(void)
 
 	acpi_numa_arch_fixup();
 
-	if (cnt <= 0)
-		return cnt ?: -ENOENT;
+	if (cnt < 0)
+		return cnt;
+	else if (cnt == 0)
+		return -ENOENT;
 	return 0;
 }
 
-- 
1.6.0.2



  parent reply	other threads:[~2013-04-10 10:25 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-10 10:22 [PATCH 0/4] ACPI and PM patches for Euler stable from mainline v3.6 Hanjun Guo
2013-04-10 10:22 ` [PATCH 1/4] cpuidle: fix error handling in __cpuidle_register_device Hanjun Guo
2013-04-10 10:22 ` [PATCH 2/4] cpufreq: Fix sysfs deadlock with concurrent hotplug/frequency switch Hanjun Guo
2013-04-10 10:23 ` Hanjun Guo [this message]
2013-04-10 10:23 ` [PATCH 4/4] ACPI: Only count valid srat memory structures Hanjun Guo
2013-04-10 10:33 ` [PATCH 0/4] ACPI and PM patches for Euler stable from mainline v3.6 Hanjun Guo

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=1365589381-5624-4-git-send-email-guohanjun@huawei.com \
    --to=guohanjun@huawei.com \
    --cc=jiang.liu@huawei.com \
    --cc=kernel.openeuler@huawei.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=toshi.kani@hp.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