Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751586AbdISLOt (ORCPT ); Tue, 19 Sep 2017 07:14:49 -0400 Received: from mail-pg0-f66.google.com ([74.125.83.66]:37912 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750964AbdISLOs (ORCPT ); Tue, 19 Sep 2017 07:14:48 -0400 X-Google-Smtp-Source: AOwi7QBL3ssaQpef+HDzHTp6sDwiWxSgdrGBsl46NfWwiOT+TD1ldMk8LOhRzpSKf/1//uRJMFNBKQ== From: Bhumika Goyal To: julia.lawall@lip6.fr, perex@perex.cz, tiwai@suse.com, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org Cc: Bhumika Goyal Subject: [PATCH] ALSA: hrtimer: make hrtimer_hw const and __initconst Date: Tue, 19 Sep 2017 16:44:38 +0530 Message-Id: <1505819678-1512-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: 774 Lines: 24 Make this const as it is only used during a copy operation. Also, make it __initconst as it is only used during the init phase and after this it is not referenced anywhere. Signed-off-by: Bhumika Goyal --- sound/core/hrtimer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/core/hrtimer.c b/sound/core/hrtimer.c index 1ac0c42..5603e49 100644 --- a/sound/core/hrtimer.c +++ b/sound/core/hrtimer.c @@ -127,7 +127,7 @@ static int snd_hrtimer_stop(struct snd_timer *t) return 0; } -static struct snd_timer_hardware hrtimer_hw = { +static const struct snd_timer_hardware hrtimer_hw __initconst = { .flags = SNDRV_TIMER_HW_AUTO | SNDRV_TIMER_HW_TASKLET, .open = snd_hrtimer_open, .close = snd_hrtimer_close, -- 1.9.1