From patchwork Sat Jan 6 14:25:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Agner X-Patchwork-Id: 10147861 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 6050C601BE for ; Sat, 6 Jan 2018 14:28:58 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 50E7C284F9 for ; Sat, 6 Jan 2018 14:28:58 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 45687289C4; Sat, 6 Jan 2018 14:28:58 +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=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DEB32284F9 for ; Sat, 6 Jan 2018 14:28:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=2JsduLS6E+c8rviOVQeq2BZsMglJSMJSvZ9xuAQ9O8E=; b=eZ0HKMr3i2nNvgwopTZqM2gSJ7 MPL15k6BkFcinQIBfD5bJArWz0RzxWDhHQJqWjgf3DN6eSbIAAtJh6+N7RYIdYmR31M16bpwXIYik mb1+JvhhdAoNX03OefnY0ozChnYBlYUtfR65+DFMCJHOUkIo/MMBTIAaCwU05s8Jv8xIsEvxADOZk CR6fuPIDnR/SAPh9hJNoV49wgXOG+Woq+QEb7nHLm6X35Wb6FFR2b0hMfAtAbs0bxOj5DFuUV3CCc TU4yVS8rDCBb0VXzjavJRcye81tCZsiJemPH57Tpy0gquI538V1mkVPhOKv2G3Mm9ld302+Bo20AI 1mbG3p4Q==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1eXpSv-000776-9t; Sat, 06 Jan 2018 14:28:53 +0000 Received: from mail.kmu-office.ch ([2a02:418:6a02::a2]) by bombadil.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1eXpQW-0005Ol-AO for linux-arm-kernel@lists.infradead.org; Sat, 06 Jan 2018 14:26:28 +0000 Received: from trochilidae.toradex.int (unknown [IPv6:2001:1620:c6e::127]) by mail.kmu-office.ch (Postfix) with ESMTPSA id 679E55C3B9E; Sat, 6 Jan 2018 15:19:31 +0100 (CET) From: Stefan Agner To: linus.walleij@linaro.org, shawnguo@kernel.org, kernel@pengutronix.de Subject: [PATCH v2 4/5] pinctrl: imx7ulp: constify struct imx_cfg_params_decode Date: Sat, 6 Jan 2018 15:25:52 +0100 Message-Id: <20180106142553.15322-5-stefan@agner.ch> X-Mailer: git-send-email 2.15.1 In-Reply-To: <20180106142553.15322-1-stefan@agner.ch> References: <20180106142553.15322-1-stefan@agner.ch> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=agner.ch; s=dkim; t=1515248371; bh=mkQN3x8XA4tRRU6Vko8dx6GnEOtL6nSNkU0q1VnzmuI=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=UGRUdZjNhtkNqF/dKYp0/J+0uiyam8lUbL6wBp4VERAvOZjUY3Fgo6FVpq8U781p3KEGUfM6pTvaybQu/tDsRtqUkVsiYH34ZGQLvYheMOQgzfA4md6VGSMz1pbhiIs/vpLgRCPx+ovz9iEKVeJw2oEV44Mn/lHPgwEqXO2R2aQ= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180106_062624_617033_BC1ADDD7 X-CRM114-Status: UNSURE ( 8.99 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: aisheng.dong@nxp.com, mark.rutland@arm.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Stefan Agner , robh+dt@kernel.org, fabio.estevam@nxp.com, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The decode parameters are constant mark them const. Cc: Dong Aisheng Signed-off-by: Stefan Agner --- drivers/pinctrl/freescale/pinctrl-imx.c | 2 +- drivers/pinctrl/freescale/pinctrl-imx.h | 2 +- drivers/pinctrl/freescale/pinctrl-imx7ulp.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/pinctrl/freescale/pinctrl-imx.c b/drivers/pinctrl/freescale/pinctrl-imx.c index 86256d25c4a3..24aaddd760a0 100644 --- a/drivers/pinctrl/freescale/pinctrl-imx.c +++ b/drivers/pinctrl/freescale/pinctrl-imx.c @@ -255,7 +255,7 @@ static u32 imx_pinconf_decode_generic_config(struct imx_pinctrl *ipctl, unsigned int num_configs) { const struct imx_pinctrl_soc_info *info = ipctl->info; - struct imx_cfg_params_decode *decode; + const struct imx_cfg_params_decode *decode; enum pin_config_param param; u32 raw_config = 0; u32 param_val; diff --git a/drivers/pinctrl/freescale/pinctrl-imx.h b/drivers/pinctrl/freescale/pinctrl-imx.h index 41ee75537da4..038e8c0e5b96 100644 --- a/drivers/pinctrl/freescale/pinctrl-imx.h +++ b/drivers/pinctrl/freescale/pinctrl-imx.h @@ -71,7 +71,7 @@ struct imx_pinctrl_soc_info { bool generic_pinconf; const struct pinconf_generic_params *custom_params; unsigned int num_custom_params; - struct imx_cfg_params_decode *decodes; + const struct imx_cfg_params_decode *decodes; unsigned int num_decodes; void (*fixup)(unsigned long *configs, unsigned int num_configs, u32 *raw_config); diff --git a/drivers/pinctrl/freescale/pinctrl-imx7ulp.c b/drivers/pinctrl/freescale/pinctrl-imx7ulp.c index 0406d8b39e6a..f363e45fd246 100644 --- a/drivers/pinctrl/freescale/pinctrl-imx7ulp.c +++ b/drivers/pinctrl/freescale/pinctrl-imx7ulp.c @@ -266,7 +266,7 @@ static const struct pinctrl_pin_desc imx7ulp_pinctrl_pads[] = { #define BP_MUX_MODE 8 #define BM_PULL_ENABLED BIT(1) -struct imx_cfg_params_decode imx7ulp_cfg_decodes[] = { +static const struct imx_cfg_params_decode imx7ulp_cfg_decodes[] = { IMX_CFG_PARAMS_DECODE(PIN_CONFIG_DRIVE_STRENGTH, BIT(6), 6), IMX_CFG_PARAMS_DECODE(PIN_CONFIG_DRIVE_PUSH_PULL, BIT(5), 5), IMX_CFG_PARAMS_DECODE(PIN_CONFIG_SLEW_RATE, BIT(2), 2),