From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755108AbcLZLbS (ORCPT ); Mon, 26 Dec 2016 06:31:18 -0500 Received: from mail-pg0-f66.google.com ([74.125.83.66]:34502 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751222AbcLZLbP (ORCPT ); Mon, 26 Dec 2016 06:31:15 -0500 From: Bhumika Goyal To: julia.lawall@lip6.fr, jason@lakedaemon.net, andrew@lunn.ch, gregory.clement@free-electrons.com, sebastian.hesselbarth@gmail.com, a.zummo@towertech.it, alexandre.belloni@free-electrons.com, linux-arm-kernel@lists.infradead.org, rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org Cc: keescook@chromium.org, Bhumika Goyal Subject: [PATCH] rtc: armada38x: add __ro_after_init to armada38x_rtc_ops Date: Mon, 26 Dec 2016 17:01:02 +0530 Message-Id: <1482751862-18699-1-git-send-email-bhumirks@gmail.com> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The object armada38x_rtc_ops of type rtc_class_ops structure is not modified after getting initialized by armada38x_rtc_probe. Apart from getting referenced in init it is also passed as an argument to the function devm_rtc_device_register but this argument is of type const struct rtc_class_ops *. Therefore add __ro_after_init to its declaration. Signed-off-by: Bhumika Goyal --- drivers/rtc/rtc-armada38x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/rtc-armada38x.c b/drivers/rtc/rtc-armada38x.c index 9a3f2a6..7883c7f 100644 --- a/drivers/rtc/rtc-armada38x.c +++ b/drivers/rtc/rtc-armada38x.c @@ -202,7 +202,7 @@ static irqreturn_t armada38x_rtc_alarm_irq(int irq, void *data) return IRQ_HANDLED; } -static struct rtc_class_ops armada38x_rtc_ops = { +static struct rtc_class_ops armada38x_rtc_ops __ro_after_init = { .read_time = armada38x_rtc_read_time, .set_time = armada38x_rtc_set_time, .read_alarm = armada38x_rtc_read_alarm, -- 1.9.1 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Sender: rtc-linux@googlegroups.com MIME-Version: 1.0 Received: from mail-pg0-x241.google.com (mail-pg0-x241.google.com. [2607:f8b0:400e:c05::241]) by gmr-mx.google.com with ESMTPS id t67si11519045pfd.3.2016.12.26.03.31.14 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 26 Dec 2016 03:31:14 -0800 (PST) Received: by mail-pg0-x241.google.com with SMTP id g1so9056966pgn.0 for ; Mon, 26 Dec 2016 03:31:14 -0800 (PST) From: Bhumika Goyal To: julia.lawall@lip6.fr, jason@lakedaemon.net, andrew@lunn.ch, gregory.clement@free-electrons.com, sebastian.hesselbarth@gmail.com, a.zummo@towertech.it, alexandre.belloni@free-electrons.com, linux-arm-kernel@lists.infradead.org, rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org Cc: keescook@chromium.org, Bhumika Goyal Subject: [rtc-linux] [PATCH] rtc: armada38x: add __ro_after_init to armada38x_rtc_ops Date: Mon, 26 Dec 2016 17:01:02 +0530 Message-Id: <1482751862-18699-1-git-send-email-bhumirks@gmail.com> Reply-To: rtc-linux@googlegroups.com Content-Type: text/plain; charset=UTF-8 List-ID: List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , The object armada38x_rtc_ops of type rtc_class_ops structure is not modified after getting initialized by armada38x_rtc_probe. Apart from getting referenced in init it is also passed as an argument to the function devm_rtc_device_register but this argument is of type const struct rtc_class_ops *. Therefore add __ro_after_init to its declaration. Signed-off-by: Bhumika Goyal --- drivers/rtc/rtc-armada38x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/rtc-armada38x.c b/drivers/rtc/rtc-armada38x.c index 9a3f2a6..7883c7f 100644 --- a/drivers/rtc/rtc-armada38x.c +++ b/drivers/rtc/rtc-armada38x.c @@ -202,7 +202,7 @@ static irqreturn_t armada38x_rtc_alarm_irq(int irq, void *data) return IRQ_HANDLED; } -static struct rtc_class_ops armada38x_rtc_ops = { +static struct rtc_class_ops armada38x_rtc_ops __ro_after_init = { .read_time = armada38x_rtc_read_time, .set_time = armada38x_rtc_set_time, .read_alarm = armada38x_rtc_read_alarm, -- 1.9.1 -- 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. --- You received this message because you are subscribed to the Google Groups "rtc-linux" group. To unsubscribe from this group and stop receiving emails from it, send an email to rtc-linux+unsubscribe@googlegroups.com. For more options, visit https://groups.google.com/d/optout. From mboxrd@z Thu Jan 1 00:00:00 1970 From: bhumirks@gmail.com (Bhumika Goyal) Date: Mon, 26 Dec 2016 17:01:02 +0530 Subject: [PATCH] rtc: armada38x: add __ro_after_init to armada38x_rtc_ops Message-ID: <1482751862-18699-1-git-send-email-bhumirks@gmail.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org The object armada38x_rtc_ops of type rtc_class_ops structure is not modified after getting initialized by armada38x_rtc_probe. Apart from getting referenced in init it is also passed as an argument to the function devm_rtc_device_register but this argument is of type const struct rtc_class_ops *. Therefore add __ro_after_init to its declaration. Signed-off-by: Bhumika Goyal --- drivers/rtc/rtc-armada38x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/rtc-armada38x.c b/drivers/rtc/rtc-armada38x.c index 9a3f2a6..7883c7f 100644 --- a/drivers/rtc/rtc-armada38x.c +++ b/drivers/rtc/rtc-armada38x.c @@ -202,7 +202,7 @@ static irqreturn_t armada38x_rtc_alarm_irq(int irq, void *data) return IRQ_HANDLED; } -static struct rtc_class_ops armada38x_rtc_ops = { +static struct rtc_class_ops armada38x_rtc_ops __ro_after_init = { .read_time = armada38x_rtc_read_time, .set_time = armada38x_rtc_set_time, .read_alarm = armada38x_rtc_read_alarm, -- 1.9.1