Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2573126yba; Mon, 6 May 2019 08:11:22 -0700 (PDT) X-Google-Smtp-Source: APXvYqxBy6rfTkV7vhxlCi948bgij8mwzDjoSpxDQVo0r1QJO7T9RTgrpfLKoZwOShvBWnQHxLl4 X-Received: by 2002:a17:902:7797:: with SMTP id o23mr1054952pll.147.1557155482053; Mon, 06 May 2019 08:11:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557155482; cv=none; d=google.com; s=arc-20160816; b=Cd61YQrjaCwmP+jMM3syt2G9FUE1G/PLQjotroKecTMiQF44A6Jokx3ypoJQGddi10 D/fIU4AgY0rzl5yChorIyzsKHSjlovfCLsefmG9W2+dA5F7gNHGk9knwsI92RzBozB2S E+drkvflAjwfz0hIo11+RWUFS80sNMCejlwx1AVpl+J3O1RnY0T8a2adio1Vx6pT29sZ EGhxQxwfu0bMymknFCmyedqGim7SIR3CIUzQubTAR1j5lnV4iNkH6PkJp1QW8DTImY55 x9Q10yU3HHNg5hRXFmMrHWt6AEMReJEZk1bOaJ3HU9MEFumv0e6Q6g5qRIcP+1qWDTuv Efgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=VVeU0rj9ErwZQTzakR3DrMzy8i1PZIM2niwJPI7s6ts=; b=qCFJ6QD0sowmQUlgh1pvaAmD7PWvzXROZ1SLuKzZs67oT+9eZp4AfioMQ0CR5J+zG+ 2U0O3TUc0xCrZLwa5w0w4CCBiryVJv9c9GdC1gmbCLNGk+PTWGD+6uHBC5cOhFYFSbAx JGTF5LkFaxKHNJ5aaHXZUqt5/fNlNfcKz8sbVQXgh+7bV3qbSQ7n2DA6L7IXm4DRBXBf Q4whQhh9nZyqHApHeCPMqRHnHDvJ3clji3kvEQbe/B0hHE0M0pA/h+h08a05f7XiLwAM O+d43uBVISNaoNK/c3VNNza3KIRjBqe88/VjCwlhhsqmex/Pcx5IAF9KSkFiqwxSEInT H22A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ugGyTS04; 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 l10si14019070pgq.334.2019.05.06.08.11.04; Mon, 06 May 2019 08:11:22 -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; dkim=pass header.i=@kernel.org header.s=default header.b=ugGyTS04; 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 S1727081AbfEFOgE (ORCPT + 99 others); Mon, 6 May 2019 10:36:04 -0400 Received: from mail.kernel.org ([198.145.29.99]:56262 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727073AbfEFOgB (ORCPT ); Mon, 6 May 2019 10:36:01 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 1B414214AE; Mon, 6 May 2019 14:35:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1557153360; bh=+e1npYX2hzN0yu/0Pk81Mb6G/TcQHqkXK7Xqe5KdvZ4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ugGyTS04idOsANf5ziMBw2iLxtmf1YGJrLAGtJ5qx9vV4hLka8H052u5aTGB0rYFj i1AECH2gwvusl37KPNncbSf56aPm5fGIgl8Wf+DfLvICZKAaNq7p2x2QQAaEtMtAiw qgnFi69TPeisK6QY7CzVdqv2H6O+DWeQM0NvddTY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Wolfram Sang , Geert Uytterhoeven , Steve Twiss , Alexandre Belloni , "Sasha Levin (Microsoft)" Subject: [PATCH 5.0 060/122] rtc: da9063: set uie_unsupported when relevant Date: Mon, 6 May 2019 16:31:58 +0200 Message-Id: <20190506143100.390537986@linuxfoundation.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190506143054.670334917@linuxfoundation.org> References: <20190506143054.670334917@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ Upstream commit 882c5e552ffd06856de42261460f46e18319d259 ] The DA9063AD doesn't support alarms on any seconds and its granularity is the minute. Set uie_unsupported in that case. Reported-by: Wolfram Sang Reported-by: Geert Uytterhoeven Reviewed-by: Wolfram Sang Tested-by: Wolfram Sang Acked-by: Steve Twiss Signed-off-by: Alexandre Belloni Signed-off-by: Sasha Levin (Microsoft) --- drivers/rtc/rtc-da9063.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/rtc/rtc-da9063.c b/drivers/rtc/rtc-da9063.c index b4e054c64bad..69b54e5556c0 100644 --- a/drivers/rtc/rtc-da9063.c +++ b/drivers/rtc/rtc-da9063.c @@ -480,6 +480,13 @@ static int da9063_rtc_probe(struct platform_device *pdev) da9063_data_to_tm(data, &rtc->alarm_time, rtc); rtc->rtc_sync = false; + /* + * TODO: some models have alarms on a minute boundary but still support + * real hardware interrupts. Add this once the core supports it. + */ + if (config->rtc_data_start != RTC_SEC) + rtc->rtc_dev->uie_unsupported = 1; + irq_alarm = platform_get_irq_byname(pdev, "ALARM"); ret = devm_request_threaded_irq(&pdev->dev, irq_alarm, NULL, da9063_alarm_event, -- 2.20.1