wext.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. #ifndef __NET_WEXT_H
  2. #define __NET_WEXT_H
  3. #include <net/iw_handler.h>
  4. struct net;
  5. #ifdef CONFIG_WEXT_CORE
  6. int wext_handle_ioctl(struct net *net, struct ifreq *ifr, unsigned int cmd,
  7. void __user *arg);
  8. int compat_wext_handle_ioctl(struct net *net, unsigned int cmd,
  9. unsigned long arg);
  10. struct iw_statistics *get_wireless_stats(struct net_device *dev);
  11. int call_commit_handler(struct net_device *dev);
  12. #else
  13. static inline int wext_handle_ioctl(struct net *net, struct ifreq *ifr, unsigned int cmd,
  14. void __user *arg)
  15. {
  16. return -EINVAL;
  17. }
  18. static inline int compat_wext_handle_ioctl(struct net *net, unsigned int cmd,
  19. unsigned long arg)
  20. {
  21. return -EINVAL;
  22. }
  23. #endif
  24. #ifdef CONFIG_WEXT_PROC
  25. int wext_proc_init(struct net *net);
  26. void wext_proc_exit(struct net *net);
  27. #else
  28. static inline int wext_proc_init(struct net *net)
  29. {
  30. return 0;
  31. }
  32. static inline void wext_proc_exit(struct net *net)
  33. {
  34. return;
  35. }
  36. #endif
  37. #ifdef CONFIG_WEXT_PRIV
  38. int ioctl_private_call(struct net_device *dev, struct iwreq *iwr,
  39. unsigned int cmd, struct iw_request_info *info,
  40. iw_handler handler);
  41. int compat_private_call(struct net_device *dev, struct iwreq *iwr,
  42. unsigned int cmd, struct iw_request_info *info,
  43. iw_handler handler);
  44. int iw_handler_get_private(struct net_device * dev,
  45. struct iw_request_info * info,
  46. union iwreq_data * wrqu,
  47. char * extra);
  48. #else
  49. #define ioctl_private_call NULL
  50. #define compat_private_call NULL
  51. #endif
  52. #endif /* __NET_WEXT_H */