Received: by 10.223.176.46 with SMTP id f43csp364448wra; Thu, 25 Jan 2018 23:41:11 -0800 (PST) X-Google-Smtp-Source: AH8x225BX592bWCKzSFWEiUUSST3x2v0VDCbV8+ZcfKWDdYojRaWfKk2ZvxXx51ruXmcIgAfpH2C X-Received: by 10.98.7.73 with SMTP id b70mr18112585pfd.39.1516952471566; Thu, 25 Jan 2018 23:41:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516952471; cv=none; d=google.com; s=arc-20160816; b=L2zToEKSnmEpqJMsSQkKyLqCb34e3McW+UP0o21B1IBsK3TnY6Zt/bbLvXauT3DcGD sXNNRlfw0q4EV7wy7VpLZFRk5k6zOhAortDpeG1oewH22kli5JcHp+oJRC9lGR6wfARW NJFr+JQHWbQcsOZK16AUtu/i635qHZUGkiHmozXnCuC9DjZzimqx/aSArNJbLwzGoIY1 itPUBwSVbxcsFePAYe/tdJk+twmHcwuU2Edmw1kU0/rpB3+D+SCwKa6DLOBYf25eoVaI KTKgHJb2EqalNp8z3Mw6xNDb1MX+F91pqio55gIa546WIK76p6kkt+JgwV+5JkR04oV8 ivAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=bXrIQAeaBj8ZTh2/1PI5C5HpC8c5NeqH4Hd9pU7SKRg=; b=Dey4nAmmMVGh7DqmRJAzNTD+5r5qNg4ZrVHzzqbcWWS2d5UYJWIN5KmFHADXyoaDjD FFdZia05ndhbHIj5g9dLd+mvleCPoHuK8YFi1Qv+500b1zGn8GXsSVTxkWGR4C48r2ia +QplvtOPXVMzAllE5sbmT1GoYqaJVDN8YHh9+IAaKhsnsxwjmO4oZHw4tBRH0Wd3PmrS Xcn1KGozJql0uGWcD4kl/PWD2nD3DMdGqT/AcYABGfr7UpH0PbFyhcfctL/fjkLRqKLR 173c0mD193VzSv9hQrg4J2uAwZZpHFODKeIDJ8pUtiy7Ja69JeNcG2MPqKBhOp157kKS syxA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=izBDVqer; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e11si2655313pgr.135.2018.01.25.23.40.57; Thu, 25 Jan 2018 23:41:11 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=izBDVqer; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752153AbeAZHkM (ORCPT + 99 others); Fri, 26 Jan 2018 02:40:12 -0500 Received: from mail-pf0-f193.google.com ([209.85.192.193]:39021 "EHLO mail-pf0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751897AbeAZHim (ORCPT ); Fri, 26 Jan 2018 02:38:42 -0500 Received: by mail-pf0-f193.google.com with SMTP id e11so7751542pff.6 for ; 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=YxatD9ygtfyVn75i7KL54zEOBhmkGo4EapLCGEqieAr5IE+kgXqE/QpinDmIB3Av9w /QpBjfibTu26SyAk2n3NYoAovAsaRcyCVvB1EdGiElXLbQhUN+9REUTIYXub6VXq7VUi FHID8isAhoDIbKjh4AU0eaAaGwwd4qV59/lew+WAfyo0KH7bmVjc6I+5GI2eiHWJtxa/ QBWXoWmGHDAVyrF+B+AF7fP90EchQw5+xdzNdnW1+vWmVckwZA/3+1+zODpqw0BEtdpZ DS9FY1qPyM7RgjV76z1LPJXxBIjNQ5QeDQh5ospmNQRQTpafFat/zLcOMh0UbcXFanS7 7eRg== X-Gm-Message-State: AKwxyteALZVIQyRbdozKMYQ+sAo6ueOw4nX2xYaxN1IwRIy3rhDfiKLE Bqslrstwj6cBl3gHbUtg8C2HUBzaA60= 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 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 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-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 --- kernel/cpu_pm.c | 3 +++ 1 file changed, 3 insertions(+) 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; } -- 2.16.0.rc1.238.g530d649a79-goog