Message ID | 20180126073835.16575-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 6ADED602C8 for <patchwork-linux-pm@patchwork.kernel.org>; Fri, 26 Jan 2018 07:38:47 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 59FF128D4B for <patchwork-linux-pm@patchwork.kernel.org>; Fri, 26 Jan 2018 07:38:47 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4DA3729069; Fri, 26 Jan 2018 07:38:47 +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 F276E28D4B for <patchwork-linux-pm@patchwork.kernel.org>; Fri, 26 Jan 2018 07:38:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752046AbeAZHio (ORCPT <rfc822;patchwork-linux-pm@patchwork.kernel.org>); Fri, 26 Jan 2018 02:38:44 -0500 Received: from mail-pf0-f195.google.com ([209.85.192.195]:33051 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751891AbeAZHil (ORCPT <rfc822;linux-pm@vger.kernel.org>); Fri, 26 Jan 2018 02:38:41 -0500 Received: by mail-pf0-f195.google.com with SMTP id t5so7754429pfi.0 for <linux-pm@vger.kernel.org>; Thu, 25 Jan 2018 23:38:41 -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=izBDVqerXsG0FW/CpWiWm4BeUcN7DNntEnA6FQdAmqdSL1/TwdOgUYnsKZwM62naop yYFw9Z3fVaumY1C3SBSMmkjNIcwdkEfZLYc8v6nMV5an2mHPegLijRw0TC4IvV0869vH ZLVsfSGCPBGdiZEVe8x48C8qp4q+ua97DLdwQ= 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=tY51V7O+EHrxgbc596VBI7Pbyq6AQRUE5vo4tAoAx07KiqFa7jI9F+hUPAWzcs5tmI l4jGLjOOKr265KUaQp+RSlirPG3OsOyRDeOBHvri+XONr27+cXFWR5ha0hj8jqIfEB+4 GCq2ZYIl35uRSK94JNkDebZ3wQfwzJk/SpFHIGw/VxCfrCDupxZ3BCLFcCtVf7iyvucK 9xVUBcUdNq14D0Kk8UWlxLhmtwpU9gZx1ZlcUtbjqo3Z6AezFBvT2uz37xL+HKItGE9M E0kwNWj2XWKV5PekHTvgVSONJoUQaGB8Ud7xOZoBL+zKzFCwLpjdFlkj8nP5ibE9gyJY aHMA== X-Gm-Message-State: AKwxytdKjTwOhNwwWMmgh4xheo+blitxfPtX/L8IOd+ormqP0ePUAmh7 MLSGsUE3xBS55K9dRpPaAD+4UQ== X-Google-Smtp-Source: AH8x2242FqBeGYetnIn8aysQEjyOGDoau9Af41ELjBMWPfan9pvJLnc2OM/sImcJKuuCEfbAWQnnJg== X-Received: by 10.98.62.69 with SMTP id l66mr18595617pfa.20.1516952321301; Thu, 25 Jan 2018 23:38:41 -0800 (PST) Received: from exogeni.mtv.corp.google.com ([2620:0:1000:1600:211e:5908:95bc:4888]) by smtp.gmail.com with ESMTPSA id t22sm17856168pfi.118.2018.01.25.23.38.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 25 Jan 2018 23:38:40 -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 v2 1/5] cpu_pm: add syscore_suspend error handling Date: Thu, 25 Jan 2018 23:38:31 -0800 Message-Id: <20180126073835.16575-2-dbasehore@chromium.org> X-Mailer: git-send-email 2.16.0.rc1.238.g530d649a79-goog In-Reply-To: <20180126073835.16575-1-dbasehore@chromium.org> References: <20180126073835.16575-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(+)