From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752094AbdG1NJZ (ORCPT ); Fri, 28 Jul 2017 09:09:25 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:36773 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751673AbdG1NJW (ORCPT ); Fri, 28 Jul 2017 09:09:22 -0400 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 3/5] ALSA: pci: constify snd_timer_hardware structures Date: Fri, 28 Jul 2017 18:38:28 +0530 Message-Id: <1501247311-19803-4-git-send-email-bhumirks@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1501247311-19803-1-git-send-email-bhumirks@gmail.com> References: <1501247311-19803-1-git-send-email-bhumirks@gmail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Declare snd_timer_hardware structures as const as their only usage is during a copy operation. As they are not modified anywhere, they can be made const. Signed-off-by: Bhumika Goyal --- sound/pci/emu10k1/timer.c | 2 +- sound/pci/ymfpci/ymfpci_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/pci/emu10k1/timer.c b/sound/pci/emu10k1/timer.c index b69a7f8..cf43908 100644 --- a/sound/pci/emu10k1/timer.c +++ b/sound/pci/emu10k1/timer.c @@ -66,7 +66,7 @@ static int snd_emu10k1_timer_precise_resolution(struct snd_timer *timer, return 0; } -static struct snd_timer_hardware snd_emu10k1_timer_hw = { +static const struct snd_timer_hardware snd_emu10k1_timer_hw = { .flags = SNDRV_TIMER_HW_AUTO, .resolution = 20833, /* 1 sample @ 48KHZ = 20.833...us */ .ticks = 1024, diff --git a/sound/pci/ymfpci/ymfpci_main.c b/sound/pci/ymfpci/ymfpci_main.c index 1114166..39b1d11 100644 --- a/sound/pci/ymfpci/ymfpci_main.c +++ b/sound/pci/ymfpci/ymfpci_main.c @@ -1938,7 +1938,7 @@ static int snd_ymfpci_timer_precise_resolution(struct snd_timer *timer, return 0; } -static struct snd_timer_hardware snd_ymfpci_timer_hw = { +static const struct snd_timer_hardware snd_ymfpci_timer_hw = { .flags = SNDRV_TIMER_HW_AUTO, .resolution = 10417, /* 1 / 96 kHz = 10.41666...us */ .ticks = 0x10000, -- 1.9.1