From: Javier Carrasco <javier.carrasco.cruz@gmail.com>
To: Jean Delvare <jdelvare@suse.com>,
Guenter Roeck <linux@roeck-us.net>,
Eric Tremblay <etremblay@distech-controls.com>,
Robert Marko <robert.marko@sartura.hr>,
Luka Perkov <luka.perkov@sartura.hr>
Cc: linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org,
Javier Carrasco <javier.carrasco.cruz@gmail.com>
Subject: [PATCH 3/3] hwmon: (tps23861) Constify struct regmap_config
Date: Tue, 02 Jul 2024 12:09:32 +0200 [thread overview]
Message-ID: <20240702-hwmon-const-regmap-v1-3-63f6d4765fe0@gmail.com> (raw)
In-Reply-To: <20240702-hwmon-const-regmap-v1-0-63f6d4765fe0@gmail.com>
`tps23861_regmap_config` is not modified and can be declared as const to
move its data to a read-only section.
Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
---
drivers/hwmon/tps23861.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hwmon/tps23861.c b/drivers/hwmon/tps23861.c
index d33ecbac00d6..dfcfb09d9f3c 100644
--- a/drivers/hwmon/tps23861.c
+++ b/drivers/hwmon/tps23861.c
@@ -117,7 +117,7 @@ struct tps23861_data {
struct dentry *debugfs_dir;
};
-static struct regmap_config tps23861_regmap_config = {
+static const struct regmap_config tps23861_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
.max_register = 0x6f,
--
2.40.1
next prev parent reply other threads:[~2024-07-02 10:09 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-02 10:09 [PATCH 0/3] hwmon: constify struct regmap_config Javier Carrasco
2024-07-02 10:09 ` [PATCH 1/3] hwmon: (ina238) Constify " Javier Carrasco
2024-07-02 18:30 ` Guenter Roeck
2024-07-02 10:09 ` [PATCH 2/3] hwmon: (tmp513) " Javier Carrasco
2024-07-02 18:31 ` Guenter Roeck
2024-07-02 10:09 ` Javier Carrasco [this message]
2024-07-02 18:31 ` [PATCH 3/3] hwmon: (tps23861) " Guenter Roeck
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=20240702-hwmon-const-regmap-v1-3-63f6d4765fe0@gmail.com \
--to=javier.carrasco.cruz@gmail.com \
--cc=etremblay@distech-controls.com \
--cc=jdelvare@suse.com \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=luka.perkov@sartura.hr \
--cc=robert.marko@sartura.hr \
/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