realtek: fix regmap_field getter const qualifier
The allocated regmap_field object is not stored as a const reference, so
the helper function allocating the object should not return it as such.
Drop 'const' so the build doesn't complain about discarding the
qualifier.
Fixes: 6ef6014887 ("realtek: Add pinctrl support for RTL8231")
Signed-off-by: Sander Vanheule <sander@svanheule.net>
This commit is contained in:
parent
75a33df5f6
commit
c98289b074
@ -233,7 +233,7 @@ Signed-off-by: Sander Vanheule <sander@svanheule.net>
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static const struct regmap_field *rtl8231_led_get_field(struct device *dev, struct regmap *map,
|
||||
+static struct regmap_field *rtl8231_led_get_field(struct device *dev, struct regmap *map,
|
||||
+ unsigned int port_index, unsigned int led_index)
|
||||
+{
|
||||
+ unsigned int offset = port_index / RTL8231_LED_PER_REG;
|
||||
|
||||
@ -233,7 +233,7 @@ Signed-off-by: Sander Vanheule <sander@svanheule.net>
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static const struct regmap_field *rtl8231_led_get_field(struct device *dev, struct regmap *map,
|
||||
+static struct regmap_field *rtl8231_led_get_field(struct device *dev, struct regmap *map,
|
||||
+ unsigned int port_index, unsigned int led_index)
|
||||
+{
|
||||
+ unsigned int offset = port_index / RTL8231_LED_PER_REG;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user