Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

242 lines
5.5 KiB

  1. /****************************************************************************
  2. Copyright (c) 2000 Microsoft Corporation
  3. Module Name:
  4. bthioctl.h
  5. Abstract:
  6. defines the IOCTL codes for the kernel/user calls
  7. Environment:
  8. Kernel & user mode
  9. Revision History:
  10. 4-4-00 : created by Husni Roukbi
  11. ****************************************************************************/
  12. #ifndef __BTHIOCTL_H__
  13. #define __BTHIOCTL_H__
  14. #ifndef CTL_CODE
  15. #pragma message("CTL_CODE undefined. Include winioctl.h or wdm.h")
  16. #endif
  17. // IOCTL defines
  18. //
  19. #define BTH_IOCTL_BASE 1000
  20. #define FILE_DEVICE_BLUETOOTH FILE_DEVICE_UNKNOWN
  21. #define BTH_CTL(id) CTL_CODE(FILE_DEVICE_BLUETOOTH, \
  22. (id), \
  23. METHOD_BUFFERED, \
  24. FILE_ANY_ACCESS)
  25. #define BTH_KERNEL_CTL(id) CTL_CODE(FILE_DEVICE_BLUETOOTH, \
  26. (id), \
  27. METHOD_NEITHER, \
  28. FILE_ANY_ACCESS)
  29. //
  30. // kernel-level IOCTLs
  31. //
  32. #define IOCTL_INTERNAL_BTH_SUBMIT_BRB BTH_KERNEL_CTL(BTH_IOCTL_BASE+0)
  33. //
  34. // Input: none
  35. // Output: BTH_ENUMERATOR_INFO
  36. //
  37. #define IOCTL_INTERNAL_BTHENUM_GET_ENUMINFO BTH_KERNEL_CTL(BTH_IOCTL_BASE+1)
  38. //
  39. // Input: none
  40. // Output: BTH_DEVICE_INFO
  41. //
  42. #define IOCTL_INTERNAL_BTHENUM_GET_DEVINFO BTH_KERNEL_CTL(BTH_IOCTL_BASE+2)
  43. //
  44. // user-level IOCTLs
  45. //
  46. //
  47. // use this ioctl to get a list of cached discovered devices in the port driver.
  48. //
  49. #define IOCTL_BTH_GET_DEVICE_INFO BTH_CTL(BTH_IOCTL_BASE+1)
  50. //
  51. // use this ioctl to start a new device discovery.
  52. //
  53. #define IOCTL_BTH_INQUIRY_DEVICE BTH_CTL(BTH_IOCTL_BASE+2)
  54. //
  55. // Input: HANDLE_SDP
  56. // Output: SDP_ERROR
  57. //
  58. #define IOCTL_BTH_SDP_GET_LAST_ERROR \
  59. BTH_CTL(BTH_IOCTL_BASE+3)
  60. //
  61. // Input: BTH_SDP_CONNECT
  62. // Output: BTH_SDP_CONNECT
  63. //
  64. //
  65. #define IOCTL_BTH_SDP_CONNECT BTH_CTL(BTH_IOCTL_BASE+4)
  66. //
  67. // Input: HANDLE_SDP
  68. // Output: none
  69. //
  70. #define IOCTL_BTH_SDP_DISCONNECT BTH_CTL(BTH_IOCTL_BASE+5)
  71. //
  72. // Input: BTH_SDP_SERVICE_SEARCH_REQUEST
  73. // Output: ULONG * number of handles wanted
  74. //
  75. #define IOCTL_BTH_SDP_SERVICE_SEARCH \
  76. BTH_CTL(BTH_IOCTL_BASE+6)
  77. //
  78. // Input: BTH_SDP_ATTRIBUTE_SEARCH_REQUEST
  79. // Output: BTH_SDP_STREAM_RESPONSE or bigger
  80. //
  81. #define IOCTL_BTH_SDP_ATTRIBUTE_SEARCH \
  82. BTH_CTL(BTH_IOCTL_BASE+7)
  83. //
  84. // Input: BTH_SDP_SERVICE_ATTRIBUTE_SEARCH_REQUEST
  85. // Output: BTH_SDP_STREAM_RESPONSE or bigger
  86. //
  87. #define IOCTL_BTH_SDP_SERVICE_ATTRIBUTE_SEARCH \
  88. BTH_CTL(BTH_IOCTL_BASE+8)
  89. //
  90. // Input: raw SDP stream (at least 2 bytes)
  91. // Ouptut: HANDLE_SDP
  92. //
  93. #define IOCTL_BTH_SDP_SUBMIT_RECORD BTH_CTL(BTH_IOCTL_BASE+9)
  94. // BTH_CTL(BTH_IOCTL_BASE+10)
  95. //
  96. // Input: HANDLE_SDP
  97. // Output: none
  98. //
  99. #define IOCTL_BTH_SDP_REMOVE_RECORD BTH_CTL(BTH_IOCTL_BASE+11)
  100. //
  101. // Input: BTH_AUTHENTICATE_RESPONSE
  102. // Output: BTHSTATUS
  103. //
  104. #define IOCTL_BTH_PIN_RESPONSE BTH_CTL(BTH_IOCTL_BASE+12)
  105. //
  106. // Input: ULONG
  107. // Output: none
  108. //
  109. #define IOCTL_BTH_UPDATE_SETTINGS BTH_CTL(BTH_IOCTL_BASE+13)
  110. //
  111. // Input: none
  112. // Output: BTH_LOCAL_RADIO_INFO
  113. //
  114. #define IOCTL_BTH_GET_LOCAL_INFO BTH_CTL(BTH_IOCTL_BASE+14)
  115. //
  116. // Input: BTH_ADDR
  117. // Output: none
  118. //
  119. #define IOCTL_BTH_DISCONNECT_DEVICE BTH_CTL(BTH_IOCTL_BASE+15)
  120. // BTH_CTL(BTH_IOCTL_BASE+16)
  121. //
  122. // Input: BTH_ADDR
  123. // Output: BTH_RADIO_INFO
  124. //
  125. #define IOCTL_BTH_GET_RADIO_INFO BTH_CTL(BTH_IOCTL_BASE+17)
  126. //
  127. // Input: BTH_AUTHENTICATE_DEVICE
  128. // Output: BTHSTATUS
  129. //
  130. #define IOCTL_BTH_PAIR_DEVICE BTH_CTL(BTH_IOCTL_BASE+18)
  131. //
  132. // Input: BTH_ADDR
  133. // Ouptut: none
  134. //
  135. #define IOCTL_BTH_UNPAIR_DEVICE BTH_CTL(BTH_IOCTL_BASE+19)
  136. //
  137. // Input: 1 or 2 ULONGs
  138. // Ouptut: 1 or 2 ULONGs
  139. //
  140. #define IOCTL_BTH_DEBUG_LEVEL BTH_CTL(BTH_IOCTL_BASE+20)
  141. //
  142. // Input: BTH_SDP_RECORD + raw SDP record
  143. // Output: HANDLE_SDP
  144. //
  145. #define IOCTL_BTH_SDP_SUBMIT_RECORD_WITH_INFO BTH_CTL(BTH_IOCTL_BASE+21)
  146. //
  147. // Input: UCHAR
  148. // Output: none
  149. //
  150. #define IOCTL_BTH_SCAN_ENABLE BTH_CTL(BTH_IOCTL_BASE+22)
  151. //
  152. // Input: none
  153. // Output: BTH_PERF_STATS
  154. //
  155. #define IOCTL_BTH_GET_PERF BTH_CTL(BTH_IOCTL_BASE+23)
  156. //
  157. // Input: none
  158. // Output: none
  159. //
  160. #define IOCTL_BTH_RESET_PERF BTH_CTL(BTH_IOCTL_BASE+24)
  161. //
  162. // Input: BTH_DEVICE_UPDATE
  163. // Output:
  164. //
  165. #define IOCTL_BTH_UPDATE_DEVICE BTH_CTL(BTH_IOCTL_BASE+25)
  166. //
  167. // Input: BTH_ADDR
  168. // Output: BTH_DEVICE_PROTOCOLS_LIST + n * GUID
  169. //
  170. #define IOCTL_BTH_GET_DEVICE_PROTOCOLS \
  171. BTH_CTL(BTH_IOCTL_BASE+26)
  172. // BTH_CTL(BTH_IOCTL_BASE+27)
  173. //
  174. // Input: BTH_ADDR
  175. // Output: none
  176. //
  177. #define IOCTL_BTH_PERSONALIZE_DEVICE \
  178. BTH_CTL(BTH_IOCTL_BASE+28)
  179. //
  180. // UPF ONLY
  181. // Input: BTH_ADDR
  182. // Output: UCHAR
  183. //
  184. #define IOCTL_BTH_GET_CONNECTION_ROLE \
  185. BTH_CTL(BTH_IOCTL_BASE+29)
  186. //
  187. // UPF ONLY
  188. // Input: BTH_SET_CONNECTION_ROLE
  189. // Output: none
  190. //
  191. #define IOCTL_BTH_SET_CONNECTION_ROLE \
  192. BTH_CTL(BTH_IOCTL_BASE+30)
  193. #endif // __BTHIOCTL_H__