From: Rikard Falkeborn <rikard.falkeborn@gmail.com>
To: "Andreas Färber" <afaerber@suse.de>,
"Manivannan Sadhasivam" <manivannan.sadhasivam@linaro.org>,
"Linus Walleij" <linus.walleij@linaro.org>
Cc: linux-arm-kernel@lists.infradead.org, linux-gpio@vger.kernel.org,
linux-kernel@vger.kernel.org,
Rikard Falkeborn <rikard.falkeborn@gmail.com>
Subject: [PATCH 3/3] pinctrl: actions: pinctrl-s900: Constify s900_padinfo[]
Date: Mon, 31 Aug 2020 00:43:11 +0200 [thread overview]
Message-ID: <20200830224311.36994-4-rikard.falkeborn@gmail.com> (raw)
In-Reply-To: <20200830224311.36994-1-rikard.falkeborn@gmail.com>
The only usage of s900_padinfo[] is to assign it to the padinfo field in
the owl_pinctrl_soc_data struct, which is a const pointer. Make it const
to allow the compiler to put it in read-only memory.
Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com>
---
drivers/pinctrl/actions/pinctrl-s900.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pinctrl/actions/pinctrl-s900.c b/drivers/pinctrl/actions/pinctrl-s900.c
index 9492b86852e7..811249a8011e 100644
--- a/drivers/pinctrl/actions/pinctrl-s900.c
+++ b/drivers/pinctrl/actions/pinctrl-s900.c
@@ -1556,7 +1556,7 @@ static PAD_ST_CONF(I2S_BCLK0, 1, 1, 1);
static PAD_ST_CONF(I2S_MCLK0, 1, 0, 1);
/* Pad info table */
-static struct owl_padinfo s900_padinfo[NUM_PADS] = {
+static const struct owl_padinfo s900_padinfo[NUM_PADS] = {
[ETH_TXD0] = PAD_INFO_ST(ETH_TXD0),
[ETH_TXD1] = PAD_INFO_ST(ETH_TXD1),
[ETH_TXEN] = PAD_INFO_ST(ETH_TXEN),
--
2.28.0
next prev parent reply other threads:[~2020-08-30 22:43 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-30 22:43 [PATCH 0/3] pinctrl/actions: Constify static variables Rikard Falkeborn
2020-08-30 22:43 ` [PATCH 1/3] pinctrl: actions: pinctrl-owl: Constify owl_pinctrl_ops and owl_pinmux_ops Rikard Falkeborn
2020-08-30 22:43 ` [PATCH 2/3] pinctrl: actions: pinctrl-s700: Constify s700_padinfo[] Rikard Falkeborn
2020-08-30 22:43 ` Rikard Falkeborn [this message]
2020-08-31 9:15 ` [PATCH 0/3] pinctrl/actions: Constify static variables Manivannan Sadhasivam
2020-09-12 10:15 ` Linus Walleij
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200830224311.36994-4-rikard.falkeborn@gmail.com \
--to=rikard.falkeborn@gmail.com \
--cc=afaerber@suse.de \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=manivannan.sadhasivam@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®