This source file includes following definitions.
- b43_leds_register
- b43_leds_unregister
- b43_leds_init
- b43_leds_exit
- b43_leds_stop
1
2 #ifndef B43_LEDS_H_
3 #define B43_LEDS_H_
4
5 struct b43_wl;
6 struct b43_wldev;
7
8 #ifdef CONFIG_B43_LEDS
9
10 #include <linux/types.h>
11 #include <linux/leds.h>
12 #include <linux/workqueue.h>
13
14
15 #define B43_LED_MAX_NAME_LEN 31
16
17 struct b43_led {
18 struct b43_wl *wl;
19
20 struct led_classdev led_dev;
21
22 u8 index;
23
24
25 bool activelow;
26
27 char name[B43_LED_MAX_NAME_LEN + 1];
28
29 atomic_t state;
30
31 bool hw_state;
32 };
33
34 struct b43_leds {
35 struct b43_led led_tx;
36 struct b43_led led_rx;
37 struct b43_led led_radio;
38 struct b43_led led_assoc;
39
40 bool stop;
41 struct work_struct work;
42 };
43
44 #define B43_MAX_NR_LEDS 4
45
46 #define B43_LED_BEHAVIOUR 0x7F
47 #define B43_LED_ACTIVELOW 0x80
48
49 enum b43_led_behaviour {
50 B43_LED_OFF,
51 B43_LED_ON,
52 B43_LED_ACTIVITY,
53 B43_LED_RADIO_ALL,
54 B43_LED_RADIO_A,
55 B43_LED_RADIO_B,
56 B43_LED_MODE_BG,
57 B43_LED_TRANSFER,
58 B43_LED_APTRANSFER,
59 B43_LED_WEIRD,
60 B43_LED_ASSOC,
61 B43_LED_INACTIVE,
62 };
63
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);
69
70
71 #else
72
73
74 struct b43_leds {
75
76 };
77
78 static inline void b43_leds_register(struct b43_wldev *dev)
79 {
80 }
81 static inline void b43_leds_unregister(struct b43_wl *wl)
82 {
83 }
84 static inline void b43_leds_init(struct b43_wldev *dev)
85 {
86 }
87 static inline void b43_leds_exit(struct b43_wldev *dev)
88 {
89 }
90 static inline void b43_leds_stop(struct b43_wldev *dev)
91 {
92 }
93 #endif
94
95 #endif