From patchwork Thu Jan 8 11:34:18 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alessandro Zummo X-Patchwork-Id: 17330 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from wf-out-1516.google.com (wf-out-1516.google.com [209.85.200.164]) by ozlabs.org (Postfix) with ESMTP id D3642DE067 for ; Thu, 8 Jan 2009 22:34:27 +1100 (EST) Received: by wf-out-1516.google.com with SMTP id r34so2319134wfc.41 for ; Thu, 08 Jan 2009 03:34:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=beta; h=domainkey-signature:received:received:x-sender:x-apparently-to :received:received:received-spf:authentication-results:received :received:from:subject:to:cc:date:message-id:user-agent:mime-version :content-type:reply-to:sender:precedence:x-google-loop:mailing-list :list-id:list-post:list-help:list-unsubscribe:x-beenthere-env :x-beenthere; bh=Ol3IyAyXCDD4KBVKHdwtrh1JckPICEPEz2zsbimSjfM=; b=RK0jxAQiHJtYYytjQkMQ+NvU7kzKsiJvOBN3ehj7qUup4fU4A9HV0KtJvsxFQNcrGx Tq4bpMU16WXWmdfDHnnS/XqpAhNJeOfQF4CoXK/12JsKFtGbnEsAE+jjMMSpDMWJU1Hs LeDiOr35PV+2sVsits6n5s/da4uEyJdvq/rgs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlegroups.com; s=beta; h=x-sender:x-apparently-to:received-spf:authentication-results:from :subject:to:cc:date:message-id:user-agent:mime-version:content-type :reply-to:sender:precedence:x-google-loop:mailing-list:list-id :list-post:list-help:list-unsubscribe:x-beenthere-env:x-beenthere; b=yKAtPNXhobIlg08nL0D8G/QjAFl2//EI5SS5Uq7cm6EcS4V1TU+y1aDqfx0NoNmQSi yWLW6dSFbFyTWttJ243bzqQEuQ2lpVje7ys14SjYvH14y5EWnKWN2etfzSghXWHFLJtL +QMrSojV/56y2/7qAw0b9iXS6xL4OjQEaZYqU= Received: by 10.140.187.10 with SMTP id k10mr1429369rvf.19.1231414462229; Thu, 08 Jan 2009 03:34:22 -0800 (PST) Received: by 10.230.111.65 with SMTP id r1gr1774vbp.0; Thu, 08 Jan 2009 03:34:22 -0800 (PST) X-Sender: a.zummo@towertech.it X-Apparently-To: rtc-linux@googlegroups.com Received: by 10.100.119.18 with SMTP id r18mr7575831anc.24.1231414461400; Thu, 08 Jan 2009 03:34:21 -0800 (PST) Received: from mx0.towertech.it (mx0.towertech.it [213.215.222.73]) by mx.google.com with SMTP id 7si13949864yxg.11.2009.01.08.03.34.20; Thu, 08 Jan 2009 03:34:20 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of a.zummo@towertech.it designates 213.215.222.73 as permitted sender) client-ip=213.215.222.73; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of a.zummo@towertech.it designates 213.215.222.73 as permitted sender) smtp.mail=a.zummo@towertech.it Received: (qmail 30234 invoked from network); 8 Jan 2009 12:34:19 +0100 Received: from unknown (HELO i1501.lan.towertech.it) (81.208.60.204) by mx0.towertech.it with SMTP; 8 Jan 2009 12:34:19 +0100 From: Alessandro Zummo Subject: [rtc-linux] [PATCH] rtc: rtc-twl4030 don't mask alarm interrupts on shutdown To: akpm@linux-foundation.org Cc: Matti Halme , Alessandro Zummo , David Brownell , Tony Lindgren , Samuel Ortiz , rtc-linux@googlegroups.com Date: Thu, 08 Jan 2009 12:34:18 +0100 Message-ID: <20090108113418.4819.56434.stgit@i1501.lan.towertech.it> User-Agent: StGIT/0.14.2 Mime-Version: 1.0 Reply-To: rtc-linux@googlegroups.com Sender: rtc-linux@googlegroups.com Precedence: bulk X-Google-Loop: groups Mailing-List: list rtc-linux@googlegroups.com; contact rtc-linux+owner@googlegroups.com List-Id: List-Post: List-Help: List-Unsubscribe: , X-BeenThere-Env: rtc-linux@googlegroups.com X-BeenThere: rtc-linux@googlegroups.com From: Matti Halme A triggering RTC alarm should be able to power on a device that has been powered off. This patch enables that on twl4030 by not masking the alarm interrupt at shutdown. Signed-off-by: Matti Halme Signed-off-by: Alessandro Zummo Cc: David Brownell Cc: Tony Lindgren Cc: Samuel Ortiz Cc: rtc-linux@googlegroups.com Acked-by: David Brownell --- drivers/rtc/rtc-twl4030.c | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to "rtc-linux". Membership options at http://groups.google.com/group/rtc-linux . Please read http://groups.google.com/group/rtc-linux/web/checklist before submitting a driver. -~----------~----~----~----~------~----~------~--~--- diff --git a/drivers/rtc/rtc-twl4030.c b/drivers/rtc/rtc-twl4030.c index 25dc3e1..ad35f76 100644 --- a/drivers/rtc/rtc-twl4030.c +++ b/drivers/rtc/rtc-twl4030.c @@ -482,8 +482,9 @@ static int __devexit twl4030_rtc_remove(struct platform_device *pdev) static void twl4030_rtc_shutdown(struct platform_device *pdev) { - mask_rtc_irq_bit(BIT_RTC_INTERRUPTS_REG_IT_TIMER_M | - BIT_RTC_INTERRUPTS_REG_IT_ALARM_M); + /* mask timer interrupts, but leave alarm interrupts on to enable + power-on when alarm is triggered */ + mask_rtc_irq_bit(BIT_RTC_INTERRUPTS_REG_IT_TIMER_M); } #ifdef CONFIG_PM