diff options
author | Javier Carrasco <javier.carrasco.cruz@gmail.com> | 2024-07-04 00:46:34 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-07-06 03:02:19 +0300 |
commit | 7f805f6396d496e9b7b7e92389c987178afeef7b (patch) | |
tree | 66d6f99ccd500b011e4b81af4aacf54281e8290a /drivers/net/ethernet/ti | |
parent | 8dfbb068a4e14a3ff497661d211bfb4b2acc3563 (diff) | |
download | linux-7f805f6396d496e9b7b7e92389c987178afeef7b.tar.xz |
net: ti: icss-iep: constify struct regmap_config
`am654_icss_iep_regmap_config` is only assigned to a pointer that passes
the data as read-only.
Add the const modifier to the struct and pointer to move the data to a
read-only section.
Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
Reviewed-by: Roger Quadros <rogerq@kernel.org>
Reviewed-by: MD Danish Anwar <danishanwar@ti.com>
Link: https://patch.msgid.link/20240703-net-const-regmap-v1-2-ff4aeceda02c@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/ti')
-rw-r--r-- | drivers/net/ethernet/ti/icssg/icss_iep.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/ti/icssg/icss_iep.c b/drivers/net/ethernet/ti/icssg/icss_iep.c index 003668dee738..75c294ce6fb6 100644 --- a/drivers/net/ethernet/ti/icssg/icss_iep.c +++ b/drivers/net/ethernet/ti/icssg/icss_iep.c @@ -95,7 +95,7 @@ enum { * @flags: Flags to represent IEP properties */ struct icss_iep_plat_data { - struct regmap_config *config; + const struct regmap_config *config; u32 reg_offs[ICSS_IEP_MAX_REGS]; u32 flags; }; @@ -952,7 +952,7 @@ static int icss_iep_regmap_read(void *context, unsigned int reg, return 0; } -static struct regmap_config am654_icss_iep_regmap_config = { +static const struct regmap_config am654_icss_iep_regmap_config = { .name = "icss iep", .reg_stride = 1, .reg_write = icss_iep_regmap_write, |