1 /* SPDX-License-Identifier: GPL-2.0 */
10 #include <linux/types.h>
11 #include <linux/leds.h>
12 #include <linux/workqueue.h>
15 #define B43_LED_MAX_NAME_LEN 31
19 /* The LED class device */
20 struct led_classdev led_dev;
21 /* The index number of the LED. */
23 /* If activelow is true, the LED is ON if the
24 * bit is switched off. */
26 /* The unique name string for this LED device. */
27 char name[B43_LED_MAX_NAME_LEN + 1];
28 /* The current status of the LED. This is updated locklessly. */
30 /* The active state in hardware. */
35 struct b43_led led_tx;
36 struct b43_led led_rx;
37 struct b43_led led_radio;
38 struct b43_led led_assoc;
41 struct work_struct work;
44 #define B43_MAX_NR_LEDS 4
46 #define B43_LED_BEHAVIOUR 0x7F
47 #define B43_LED_ACTIVELOW 0x80
48 /* LED behaviour values */
49 enum b43_led_behaviour {
59 B43_LED_WEIRD, //FIXME
64 void b43_leds_register(struct b43_wldev *dev);
65 void b43_leds_unregister(struct b43_wl *wl);
66 void b43_leds_init(struct b43_wldev *dev);
67 void b43_leds_exit(struct b43_wldev *dev);
68 void b43_leds_stop(struct b43_wldev *dev);
71 #else /* CONFIG_B43_LEDS */
72 /* LED support disabled */
78 static inline void b43_leds_register(struct b43_wldev *dev)
81 static inline void b43_leds_unregister(struct b43_wl *wl)
84 static inline void b43_leds_init(struct b43_wldev *dev)
87 static inline void b43_leds_exit(struct b43_wldev *dev)
90 static inline void b43_leds_stop(struct b43_wldev *dev)
93 #endif /* CONFIG_B43_LEDS */
95 #endif /* B43_LEDS_H_ */