Thread (67 messages) 67 messages, 5 authors, 2021-02-28
STALE1917d
Revisions (10)
  1. v8 current
  2. v9 [diff vs current]
  3. v10 [diff vs current]
  4. v11 [diff vs current]
  5. v12 [diff vs current]
  6. v13 [diff vs current]
  7. v14 [diff vs current]
  8. v15 [diff vs current]
  9. v16 [diff vs current]
  10. v17 [diff vs current]

[PATCH v8 07/22] counter: 104-quad-8: Add const qualifier for actions_list array

From: William Breathitt Gray <hidden>
Date: 2021-02-12 12:16:37
Also in: linux-arm-kernel, lkml
Subsystem: acces 104-quad-8 driver, counter subsystem, the rest · Maintainers: William Breathitt Gray, Linus Torvalds

The struct counter_synapse actions_list member expects a const enum
counter_synapse_action array. This patch adds the const qualifier to the
quad8_index_actions_list and quad8_synapse_actions_list to match
actions_list.

Cc: Syed Nayyar Waris <redacted>
Signed-off-by: William Breathitt Gray <redacted>
---
 drivers/counter/104-quad-8.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/counter/104-quad-8.c b/drivers/counter/104-quad-8.c
index af4e0503b074..9a96296b0625 100644
--- a/drivers/counter/104-quad-8.c
+++ b/drivers/counter/104-quad-8.c
@@ -305,12 +305,12 @@ enum quad8_synapse_action {
 	QUAD8_SYNAPSE_ACTION_BOTH_EDGES
 };
 
-static enum counter_synapse_action quad8_index_actions_list[] = {
+static const enum counter_synapse_action quad8_index_actions_list[] = {
 	[QUAD8_SYNAPSE_ACTION_NONE] = COUNTER_SYNAPSE_ACTION_NONE,
 	[QUAD8_SYNAPSE_ACTION_RISING_EDGE] = COUNTER_SYNAPSE_ACTION_RISING_EDGE
 };
 
-static enum counter_synapse_action quad8_synapse_actions_list[] = {
+static const enum counter_synapse_action quad8_synapse_actions_list[] = {
 	[QUAD8_SYNAPSE_ACTION_NONE] = COUNTER_SYNAPSE_ACTION_NONE,
 	[QUAD8_SYNAPSE_ACTION_RISING_EDGE] = COUNTER_SYNAPSE_ACTION_RISING_EDGE,
 	[QUAD8_SYNAPSE_ACTION_FALLING_EDGE] = COUNTER_SYNAPSE_ACTION_FALLING_EDGE,
-- 
2.30.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help