From patchwork Tue Aug 15 15:10:09 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julia Lawall X-Patchwork-Id: 9902095 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8985B60230 for ; Tue, 15 Aug 2017 15:36:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7BABD2888F for ; Tue, 15 Aug 2017 15:36:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 708D028897; Tue, 15 Aug 2017 15:36:38 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E00172888F for ; Tue, 15 Aug 2017 15:36:37 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 67A1F267467; Tue, 15 Aug 2017 17:36:01 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 179B6267456; Tue, 15 Aug 2017 17:35:56 +0200 (CEST) Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by alsa0.perex.cz (Postfix) with ESMTP id 42640267456 for ; Tue, 15 Aug 2017 17:35:54 +0200 (CEST) X-IronPort-AV: E=Sophos;i="5.41,378,1498514400"; d="scan'208";a="234482055" Received: from palace.lip6.fr (HELO localhost.localdomain) ([132.227.105.202]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/AES128-SHA256; 15 Aug 2017 17:35:52 +0200 From: Julia Lawall To: Liam Girdwood Date: Tue, 15 Aug 2017 17:10:09 +0200 Message-Id: <1502809812-13891-3-git-send-email-Julia.Lawall@lip6.fr> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1502809812-13891-1-git-send-email-Julia.Lawall@lip6.fr> References: <1502809812-13891-1-git-send-email-Julia.Lawall@lip6.fr> Cc: alsa-devel@alsa-project.org, Heiko Stuebner , linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Takashi Iwai , linux-rockchip@lists.infradead.org, Mark Brown , linux-arm-kernel@lists.infradead.org, bhumirks@gmail.com Subject: [alsa-devel] [PATCH 2/5] ASoC: rockchip: constify snd_soc_dai_ops structures X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP These snd_soc_dai_ops structures are only stored in the ops field of a snd_soc_dai_driver structure, which is const. Thus, the snd_soc_dai_ops structures can be const too. Done with the help of Coccinelle. Signed-off-by: Julia Lawall --- sound/soc/rockchip/rockchip_pdm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/rockchip/rockchip_pdm.c b/sound/soc/rockchip/rockchip_pdm.c index c5ddeed..400e29e 100644 --- a/sound/soc/rockchip/rockchip_pdm.c +++ b/sound/soc/rockchip/rockchip_pdm.c @@ -249,7 +249,7 @@ static int rockchip_pdm_dai_probe(struct snd_soc_dai *dai) return 0; } -static struct snd_soc_dai_ops rockchip_pdm_dai_ops = { +static const struct snd_soc_dai_ops rockchip_pdm_dai_ops = { .set_fmt = rockchip_pdm_set_fmt, .trigger = rockchip_pdm_trigger, .hw_params = rockchip_pdm_hw_params,