Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp3118315pxb; Tue, 19 Jan 2021 14:24:38 -0800 (PST) X-Google-Smtp-Source: ABdhPJz3btDHn4EzzR8jsoaXObM60Zu/A7ZrrRc8QCpEFBml6+9el2ZctHeiE7idBm0Lp6TCpf8+ X-Received: by 2002:a05:6402:524f:: with SMTP id t15mr3206301edd.158.1611095078074; Tue, 19 Jan 2021 14:24:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611095078; cv=none; d=google.com; s=arc-20160816; b=oK85o4KeTWJturn0Z3FolNhCwkcfG6JquS+WXfaERGjej7IY1Y4ydaj8wMND/uSkrc XxjwoxrFnNRS1DvSWTOtl2fK1wiU/2scq8RahjE47afZ+p+9QX/b/1iGWr3uW84CMiiU 6apyH/dvgUSeydOkd9kYOkfNvTyMMcbhOyZR2Z+FVDKG0mVyT9Z8TK6OeuCDMLbrzutY pKiV9tRae+kkTso9OZsT/I7V1LZ0OFJCxrQF5nOb7Dw5o3I0GQDRUhGt5NGDZKyGv6wt gzhg2aD0NvDGIFTQW5WltblZvhGxX47VPa8Af9a5M00lybJ8OsKIhsbuCu7WEDHbUmyU sT5w== 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=qcvg9NbCjBnO/XZAmR7wkQ9E2LNoTCPhnEig2IpZdNA=; b=uybB7/xplPwjBAWypJ3Vh3TXCinG3tjqRNu3/jGzjy6pvd1QcR3pJDBBTuPPBEZZcm Pt2bhcmcOxcgcBf2rDPIeJtkgjr3nU6Y8LFPBhoaDIXdEwrJQfXzR0gfQdSSxbKHybRQ Zf5kYwgpaXlN21w9XKUQazXdcC+SRWm9hXfJIkJPFPsTmWHxVtfiKP3w30BuJkDzOAi3 T3b4dHc1f1Yxc8c7H/vq5pg8MBnPbmHXUvlhOML/Ojb9q9LJJgZfzjO+AFPHlw15JBj6 T86F038r9wlLV3HqI1NxpkTuWe6RA7Ps3HG6/P+ECfHTDAk/JWAVC5Wv6J2FIkYst3gs Hqwg== 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 n25si57259edw.77.2021.01.19.14.24.10; Tue, 19 Jan 2021 14:24:38 -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 S1727990AbhASWWs (ORCPT + 99 others); Tue, 19 Jan 2021 17:22:48 -0500 Received: from relay7-d.mail.gandi.net ([217.70.183.200]:42479 "EHLO relay7-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729427AbhASWIH (ORCPT ); Tue, 19 Jan 2021 17:08:07 -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 relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 6FFD620009; Tue, 19 Jan 2021 22:07:01 +0000 (UTC) From: Alexandre Belloni To: Alessandro Zummo , Alexandre Belloni Cc: linux-rtc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 07/14] rtc: hym8563: use rtc_lock/rtc_unlock Date: Tue, 19 Jan 2021 23:06:45 +0100 Message-Id: <20210119220653.677750-7-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-hym8563.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/rtc/rtc-hym8563.c b/drivers/rtc/rtc-hym8563.c index 24e0095be058..0751cae27285 100644 --- a/drivers/rtc/rtc-hym8563.c +++ b/drivers/rtc/rtc-hym8563.c @@ -428,10 +428,9 @@ static irqreturn_t hym8563_irq(int irq, void *dev_id) { struct hym8563 *hym8563 = (struct hym8563 *)dev_id; struct i2c_client *client = hym8563->client; - struct mutex *lock = &hym8563->rtc->ops_lock; int data, ret; - mutex_lock(lock); + rtc_lock(hym8563->rtc); /* Clear the alarm flag */ @@ -451,7 +450,7 @@ static irqreturn_t hym8563_irq(int irq, void *dev_id) } out: - mutex_unlock(lock); + rtc_unlock(hym8563->rtc); return IRQ_HANDLED; } -- 2.29.2