Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp3112415pxb; Tue, 19 Jan 2021 14:14:58 -0800 (PST) X-Google-Smtp-Source: ABdhPJx4y/0TfJXkEG6GYTW68rZ/N4HjtwDblcqAELtzYy36iPwVa52nNPGVtAeDTDoUTDfaXQco X-Received: by 2002:aa7:c6cf:: with SMTP id b15mr4877746eds.76.1611094498219; Tue, 19 Jan 2021 14:14:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611094498; cv=none; d=google.com; s=arc-20160816; b=apYzuC0ogYaVdFG6SotbiO3+B5ktqoDb9n1KX/2RVcRaMZfevosRnBYxS/Tbr/exl6 SuhzY4/dy2BarSTTvjr4WkrdxIGbHWZh158UgCPmpuFfDPJW+MUkF8EiHkoBlcaSyAfO 0HV67La68QvTdNIYYP5VVlsY4XACWGhsf/DF8cgFVfCYrEfKRBWZz5KtE1IAOZgmKX2f X21MrP4UjB7yodK+/4ddsWIahyMpmieKiDhaePm3lpWNyB1aon0ca9WSu70FBzD1xf0y GVQKfKz/kVS5Z5RDDvp8oJM8zzn9UJTLH8R1SIzOy65hQbQo3DHbF7BQOWJkpfLbkbml jFuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=oXWgPtX2/TLrt87mvjNmmrPCuVuYNNqnSTdLM4f/w8I=; b=cMCCQZrMpEd3J9HCiV8EwUCrRZONtffcTwS1wqfLiEDcz6p06gb11ga6hNhP1857Qh QvRW9wgCn2Lle/f2Bk3siLBtRtH/xJIjOF+Li1txxeNbn207mbtUWbsgXaSIO8Lc5qwU TlNX4lMGHwA3advDn4jjBdqoDDwExCKqlxlJQyHO6i+MQKgfjp4wcq5ihmzsa+UzjxkG HES+jK5lLMoUPRUvIZLIfwQQNWsgujVWjIgtkol10WxZSywVhmm4oTNdM7ZHDSVCoLHy AfwCFUeicqbO3MqCPrvbMqoueoDYdmEmwkxWUbn/U87qYrsTKbHy/WG8k+HwHlc0B3Nd R4gA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o16si11550ejr.715.2021.01.19.14.14.33; Tue, 19 Jan 2021 14:14:58 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728318AbhASWKW (ORCPT + 99 others); Tue, 19 Jan 2021 17:10:22 -0500 Received: from relay5-d.mail.gandi.net ([217.70.183.197]:40277 "EHLO relay5-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729509AbhASWIN (ORCPT ); Tue, 19 Jan 2021 17:08:13 -0500 X-Originating-IP: 86.202.109.140 Received: from localhost (lfbn-lyo-1-13-140.w86-202.abo.wanadoo.fr [86.202.109.140]) (Authenticated sender: alexandre.belloni@bootlin.com) by relay5-d.mail.gandi.net (Postfix) with ESMTPSA id 1082F1C0007; Tue, 19 Jan 2021 22:07:07 +0000 (UTC) From: Alexandre Belloni To: Alessandro Zummo , Alexandre Belloni , Maxime Coquelin , Alexandre Torgue Cc: linux-rtc@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 14/14] rtc: stm32: use rtc_lock/rtc_unlock Date: Tue, 19 Jan 2021 23:06:52 +0100 Message-Id: <20210119220653.677750-14-alexandre.belloni@bootlin.com> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210119220653.677750-1-alexandre.belloni@bootlin.com> References: <20210119220653.677750-1-alexandre.belloni@bootlin.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Avoid accessing directly rtc->ops_lock and use the RTC core helpers. Signed-off-by: Alexandre Belloni --- drivers/rtc/rtc-stm32.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/rtc/rtc-stm32.c b/drivers/rtc/rtc-stm32.c index d774aa18f57a..75a8924ba12b 100644 --- a/drivers/rtc/rtc-stm32.c +++ b/drivers/rtc/rtc-stm32.c @@ -209,7 +209,7 @@ static irqreturn_t stm32_rtc_alarm_irq(int irq, void *dev_id) const struct stm32_rtc_events *evts = &rtc->data->events; unsigned int status, cr; - mutex_lock(&rtc->rtc_dev->ops_lock); + rtc_lock(rtc->rtc_dev); status = readl_relaxed(rtc->base + regs->sr); cr = readl_relaxed(rtc->base + regs->cr); @@ -226,7 +226,7 @@ static irqreturn_t stm32_rtc_alarm_irq(int irq, void *dev_id) stm32_rtc_clear_event_flags(rtc, evts->alra); } - mutex_unlock(&rtc->rtc_dev->ops_lock); + rtc_unlock(rtc->rtc_dev); return IRQ_HANDLED; } -- 2.29.2