All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] leds: trigger: stop exporting trigger_list
@ 2024-01-31 14:30 Heiner Kallweit
  2024-02-08 10:22 ` (subset) " Lee Jones
  0 siblings, 1 reply; 6+ messages in thread
From: Heiner Kallweit @ 2024-01-31 14:30 UTC (permalink / raw)
  To: Pavel Machek, Lee Jones; +Cc: linux-leds@vger.kernel.org

682e98564ffb ("leds: trigger: panic: Simplify led_trigger_set_panic")
removed the last external user of variable trigger_list. So stop
exporting it.
If in future a need should arise again to access this variable, I think
we better add some accessor instead of exporting the variable directly.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
---
applies on top of for-leds-next
---
 drivers/leds/led-triggers.c | 2 +-
 drivers/leds/leds.h         | 1 -
 2 files changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/leds/led-triggers.c b/drivers/leds/led-triggers.c
index 71cb0aee5..371000770 100644
--- a/drivers/leds/led-triggers.c
+++ b/drivers/leds/led-triggers.c
@@ -23,7 +23,7 @@
  * Nests outside led_cdev->trigger_lock
  */
 static DECLARE_RWSEM(triggers_list_lock);
-LIST_HEAD(trigger_list);
+static LIST_HEAD(trigger_list);
 
  /* Used by LED Class */
 
diff --git a/drivers/leds/leds.h b/drivers/leds/leds.h
index 345062cca..1138e2ab8 100644
--- a/drivers/leds/leds.h
+++ b/drivers/leds/leds.h
@@ -30,7 +30,6 @@ ssize_t led_trigger_write(struct file *filp, struct kobject *kobj,
 
 extern struct rw_semaphore leds_list_lock;
 extern struct list_head leds_list;
-extern struct list_head trigger_list;
 extern const char * const led_colors[LED_COLOR_ID_MAX];
 
 #endif	/* __LEDS_H_INCLUDED */
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-02-08 10:51 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-31 14:30 [PATCH] leds: trigger: stop exporting trigger_list Heiner Kallweit
2024-02-08 10:22 ` (subset) " Lee Jones
2024-02-08 10:23   ` Lee Jones
2024-02-08 10:43     ` Heiner Kallweit
2024-02-08 10:45       ` Lee Jones
2024-02-08 10:51         ` Heiner Kallweit

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.