Source code of Windows XP (NT5)
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.

309 lines
4.2 KiB

  1. /*++
  2. Copyright (c) 1991 Microsoft Corporation
  3. Module Name:
  4. sh_proto.h
  5. Abstract:
  6. This header file contains the prototypes of the functions that are
  7. local to this directory. Non-local items go to ..\inc.
  8. Author:
  9. Eric Chin (ericc) September 29, 1992
  10. Revision History:
  11. --*/
  12. #ifndef _SH_PROTO_
  13. #define _SH_PROTO_
  14. //
  15. // Stream Head Driver Dispatch Functions
  16. //
  17. NTSTATUS
  18. SHDispFdInsert(
  19. IN PIRP irp,
  20. IN PIO_STACK_LOCATION irpsp
  21. );
  22. NTSTATUS
  23. SHDispGetMsg (
  24. IN PIRP irp,
  25. IN PIO_STACK_LOCATION irpsp
  26. );
  27. NTSTATUS
  28. SHDispIoctl (
  29. IN PIRP irp,
  30. IN PIO_STACK_LOCATION irpsp
  31. );
  32. NTSTATUS
  33. SHDispIStr(
  34. IN PIRP irp
  35. );
  36. NTSTATUS
  37. SHDispPoll (
  38. IN PIRP irp,
  39. IN PIO_STACK_LOCATION irpsp
  40. );
  41. NTSTATUS
  42. SHDispPutMsg (
  43. IN PIRP irp,
  44. IN PIO_STACK_LOCATION irpsp
  45. );
  46. //
  47. // Private Function Prototypes
  48. //
  49. NTSTATUS
  50. SHpCloseDelay (
  51. IN strm_t *stream
  52. );
  53. VOID
  54. SHpCloseRun (
  55. VOID
  56. );
  57. VOID
  58. SHpUnlinkRun (
  59. VOID
  60. );
  61. NTSTATUS
  62. SHpCloseStream (
  63. IN PIRP irp
  64. );
  65. VOID
  66. SHpGenReply(
  67. IN PIRP irp,
  68. IN int retval,
  69. IN int MyErrno
  70. );
  71. NTSTATUS
  72. SHpOpenStream (
  73. IN PIRP irp,
  74. IN dev_t sdevno
  75. );
  76. NTSTATUS
  77. StrmpCreateThreads(
  78. VOID
  79. );
  80. NTSTATUS
  81. StrmpTerminateThreads(
  82. VOID
  83. );
  84. NTSTATUS
  85. do_link(
  86. IN PIRP irp,
  87. IN char *inbuf,
  88. IN ULONG nbytes,
  89. OUT int *pretval,
  90. OUT int *pMyErrno
  91. );
  92. NTSTATUS
  93. do_poll(
  94. IN PIRP irp,
  95. IN OUT char *inbuf,
  96. IN ULONG nbytes,
  97. OUT int *pretval,
  98. OUT int *pMyErrno
  99. );
  100. NTSTATUS
  101. do_push(
  102. IN PIRP irp,
  103. IN char *name,
  104. IN ULONG nbytes,
  105. OUT int *pretval,
  106. OUT int *pMyErrno
  107. );
  108. NTSTATUS
  109. do_sdebug(
  110. IN PIRP irp,
  111. IN PFILE_OBJECT pfileobj,
  112. IN char *inbuf,
  113. IN ULONG nbytes,
  114. OUT int *pretval,
  115. OUT int *pMyErrno
  116. );
  117. NTSTATUS
  118. do_unlink(
  119. IN PIRP irp,
  120. IN char *inbuf,
  121. IN ULONG nbytes,
  122. OUT int *pretval,
  123. OUT int *pMyErrno
  124. );
  125. NTSTATUS
  126. init_poll(
  127. VOID
  128. );
  129. NTSTATUS
  130. init_u(
  131. VOID
  132. );
  133. void
  134. iocrdy(
  135. IN PSTREAM_ENDPOINT ms,
  136. IN mblk_t *mp,
  137. IN int *spl_levelp
  138. );
  139. int
  140. iocreply(
  141. IN mblk_t *mp,
  142. IN PIRP irp
  143. );
  144. mblk_t *
  145. irptomp(
  146. IN PIRP irp,
  147. IN int pri,
  148. IN int ctlsize,
  149. IN int datasize,
  150. IN char *mbuf
  151. );
  152. void
  153. msgrdy(
  154. IN struct msg_strm *ms,
  155. IN int mtype
  156. );
  157. int
  158. msgreply(
  159. IN STREAM_ENDPOINT *ms,
  160. IN PIRP irp
  161. );
  162. int
  163. shopen(
  164. IN int dev,
  165. IN int flag,
  166. IN strm_t **sp,
  167. IN caddr_t handle
  168. );
  169. int
  170. shortreply(
  171. IN PIRP irp,
  172. IN int status,
  173. IN int nbytes
  174. );
  175. int
  176. shrange(
  177. IN strm_t *strm,
  178. IN int ctlsize,
  179. IN int datasize
  180. );
  181. int
  182. shready(
  183. IN strm_t *strm,
  184. IN int pri
  185. );
  186. int
  187. shtype(
  188. IN strm_t *strm
  189. );
  190. void
  191. shwsrv(
  192. IN struct msg_strm *ms
  193. );
  194. void
  195. sigevent(
  196. IN char *cp,
  197. IN int signo
  198. );
  199. int
  200. st_getmsg(
  201. IN strm_t *s,
  202. IN int datasize,
  203. IN int ctlsize,
  204. IN OUT int *flags,
  205. IN OUT int *more,
  206. OUT mblk_t **mpp,
  207. OUT int *remains
  208. );
  209. void
  210. st_putback(
  211. IN strm_t *s,
  212. IN mblk_t *mp,
  213. IN int remains
  214. );
  215. void
  216. strmevent(
  217. IN PSTREAM_ENDPOINT ms,
  218. IN int rerror,
  219. IN int werror,
  220. IN int type
  221. );
  222. void
  223. stropts(
  224. IN char *cp,
  225. IN struct stroptions *opts
  226. );
  227. int
  228. st_getmsg(
  229. IN strm_t *s,
  230. IN int datasize,
  231. IN int ctlsize,
  232. IN OUT int *flags,
  233. IN OUT int *more,
  234. OUT mblk_t **mpp,
  235. OUT int *remains
  236. );
  237. void
  238. st_putback(
  239. IN strm_t *s,
  240. IN mblk_t *mp,
  241. IN int remains
  242. );
  243. void
  244. trypoll(
  245. );
  246. STATIC int
  247. mptoirp(
  248. IN mblk_t *mp,
  249. IN PIRP irp
  250. );
  251. #endif /* _SH_PROTO_ */