Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp2251448ybi; Thu, 20 Jun 2019 11:38:07 -0700 (PDT) X-Google-Smtp-Source: APXvYqwyicQUMGvEb7iaC6jbDBIENZvKVDUzE671yLXQ9MxGHUVa1Pz3qha2ZGv8BVQQYW4u0gi9 X-Received: by 2002:a63:2a83:: with SMTP id q125mr13892268pgq.102.1561055886991; Thu, 20 Jun 2019 11:38:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561055886; cv=none; d=google.com; s=arc-20160816; b=cnOEw9CeBQnPEwSY+0Sz9ym6O7kRcU5hpZUzWJMXxPteDDBTU2uiDAkgx0pGaCnBI6 aauZkreMKouKD87MbC7JsFMd5zu3CHOCXq6aWy2f1jE1qSeukXwlo5FN+0sLJGhdxl1l ApyEsQxp8W7OqLyn8Fe2R3cS8CrGwsvmUK0Rc8mS+bPTH2e3bdBGivpbAzA+4B6Ekye6 vRlFNOTrFM82czJjbRu/7Z4zxmjMEc41qREiwwBrF+sBy/EAd2dzcIsdlsut1jcbNiGx 5sMRPkdRy+mqLkL790P0enjXd20yPZQRIiSGfgh9UaQEkh+SYGRoqnhid0ksGlwILFyp 38Tw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=o/QJTWxuIiTVYZtc3C3pmn5awkfyR7Sd/ITwOC72T54=; b=DnGlNa9vW5K2HC+paIjQwkGvuCs80FW6fbpqtu/vDMwVFNJuKGSHRfIRN+dhdCntaT 0+s0OiPKgETgWTzymNnEdJ1624GGR3MNqd+CXNy1kS+NMQds1Rp1TQva2zriOSjPasC0 qMw7YhbR0snOKQHJVUXLMyzLxP0QOl+iKmKYkc7K7xAnuxtxT2z9n0n5UDcUp8eSp2Xc Yjxe5uyORy1qM350SrQDIKNDCugUIfyi0pE/dUvd6i2/GwhUpoDfLmQaXfQTJAis6E8y jFWkDbvz4cbx/dFVCE1R6BjucIy9726cRCoX2K3mEHL5dNfMtZC/Z4MECeYY7h6iCNCT RxGw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r185si257393pgr.10.2019.06.20.11.37.51; Thu, 20 Jun 2019 11:38:06 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726289AbfFTShp (ORCPT + 99 others); Thu, 20 Jun 2019 14:37:45 -0400 Received: from relay1-d.mail.gandi.net ([217.70.183.193]:42923 "EHLO relay1-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726130AbfFTShp (ORCPT ); Thu, 20 Jun 2019 14:37:45 -0400 X-Originating-IP: 90.65.161.137 Received: from localhost (lfbn-1-1545-137.w90-65.abo.wanadoo.fr [90.65.161.137]) (Authenticated sender: alexandre.belloni@bootlin.com) by relay1-d.mail.gandi.net (Postfix) with ESMTPSA id 54605240009; Thu, 20 Jun 2019 18:37:42 +0000 (UTC) Date: Thu, 20 Jun 2019 20:37:42 +0200 From: Alexandre Belloni To: Chen-Yu Tsai Cc: Maxime Ripard , Alessandro Zummo , Vincent Donnefort , linux-rtc@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Chen-Yu Tsai Subject: Re: [PATCH 2/3] rtc: pcf8563: Clear event flags and disable interrupts before requesting irq Message-ID: <20190620183742.GD23549@piout.net> References: <20190604042337.26129-1-wens@kernel.org> <20190604042337.26129-3-wens@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190604042337.26129-3-wens@kernel.org> User-Agent: Mutt/1.11.4 (2019-03-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/06/2019 12:23:36+0800, Chen-Yu Tsai wrote: > From: Chen-Yu Tsai > > Besides the alarm, the PCF8563 also has a timer triggered interrupt. > In cases where the previous system left the timer and interrupts on, > or somehow the bits got enabled, the interrupt would keep triggering > as the kernel doesn't know about it. > > Clear both the alarm and timer event flags, and disable the interrupts, > before requesting the interrupt line. > > Fixes: ede3e9d47cca ("drivers/rtc/rtc-pcf8563.c: add alarm support") > Fixes: a45d528aab8b ("rtc: pcf8563: clear expired alarm at boot time") > Signed-off-by: Chen-Yu Tsai > --- > drivers/rtc/rtc-pcf8563.c | 11 +++++------ > 1 file changed, 5 insertions(+), 6 deletions(-) > Applied, thanks. -- Alexandre Belloni, Bootlin Embedded Linux and Kernel engineering https://bootlin.com