Message ID | 20180203012450.18378-2-dbasehore@chromium.org (mailing list archive) |
---|---|
State | Superseded, archived |
Headers | show
Return-Path: <linux-pm-owner@kernel.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 026A260467 for <patchwork-linux-pm@patchwork.kernel.org>; Sat, 3 Feb 2018 01:25:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E885C28E5C for <patchwork-linux-pm@patchwork.kernel.org>; Sat, 3 Feb 2018 01:25:06 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DAF1928FC4; Sat, 3 Feb 2018 01:25:06 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7B00528E5C for <patchwork-linux-pm@patchwork.kernel.org>; Sat, 3 Feb 2018 01:25:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752582AbeBCBZD (ORCPT <rfc822;patchwork-linux-pm@patchwork.kernel.org>); Fri, 2 Feb 2018 20:25:03 -0500 Received: from mail-pl0-f66.google.com ([209.85.160.66]:46508 "EHLO mail-pl0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752023AbeBCBY5 (ORCPT <rfc822;linux-pm@vger.kernel.org>); Fri, 2 Feb 2018 20:24:57 -0500 Received: by mail-pl0-f66.google.com with SMTP id 36so7477684ple.13 for <linux-pm@vger.kernel.org>; Fri, 02 Feb 2018 17:24:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=bXrIQAeaBj8ZTh2/1PI5C5HpC8c5NeqH4Hd9pU7SKRg=; b=etkrBbndA6WD+ocEH3LqSzV89CkhOf4GT0HtIH+oJ9K41M9S0o1A4biDE8PqiJN4cG VyLT9Sso59Scmucc93/4TUvXX1xAVn5fhU8wpqom8y2odzF7rcX06LYI0xJQIIdGrUIF rZ5eZ0aWRgdpB3DClm+yTmd9/DgMD6CVGUAo0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=bXrIQAeaBj8ZTh2/1PI5C5HpC8c5NeqH4Hd9pU7SKRg=; b=blRs0bBlzh7FOwIJNayvBwitMrzNzdj2RZxqiMXkEc2ZslQOZ8U2mnuyXVjP/OXgrl vW8A9cgVyAQk2IA59UNQrpTTXZLPynGjzeOrijabs6507vyOXdNYLQvlCk1o57BPPpvl ZjarVmT1+sRa/G4niMqONzQoX2NOqg7dRaN/kwGTkQjOdGPpbj/HKsi0T8mf92iWKOOc /DVhf2X57k4xIDQoUSoACQSC0j4dOtEuiKhIUeKHa7er1WJwEJYOLcr7E8KKrP599tsZ pJMPN36C1DfZD4RN45z6P/dziHXAiLPnEb2j7ExkT0X+aLf5eVeuGnCwTWGYtttVi2uT nyvA== X-Gm-Message-State: AKwxytfFmEuX/ID/YDcupIqt7rbFXSuB/hYRomlAbM1qHYbtU+Itxb+S esJdFEt4Kv8Cz+cRh1avAyg8TQ== X-Google-Smtp-Source: AH8x227n9hpwfoyX7zHOSCm9wc3C8xPo27bgqczoWGmGSM0myouhp2tQfjdc4gRA5VZaaFZs8m/SDg== X-Received: by 2002:a17:902:9a41:: with SMTP id x1-v6mr29579866plv.256.1517621096765; Fri, 02 Feb 2018 17:24:56 -0800 (PST) Received: from exogeni.mtv.corp.google.com ([2620:0:1000:1600:211e:5908:95bc:4888]) by smtp.gmail.com with ESMTPSA id x124sm5332917pfx.105.2018.02.02.17.24.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 02 Feb 2018 17:24:55 -0800 (PST) From: Derek Basehore <dbasehore@chromium.org> To: linux-kernel@vger.kernel.org Cc: Soby.Mathew@arm.com, sudeep.holla@arm.com, devicetree@vger.kernel.org, robh+dt@kernel.org, mark.rutland@arm.com, linux-pm@vger.kernel.org, rafael.j.wysocki@intel.com, tglx@linutronix.de, briannorris@chromium.org, marc.zyngier@arm.com, Derek Basehore <dbasehore@chromium.org> Subject: [PATCH v4 1/5] cpu_pm: add syscore_suspend error handling Date: Fri, 2 Feb 2018 17:24:46 -0800 Message-Id: <20180203012450.18378-2-dbasehore@chromium.org> X-Mailer: git-send-email 2.16.0.rc1.238.g530d649a79-goog In-Reply-To: <20180203012450.18378-1-dbasehore@chromium.org> References: <20180203012450.18378-1-dbasehore@chromium.org> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: <linux-pm.vger.kernel.org> X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/kernel/cpu_pm.c b/kernel/cpu_pm.c index 67b02e138a47..03bcc0751a51 100644 --- a/kernel/cpu_pm.c +++ b/kernel/cpu_pm.c @@ -186,6 +186,9 @@ static int cpu_pm_suspend(void) return ret; ret = cpu_cluster_pm_enter(); + if (ret) + cpu_pm_exit(); + return ret; }
If cpu_cluster_pm_enter() fails, cpu_pm_exit() should be called. This will put the CPU in the correct state to resume from the failure. Signed-off-by: Derek Basehore <dbasehore@chromium.org> --- kernel/cpu_pm.c | 3 +++ 1 file changed, 3 insertions(+)