Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751466AbdFHLaf (ORCPT ); Thu, 8 Jun 2017 07:30:35 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:47692 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750914AbdFHLae (ORCPT ); Thu, 8 Jun 2017 07:30:34 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Thu, 08 Jun 2017 17:00:33 +0530 From: kgunda@codeaurora.org To: Stephen Boyd Cc: Abhijeet Dharmapurikar , Christophe JAILLET , David Collins , Subbaraman Narayanamurthy , linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, adharmap@quicinc.com, aghayal@qti.qualcomm.com, Nicholas Troast , linux-arm-msm-owner@vger.kernel.org Subject: Re: [PATCH V1 11/15] spmi: spmi-pmic-arb: enable the SPMI interrupt as a wakeup source In-Reply-To: <20170531171358.GC20170@codeaurora.org> References: <1496147943-25822-1-git-send-email-kgunda@codeaurora.org> <1496147943-25822-12-git-send-email-kgunda@codeaurora.org> <20170531171358.GC20170@codeaurora.org> Message-ID: User-Agent: Roundcube Webmail/1.2.5 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1002 Lines: 27 On 2017-05-31 22:43, Stephen Boyd wrote: > On 05/30, Kiran Gunda wrote: >> Currently the SPMI interrupt will not wake the device. Enable this >> interrupt as a wakeup source. >> >> Signed-off-by: Nicholas Troast >> Signed-off-by: Kiran Gunda >> --- >> drivers/spmi/spmi-pmic-arb.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/drivers/spmi/spmi-pmic-arb.c >> b/drivers/spmi/spmi-pmic-arb.c >> index 0deac33..2afe359 100644 >> --- a/drivers/spmi/spmi-pmic-arb.c >> +++ b/drivers/spmi/spmi-pmic-arb.c >> @@ -1140,6 +1140,7 @@ static int spmi_pmic_arb_probe(struct >> platform_device *pdev) >> } >> >> irq_set_chained_handler_and_data(pa->irq, pmic_arb_chained_irq, pa); >> + enable_irq_wake(pa->irq); > > Why don't we do this through an irq_set_wake callback in the > irqchip? That way, we don't mark this irq as wakeup if any child > irqs aren't marked as wakeup. Yes. This looks cleaner. Will change it in the subsequent patch.