home *** CD-ROM | disk | FTP | other *** search
/ PC Welt 2006 November (DVD) / PCWELT_11_2006.ISO / casper / filesystem.squashfs / usr / src / linux-headers-2.6.17-6 / include / wlan / p80211ioctl.h < prev    next >
Encoding:
C/C++ Source or Header  |  2006-08-11  |  4.6 KB  |  124 lines

  1. /* src/include/wlan/p80211ioctl.h
  2. *
  3. * Declares constants and types for the p80211 ioctls
  4. *
  5. * Copyright (C) 1999 AbsoluteValue Systems, Inc.  All Rights Reserved.
  6. * --------------------------------------------------------------------
  7. *
  8. * linux-wlan
  9. *
  10. *   The contents of this file are subject to the Mozilla Public
  11. *   License Version 1.1 (the "License"); you may not use this file
  12. *   except in compliance with the License. You may obtain a copy of
  13. *   the License at http://www.mozilla.org/MPL/
  14. *
  15. *   Software distributed under the License is distributed on an "AS
  16. *   IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
  17. *   implied. See the License for the specific language governing
  18. *   rights and limitations under the License.
  19. *
  20. *   Alternatively, the contents of this file may be used under the
  21. *   terms of the GNU Public License version 2 (the "GPL"), in which
  22. *   case the provisions of the GPL are applicable instead of the
  23. *   above.  If you wish to allow the use of your version of this file
  24. *   only under the terms of the GPL and not to allow others to use
  25. *   your version of this file under the MPL, indicate your decision
  26. *   by deleting the provisions above and replace them with the notice
  27. *   and other provisions required by the GPL.  If you do not delete
  28. *   the provisions above, a recipient may use your version of this
  29. *   file under either the MPL or the GPL.
  30. *
  31. * --------------------------------------------------------------------
  32. *
  33. * Inquiries regarding the linux-wlan Open Source project can be
  34. * made directly to:
  35. *
  36. * AbsoluteValue Systems Inc.
  37. * info@linux-wlan.com
  38. * http://www.linux-wlan.com
  39. *
  40. * --------------------------------------------------------------------
  41. *
  42. * Portions of the development of this software were funded by 
  43. * Intersil Corporation as part of PRISM(R) chipset product development.
  44. *
  45. * --------------------------------------------------------------------
  46. *
  47. *  While this file is called 'ioctl' is purpose goes a little beyond
  48. *  that.  This file defines the types and contants used to implement
  49. *  the p80211 request/confirm/indicate interfaces on Linux.  The
  50. *  request/confirm interface is, in fact, normally implemented as an
  51. *  ioctl.  The indicate interface on the other hand, is implemented
  52. *  using the Linux 'netlink' interface.
  53. *
  54. *  The reason I say that request/confirm is 'normally' implemented 
  55. *  via ioctl is that we're reserving the right to be able to send 
  56. *  request commands via the netlink interface.  This will be necessary
  57. *  if we ever need to send request messages when there aren't any
  58. *  wlan network devices present (i.e. sending a message that only p80211
  59. *  cares about.
  60. * --------------------------------------------------------------------
  61. */
  62.  
  63.  
  64. #ifndef _P80211IOCTL_H
  65. #define _P80211IOCTL_H
  66.  
  67. /*================================================================*/
  68. /* Constants */
  69.  
  70. /*----------------------------------------------------------------*/
  71. /* p80211 ioctl "request" codes.  See argument 2 of ioctl(2). */
  72.  
  73. #define P80211_IFTEST        (SIOCDEVPRIVATE + 0)
  74. #define P80211_IFREQ        (SIOCDEVPRIVATE + 1)
  75.  
  76. /*----------------------------------------------------------------*/
  77. /* Magic number, a quick test to see we're getting the desired struct */
  78.  
  79. #define P80211_IOCTL_MAGIC    (0x4a2d464dUL)
  80.  
  81. /*----------------------------------------------------------------*/
  82. /* Netlink protocol numbers for the indication interface */
  83.  
  84. #define P80211_NL_SOCK_IND    NETLINK_USERSOCK
  85.  
  86. /*----------------------------------------------------------------*/
  87. /* Netlink multicast bits for different types of messages */
  88.  
  89. #define P80211_NL_MCAST_GRP_MLME    BIT0    /* Local station messages */
  90. #define P80211_NL_MCAST_GRP_SNIFF    BIT1    /* Sniffer messages */
  91. #define P80211_NL_MCAST_GRP_DIST    BIT2    /* Distribution system messages */
  92.  
  93. /*================================================================*/
  94. /* Macros */
  95.  
  96.  
  97. /*================================================================*/
  98. /* Types */
  99.  
  100. /*----------------------------------------------------------------*/
  101. /* A ptr to the following structure type is passed as the third */
  102. /*  argument to the ioctl system call when issuing a request to */
  103. /*  the p80211 module. */
  104.  
  105. typedef struct p80211ioctl_req
  106. {
  107.     char     name[WLAN_DEVNAMELEN_MAX]    __WLAN_ATTRIB_PACK__;
  108.     caddr_t data                            __WLAN_ATTRIB_PACK__;
  109.     UINT32    magic                __WLAN_ATTRIB_PACK__;
  110.     UINT16    len                __WLAN_ATTRIB_PACK__;
  111.     UINT32    result                __WLAN_ATTRIB_PACK__;
  112. } __WLAN_ATTRIB_PACK__ p80211ioctl_req_t;
  113.  
  114.  
  115. /*================================================================*/
  116. /* Extern Declarations */
  117.  
  118.  
  119. /*================================================================*/
  120. /* Function Declarations */
  121.  
  122.  
  123. #endif /* _P80211IOCTL_H */
  124.