rfkill.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #ifndef B43legacy_RFKILL_H_
  2. #define B43legacy_RFKILL_H_
  3. struct b43legacy_wldev;
  4. #ifdef CONFIG_B43LEGACY_RFKILL
  5. #include <linux/rfkill.h>
  6. #include <linux/workqueue.h>
  7. struct b43legacy_rfkill {
  8. /* The RFKILL subsystem data structure */
  9. struct rfkill *rfkill;
  10. /* The unique name of this rfkill switch */
  11. char name[32];
  12. /* Workqueue for asynchronous notification. */
  13. struct work_struct notify_work;
  14. };
  15. void b43legacy_rfkill_init(struct b43legacy_wldev *dev);
  16. void b43legacy_rfkill_exit(struct b43legacy_wldev *dev);
  17. void b43legacy_rfkill_toggled(struct b43legacy_wldev *dev, bool on);
  18. char *b43legacy_rfkill_led_name(struct b43legacy_wldev *dev);
  19. #else /* CONFIG_B43LEGACY_RFKILL */
  20. /* No RFKILL support. */
  21. struct b43legacy_rfkill {
  22. /* empty */
  23. };
  24. static inline void b43legacy_rfkill_init(struct b43legacy_wldev *dev)
  25. {
  26. }
  27. static inline void b43legacy_rfkill_exit(struct b43legacy_wldev *dev)
  28. {
  29. }
  30. static inline void b43legacy_rfkill_toggled(struct b43legacy_wldev *dev,
  31. bool on)
  32. {
  33. }
  34. static inline char *b43legacy_rfkill_led_name(struct b43legacy_wldev *dev)
  35. {
  36. return NULL;
  37. }
  38. #endif /* CONFIG_B43LEGACY_RFKILL */
  39. #endif /* B43legacy_RFKILL_H_ */