Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932423AbdIRMyK (ORCPT ); Mon, 18 Sep 2017 08:54:10 -0400 Received: from mail-pg0-f66.google.com ([74.125.83.66]:37173 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932366AbdIRMyJ (ORCPT ); Mon, 18 Sep 2017 08:54:09 -0400 X-Google-Smtp-Source: ADKCNb6M8fJ4urtheDZ3qAYrI33Iw5+A+Y7+Ga2kb5B1HAbhyjOcrk00/qakiGKLnfRXLKLatmLa9g== From: Bhumika Goyal To: julia.lawall@lip6.fr, daniel.lezcano@linaro.org, tglx@linutronix.de, linux-kernel@vger.kernel.org Cc: Bhumika Goyal Subject: [PATCH] x86/numachip: make numachip2_clockevent const and __initconst Date: Mon, 18 Sep 2017 18:23:53 +0530 Message-Id: <1505739233-8209-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 Content-Length: 860 Lines: 25 Make this const as it is only used during a copy operation. This usage is during the init phase, so annotate the structure with __initconst too. Done using Coccinelle. Signed-off-by: Bhumika Goyal --- drivers/clocksource/numachip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clocksource/numachip.c b/drivers/clocksource/numachip.c index 6a20dc8..9a7d7f0 100644 --- a/drivers/clocksource/numachip.c +++ b/drivers/clocksource/numachip.c @@ -43,7 +43,7 @@ static int numachip2_set_next_event(unsigned long delta, struct clock_event_devi return 0; } -static struct clock_event_device numachip2_clockevent = { +static const struct clock_event_device numachip2_clockevent __initconst = { .name = "numachip2", .rating = 400, .set_next_event = numachip2_set_next_event, -- 1.9.1