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.

1339 lines
21 KiB

  1. /*++
  2. Copyright (c) 1997 FORE Systems, Inc.
  3. Copyright (c) 1997 Microsoft Corporation
  4. Module Name:
  5. externs.h
  6. Abstract:
  7. All external declarations for ATMLANE modules (functions,
  8. variables) are here.
  9. Revision History:
  10. Notes:
  11. --*/
  12. #ifndef __ATMLANE_EXTERNS_H
  13. #define __ATMLANE_EXTERNS_H
  14. #ifndef EXTERN
  15. #define EXTERN extern
  16. #endif // EXTERN
  17. //
  18. // --------------- From adapter.c ----------------------------
  19. //
  20. #if 0
  21. EXTERN VOID Adapter();
  22. #endif
  23. EXTERN
  24. NDIS_STATUS
  25. AtmLanePnPEventHandler(
  26. IN NDIS_HANDLE ProtocolBindingContext,
  27. IN PNET_PNP_EVENT NetPnPEvent
  28. );
  29. EXTERN
  30. VOID
  31. AtmLaneBindAdapterHandler(
  32. OUT PNDIS_STATUS pStatus,
  33. IN NDIS_HANDLE BindContext,
  34. IN PNDIS_STRING pDeviceName,
  35. IN PVOID SystemSpecific1,
  36. IN PVOID SystemSpecific2
  37. );
  38. EXTERN
  39. VOID
  40. AtmLaneUnbindAdapterHandler(
  41. OUT PNDIS_STATUS Status,
  42. IN NDIS_HANDLE ProtocolBindingContext,
  43. IN NDIS_HANDLE UnbindContext
  44. );
  45. EXTERN
  46. VOID
  47. AtmLaneCompleteUnbindAdapter(
  48. IN PATMLANE_ADAPTER pAdapter
  49. );
  50. EXTERN
  51. VOID
  52. AtmLaneOpenAdapterCompleteHandler(
  53. IN NDIS_HANDLE ProtocolBindingContext,
  54. IN NDIS_STATUS Status,
  55. IN NDIS_STATUS OpenErrorStatus
  56. );
  57. EXTERN
  58. VOID
  59. AtmLaneCloseAdapterCompleteHandler(
  60. IN NDIS_HANDLE ProtocolBindingContext,
  61. IN NDIS_STATUS Status
  62. );
  63. EXTERN
  64. VOID
  65. AtmLaneSendCompleteHandler(
  66. IN NDIS_HANDLE ProtocolBindingContext,
  67. IN PNDIS_PACKET Packet,
  68. IN NDIS_STATUS Status
  69. );
  70. EXTERN
  71. VOID
  72. AtmLaneTransferDataCompleteHandler(
  73. IN NDIS_HANDLE ProtocolBindingContext,
  74. IN PNDIS_PACKET Packet,
  75. IN NDIS_STATUS Status,
  76. IN UINT BytesTransferred
  77. );
  78. EXTERN
  79. NDIS_STATUS
  80. AtmLaneReceiveHandler(
  81. IN NDIS_HANDLE ProtocolBindingContext,
  82. IN NDIS_HANDLE MacReceiveContext,
  83. IN PVOID HeaderBuffer,
  84. IN UINT HeaderBufferSize,
  85. IN PVOID LookAheadBuffer,
  86. IN UINT LookaheadBufferSize,
  87. IN UINT PacketSize
  88. );
  89. EXTERN
  90. VOID
  91. AtmLaneResetCompleteHandler(
  92. IN NDIS_HANDLE ProtocolBindingContext,
  93. IN NDIS_STATUS Status
  94. );
  95. EXTERN
  96. VOID
  97. AtmLaneRequestCompleteHandler(
  98. IN NDIS_HANDLE ProtocolBindingContext,
  99. IN PNDIS_REQUEST pNdisRequest,
  100. IN NDIS_STATUS Status
  101. );
  102. EXTERN
  103. VOID
  104. AtmLaneReceiveCompleteHandler(
  105. IN NDIS_HANDLE ProtocolBindingContext
  106. );
  107. EXTERN
  108. VOID
  109. AtmLaneStatusHandler(
  110. IN NDIS_HANDLE ProtocolBindingContext,
  111. IN NDIS_STATUS GeneralStatus,
  112. IN PVOID pStatusBuffer,
  113. IN UINT StatusBufferSize
  114. );
  115. EXTERN
  116. VOID
  117. AtmLaneStatusCompleteHandler(
  118. IN NDIS_HANDLE ProtocolBindingContext
  119. );
  120. EXTERN
  121. VOID
  122. AtmLaneCoSendCompleteHandler(
  123. IN NDIS_STATUS Status,
  124. IN NDIS_HANDLE ProtocolVcContext,
  125. IN PNDIS_PACKET pNdisPacket
  126. );
  127. EXTERN
  128. VOID
  129. AtmLaneCoStatusHandler(
  130. IN NDIS_HANDLE ProtocolBindingContext,
  131. IN NDIS_HANDLE ProtocolVcContext OPTIONAL,
  132. IN NDIS_STATUS GeneralStatus,
  133. IN PVOID pStatusBuffer,
  134. IN UINT StatusBufferSize
  135. );
  136. EXTERN
  137. NDIS_STATUS
  138. AtmLaneSendAdapterNdisRequest(
  139. IN PATMLANE_ADAPTER pAdapter,
  140. IN PNDIS_REQUEST pNdisRequest,
  141. IN NDIS_REQUEST_TYPE RequestType,
  142. IN NDIS_OID Oid,
  143. IN PVOID pBuffer,
  144. IN ULONG BufferLength
  145. );
  146. EXTERN
  147. VOID
  148. AtmLaneGetAdapterInfo(
  149. IN PATMLANE_ADAPTER pAdapter
  150. );
  151. EXTERN
  152. UINT
  153. AtmLaneCoReceivePacketHandler(
  154. IN NDIS_HANDLE ProtocolBindingContext,
  155. IN NDIS_HANDLE ProtocolVcContext,
  156. IN PNDIS_PACKET pNdisPacket
  157. );
  158. EXTERN
  159. VOID
  160. AtmLaneUnloadProtocol(
  161. VOID
  162. );
  163. EXTERN
  164. BOOLEAN
  165. AtmLaneIsDeviceAlreadyBound(
  166. IN PNDIS_STRING pDeviceName
  167. );
  168. //
  169. // --------------- From callmgr.c ----------------------------
  170. //
  171. #if 0
  172. EXTERN VOID CallMgr();
  173. #endif
  174. EXTERN
  175. VOID
  176. AtmLaneAfRegisterNotifyHandler(
  177. IN NDIS_HANDLE ProtocolBindingContext,
  178. IN PCO_ADDRESS_FAMILY pAddressFamily
  179. );
  180. EXTERN
  181. NDIS_STATUS
  182. AtmLaneOpenCallMgr(
  183. IN PATMLANE_ELAN pElan
  184. );
  185. EXTERN
  186. VOID
  187. AtmLaneOpenAfCompleteHandler(
  188. IN NDIS_STATUS Status,
  189. IN NDIS_HANDLE ProtocolAfContext,
  190. IN NDIS_HANDLE NdisAfHandle
  191. );
  192. EXTERN
  193. VOID
  194. AtmLaneCloseAfCompleteHandler(
  195. IN NDIS_STATUS Status,
  196. IN NDIS_HANDLE ProtocolAfContext
  197. );
  198. EXTERN
  199. VOID
  200. AtmLaneRegisterSaps(
  201. IN PATMLANE_ELAN pElan
  202. );
  203. EXTERN
  204. VOID
  205. AtmLaneDeregisterSaps(
  206. IN PATMLANE_ELAN pElan
  207. );
  208. EXTERN
  209. VOID
  210. AtmLaneRegisterSaps(
  211. IN PATMLANE_ELAN pElan
  212. );
  213. EXTERN
  214. NDIS_STATUS
  215. AtmLaneMakeCall(
  216. IN PATMLANE_ELAN pElan,
  217. IN PATMLANE_ATM_ENTRY pAtmEntry,
  218. IN BOOLEAN UsePvc
  219. );
  220. EXTERN
  221. VOID
  222. AtmLaneCloseCall(
  223. IN PATMLANE_VC pVc
  224. );
  225. EXTERN
  226. NDIS_STATUS
  227. AtmLaneCreateVcHandler(
  228. IN NDIS_HANDLE ProtocolAfContext,
  229. IN NDIS_HANDLE NdisVcHandle,
  230. OUT PNDIS_HANDLE pProtocolVcContext
  231. );
  232. EXTERN
  233. NDIS_STATUS
  234. AtmLaneDeleteVcHandler(
  235. IN NDIS_HANDLE ProtocolVcContext
  236. );
  237. EXTERN
  238. NDIS_STATUS
  239. AtmLaneIncomingCallHandler(
  240. IN NDIS_HANDLE ProtocolSapContext,
  241. IN NDIS_HANDLE ProtocolVcContext,
  242. IN OUT PCO_CALL_PARAMETERS pCallParameters
  243. );
  244. EXTERN
  245. VOID
  246. AtmLaneCallConnectedHandler(
  247. IN NDIS_HANDLE ProtocolVcContext
  248. );
  249. EXTERN
  250. VOID
  251. AtmLaneIncomingCloseHandler(
  252. IN NDIS_STATUS CloseStatus,
  253. IN NDIS_HANDLE ProtocolVcContext,
  254. IN PVOID pCloseData OPTIONAL,
  255. IN UINT Size OPTIONAL
  256. );
  257. EXTERN
  258. VOID
  259. AtmLaneIncomingDropPartyHandler(
  260. IN NDIS_STATUS DropStatus,
  261. IN NDIS_HANDLE ProtocolPartyContext,
  262. IN PVOID pCloseData OPTIONAL,
  263. IN UINT Size OPTIONAL
  264. );
  265. EXTERN
  266. VOID
  267. AtmLaneQosChangeHandler(
  268. IN NDIS_HANDLE ProtocolVcContext,
  269. IN PCO_CALL_PARAMETERS pCallParameters
  270. );
  271. EXTERN
  272. VOID
  273. AtmLaneRegisterSapCompleteHandler(
  274. IN NDIS_STATUS Status,
  275. IN NDIS_HANDLE ProtocolSapContext,
  276. IN PCO_SAP pSap,
  277. IN NDIS_HANDLE NdisSapHandle
  278. );
  279. EXTERN
  280. VOID
  281. AtmLaneDeregisterSapCompleteHandler(
  282. IN NDIS_STATUS Status,
  283. IN NDIS_HANDLE ProtocolSapContext
  284. );
  285. EXTERN
  286. VOID
  287. AtmLaneMakeCallCompleteHandler(
  288. IN NDIS_STATUS Status,
  289. IN NDIS_HANDLE ProtocolVcContext,
  290. IN NDIS_HANDLE NdisPartyHandle OPTIONAL,
  291. IN PCO_CALL_PARAMETERS pCallParameters
  292. );
  293. EXTERN
  294. VOID
  295. AtmLaneCloseCallCompleteHandler(
  296. IN NDIS_STATUS Status,
  297. IN NDIS_HANDLE ProtocolVcContext,
  298. IN NDIS_HANDLE ProtocolPartyContext OPTIONAL
  299. );
  300. EXTERN
  301. VOID
  302. AtmLaneAddPartyCompleteHandler(
  303. IN NDIS_STATUS Status,
  304. IN NDIS_HANDLE ProtocolPartyContext,
  305. IN NDIS_HANDLE NdisPartyHandle,
  306. IN PCO_CALL_PARAMETERS pCallParameters
  307. );
  308. EXTERN
  309. VOID
  310. AtmLaneDropPartyCompleteHandler(
  311. IN NDIS_STATUS Status,
  312. IN NDIS_HANDLE ProtocolPartyContext
  313. );
  314. EXTERN
  315. VOID
  316. AtmLaneModifyQosCompleteHandler(
  317. IN NDIS_STATUS Status,
  318. IN NDIS_HANDLE ProtocolVcContext,
  319. IN PCO_CALL_PARAMETERS pCallParameters
  320. );
  321. EXTERN
  322. NDIS_STATUS
  323. AtmLaneSendNdisCoRequest(
  324. IN NDIS_HANDLE NdisAdapterHandle,
  325. IN NDIS_HANDLE NdisAfHandle,
  326. IN PNDIS_REQUEST pNdisRequest,
  327. IN NDIS_REQUEST_TYPE RequestType,
  328. IN NDIS_OID Oid,
  329. IN PVOID pBuffer,
  330. IN ULONG BufferLength
  331. );
  332. EXTERN
  333. NDIS_STATUS
  334. AtmLaneCoRequestHandler(
  335. IN NDIS_HANDLE ProtocolAfContext,
  336. IN NDIS_HANDLE ProtocolVcContext OPTIONAL,
  337. IN NDIS_HANDLE ProtocolPartyContext OPTIONAL,
  338. IN OUT PNDIS_REQUEST pNdisRequest
  339. );
  340. EXTERN
  341. VOID
  342. AtmLaneCoRequestCompleteHandler(
  343. IN NDIS_STATUS Status,
  344. IN NDIS_HANDLE ProtocolAfContext,
  345. IN NDIS_HANDLE ProtocolVcContext OPTIONAL,
  346. IN NDIS_HANDLE ProtocolPartyContext OPTIONAL,
  347. IN PNDIS_REQUEST pNdisRequest
  348. );
  349. EXTERN
  350. NDIS_STATUS
  351. AtmLaneGetAtmAddress(
  352. IN PATMLANE_ELAN pElan
  353. );
  354. EXTERN
  355. VOID
  356. AtmLaneGetAtmAddressComplete(
  357. IN NDIS_STATUS Status,
  358. IN PATMLANE_ELAN pElan,
  359. IN PNDIS_REQUEST pNdisRequest
  360. );
  361. EXTERN
  362. NDIS_STATUS
  363. AtmLaneGetLecsIlmi(
  364. IN PATMLANE_ELAN pElan
  365. );
  366. EXTERN
  367. VOID
  368. AtmLaneGetLecsIlmiComplete(
  369. IN NDIS_STATUS Status,
  370. IN PATMLANE_ELAN pElan,
  371. IN PNDIS_REQUEST pNdisRequest
  372. );
  373. //
  374. // --------------- From elanpkt.c ----------------------------
  375. //
  376. #if 0
  377. EXTERN VOID ElanPkt();
  378. #endif
  379. EXTERN
  380. VOID
  381. AtmLaneSendConfigureRequest(
  382. IN PATMLANE_ELAN pElan LOCKIN NOLOCKOUT
  383. );
  384. EXTERN
  385. VOID
  386. AtmLaneSendJoinRequest(
  387. IN PATMLANE_ELAN pElan
  388. );
  389. EXTERN
  390. VOID
  391. AtmLaneSendArpRequest(
  392. IN PATMLANE_ELAN pElan,
  393. IN PATMLANE_MAC_ENTRY pMacEntry LOCKIN NOLOCKOUT
  394. );
  395. EXTERN
  396. VOID
  397. AtmLaneSendReadyQuery(
  398. IN PATMLANE_ELAN pElan,
  399. IN PATMLANE_VC pVc LOCKIN NOLOCKOUT
  400. );
  401. EXTERN
  402. VOID
  403. AtmLaneSendReadyIndication(
  404. IN PATMLANE_ELAN pElan,
  405. IN PATMLANE_VC pVc LOCKIN NOLOCKOUT
  406. );
  407. EXTERN
  408. VOID
  409. AtmLaneSendFlushRequest(
  410. IN PATMLANE_ELAN pElan,
  411. IN PATMLANE_MAC_ENTRY pMacEntry LOCKIN NOLOCKOUT,
  412. IN PATMLANE_ATM_ENTRY pAtmEntry
  413. );
  414. EXTERN
  415. VOID
  416. AtmLaneConfigureResponseHandler(
  417. IN PATMLANE_ELAN pElan,
  418. IN PATMLANE_VC pVc,
  419. IN PNDIS_PACKET pNdisPacket
  420. );
  421. EXTERN
  422. VOID
  423. AtmLaneControlPacketHandler(
  424. IN PATMLANE_ELAN pElan,
  425. IN PATMLANE_VC pVc,
  426. IN PNDIS_PACKET pNdisPacket
  427. );
  428. EXTERN
  429. VOID
  430. AtmLaneJoinResponseHandler(
  431. IN PATMLANE_ELAN pElan,
  432. IN PLANE_CONTROL_FRAME pCf
  433. );
  434. EXTERN
  435. VOID
  436. AtmLaneReadyQueryHandler(
  437. IN PATMLANE_ELAN pElan,
  438. IN PATMLANE_VC pVc,
  439. IN PNDIS_PACKET pQueryNdisPacket
  440. );
  441. EXTERN
  442. VOID
  443. AtmLaneFlushRequestHandler(
  444. IN PATMLANE_ELAN pElan,
  445. IN PNDIS_PACKET pRequestNdisPacket
  446. );
  447. EXTERN
  448. VOID
  449. AtmLaneArpRequestHandler(
  450. IN PATMLANE_ELAN pElan,
  451. IN PLANE_CONTROL_FRAME pCf
  452. );
  453. EXTERN
  454. VOID
  455. AtmLaneArpResponseHandler(
  456. IN PATMLANE_ELAN pElan,
  457. IN PLANE_CONTROL_FRAME pCf
  458. );
  459. EXTERN
  460. VOID
  461. AtmLaneFlushResponseHandler(
  462. IN PATMLANE_ELAN pElan,
  463. IN PLANE_CONTROL_FRAME pCf
  464. );
  465. EXTERN
  466. VOID
  467. AtmLaneReadyIndicationHandler(
  468. IN PATMLANE_ELAN pElan,
  469. IN PATMLANE_VC pVc,
  470. IN PNDIS_PACKET pIndNdisPacket
  471. );
  472. EXTERN
  473. VOID
  474. AtmLaneTopologyRequestHandler(
  475. IN PATMLANE_ELAN pElan,
  476. IN PLANE_CONTROL_FRAME pCf
  477. );
  478. EXTERN
  479. BOOLEAN
  480. AtmLaneDataPacketHandler(
  481. IN PATMLANE_ELAN pElan,
  482. IN PATMLANE_VC pVc,
  483. IN PNDIS_PACKET pNdisPacket
  484. );
  485. EXTERN
  486. VOID
  487. AtmLaneSendPacketOnVc(
  488. IN PATMLANE_VC pVc LOCKIN NOLOCKOUT,
  489. IN PNDIS_PACKET pNdisPacket,
  490. IN BOOLEAN Refresh
  491. );
  492. EXTERN
  493. VOID
  494. AtmLaneQueuePacketOnHead(
  495. IN PATMLANE_MAC_ENTRY pMacEntry,
  496. IN PNDIS_PACKET pNdisPacket
  497. );
  498. EXTERN
  499. VOID
  500. AtmLaneQueuePacketOnTail(
  501. IN PATMLANE_MAC_ENTRY pMacEntry,
  502. IN PNDIS_PACKET pNdisPacket
  503. );
  504. EXTERN
  505. PNDIS_PACKET
  506. AtmLaneDequeuePacketFromHead(
  507. IN PATMLANE_MAC_ENTRY pMacEntry
  508. );
  509. EXTERN
  510. NDIS_STATUS
  511. AtmLaneSendUnicastPacket(
  512. IN PATMLANE_ELAN pElan,
  513. IN ULONG DestAddrType,
  514. IN PMAC_ADDRESS pDestAddress,
  515. IN PNDIS_PACKET pNdisPacket
  516. );
  517. EXTERN
  518. VOID
  519. AtmLaneStartBusSends(
  520. IN PATMLANE_MAC_ENTRY pMacEntry LOCKIN NOLOCKOUT
  521. );
  522. EXTERN
  523. VOID
  524. AtmLaneDoBusSends(
  525. IN PATMLANE_MAC_ENTRY pMacEntry LOCKIN NOLOCKOUT
  526. );
  527. EXTERN
  528. VOID
  529. AtmLaneBusSendTimer(
  530. IN PVOID SystemSpecific1,
  531. IN PVOID pContext,
  532. IN PVOID SystemSpecific2,
  533. IN PVOID SystemSpecific3
  534. );
  535. EXTERN
  536. BOOLEAN
  537. AtmLaneOKToBusSend(
  538. IN PATMLANE_MAC_ENTRY pMacEntry
  539. );
  540. EXTERN
  541. VOID
  542. AtmLaneFreePacketQueue(
  543. IN PATMLANE_MAC_ENTRY pMacEntry,
  544. IN NDIS_STATUS Status
  545. );
  546. EXTERN
  547. VOID
  548. AtmLaneCompleteSendPacket(
  549. IN PATMLANE_ELAN pElan,
  550. IN PNDIS_PACKET pNdisPacket,
  551. IN NDIS_STATUS Status
  552. );
  553. EXTERN
  554. PWSTR
  555. AtmLaneMacAddrToString(
  556. IN VOID * pIn
  557. );
  558. EXTERN
  559. PWSTR
  560. AtmLaneAtmAddrToString(
  561. IN PATM_ADDRESS pIn
  562. );
  563. //
  564. // --------------- From elanproc.c ----------------------------
  565. //
  566. #if 0
  567. EXTERN VOID elanproc();
  568. #endif
  569. EXTERN
  570. VOID
  571. AtmLaneEventHandler(
  572. IN PNDIS_WORK_ITEM pWorkItem,
  573. IN PVOID pContext
  574. );
  575. EXTERN
  576. VOID
  577. AtmLaneBootStrapElans(
  578. IN PATMLANE_ADAPTER pAdapter
  579. );
  580. EXTERN
  581. NDIS_STATUS
  582. AtmLaneCreateElan(
  583. IN PATMLANE_ADAPTER pAdapter,
  584. IN PNDIS_STRING pElanKey,
  585. OUT PATMLANE_ELAN * ppElan
  586. );
  587. EXTERN
  588. NDIS_STATUS
  589. AtmLaneReconfigureHandler(
  590. IN PATMLANE_ADAPTER pAdapter,
  591. IN PNET_PNP_EVENT pNetPnPEvent
  592. );
  593. EXTERN
  594. PATMLANE_ELAN
  595. AtmLaneFindElan(
  596. IN PATMLANE_ADAPTER pAdapter,
  597. IN PNDIS_STRING pElanKey
  598. );
  599. EXTERN
  600. VOID
  601. AtmLaneConnectToServer(
  602. IN PATMLANE_ELAN pElan LOCKIN NOLOCKOUT,
  603. IN ULONG ServerType,
  604. IN BOOLEAN UsePvc
  605. );
  606. EXTERN
  607. VOID
  608. AtmLaneInvalidateAtmEntry(
  609. IN PATMLANE_ATM_ENTRY pAtmEntry LOCKIN NOLOCKOUT
  610. );
  611. EXTERN
  612. VOID
  613. AtmLaneCloseVCsOnAtmEntry(
  614. IN PATMLANE_ATM_ENTRY pAtmEntry LOCKIN NOLOCKOUT
  615. );
  616. EXTERN
  617. VOID
  618. AtmLaneGenerateMacAddr(
  619. PATMLANE_ELAN pElan
  620. );
  621. EXTERN
  622. PATMLANE_MAC_ENTRY
  623. AtmLaneSearchForMacAddress(
  624. PATMLANE_ELAN pElan,
  625. ULONG pMacAddrType,
  626. PMAC_ADDRESS pMacAddress,
  627. BOOLEAN CreateNew
  628. );
  629. EXTERN
  630. PATMLANE_ATM_ENTRY
  631. AtmLaneSearchForAtmAddress(
  632. IN PATMLANE_ELAN pElan,
  633. IN PUCHAR pAtmAddress,
  634. IN ULONG Type,
  635. IN BOOLEAN CreateNew
  636. );
  637. EXTERN
  638. ULONG
  639. AtmLaneMacAddrEqual(
  640. PMAC_ADDRESS pMacAddr1,
  641. PMAC_ADDRESS pMacAddr2
  642. );
  643. EXTERN
  644. VOID
  645. AtmLaneAbortMacEntry(
  646. IN PATMLANE_MAC_ENTRY pMacEntry
  647. );
  648. EXTERN
  649. VOID
  650. AtmLaneMacEntryAgingTimeout(
  651. IN PATMLANE_TIMER pTimer,
  652. IN PVOID Context
  653. );
  654. EXTERN
  655. VOID
  656. AtmLaneArpTimeout(
  657. IN PATMLANE_TIMER pTimer,
  658. IN PVOID Context
  659. );
  660. EXTERN
  661. VOID
  662. AtmLaneConfigureResponseTimeout(
  663. IN PATMLANE_TIMER pTimer,
  664. IN PVOID Context
  665. );
  666. EXTERN
  667. VOID
  668. AtmLaneJoinResponseTimeout(
  669. IN PATMLANE_TIMER pTimer,
  670. IN PVOID Context
  671. );
  672. EXTERN
  673. VOID
  674. AtmLaneInitializeMiniportDevice(
  675. IN PNDIS_WORK_ITEM NdisWorkItem,
  676. IN PVOID Context
  677. );
  678. EXTERN
  679. VOID
  680. AtmLaneReadyTimeout(
  681. IN PATMLANE_TIMER pTimer,
  682. IN PVOID Context
  683. );
  684. EXTERN
  685. VOID
  686. AtmLaneFlushTimeout(
  687. IN PATMLANE_TIMER pTimer,
  688. IN PVOID Context
  689. );
  690. EXTERN
  691. VOID
  692. AtmLaneVcAgingTimeout(
  693. IN PATMLANE_TIMER pTimer,
  694. IN PVOID Context
  695. );
  696. EXTERN
  697. VOID
  698. AtmLaneShutdownElan(
  699. IN PATMLANE_ELAN pElan LOCKIN NOLOCKOUT,
  700. IN BOOLEAN Restart
  701. );
  702. EXTERN
  703. VOID
  704. AtmLaneContinueShutdownElan(
  705. IN PATMLANE_ELAN pElan
  706. );
  707. EXTERN
  708. VOID
  709. AtmLaneGetProtocolConfiguration(
  710. IN NDIS_HANDLE AdapterConfigHandle,
  711. IN PATMLANE_ADAPTER pAdapter
  712. );
  713. EXTERN
  714. VOID
  715. AtmLaneGetElanConfiguration(
  716. IN NDIS_HANDLE ElanConfigHandle,
  717. IN PATMLANE_ELAN pElan
  718. );
  719. EXTERN
  720. VOID
  721. AtmLaneQueueElanEventAfterDelay(
  722. IN PATMLANE_ELAN pElan,
  723. IN ULONG Event,
  724. IN NDIS_STATUS EventStatus,
  725. IN ULONG DelayMs
  726. );
  727. EXTERN
  728. VOID
  729. AtmLaneQueueDelayedElanEvent(
  730. IN PVOID SystemSpecific1,
  731. IN PVOID TimerContext,
  732. IN PVOID SystemSpecific2,
  733. IN PVOID SystemSpecific3
  734. );
  735. EXTERN
  736. VOID
  737. AtmLaneQueueElanEvent(
  738. IN PATMLANE_ELAN pElan,
  739. IN ULONG Event,
  740. IN NDIS_STATUS EventStatus
  741. );
  742. EXTERN
  743. PATMLANE_EVENT
  744. AtmLaneDequeueElanEvent(
  745. IN PATMLANE_ELAN pElan
  746. );
  747. EXTERN
  748. VOID
  749. AtmLaneDrainElanEventQueue(
  750. IN PATMLANE_ELAN pElan
  751. );
  752. //
  753. // --------------- From miniport.c ----------------------------
  754. //
  755. #if 0
  756. EXTERN VOID Miniport();
  757. #endif
  758. EXTERN
  759. NDIS_STATUS
  760. AtmLaneMInitialize(
  761. OUT PNDIS_STATUS OpenErrorStatus,
  762. OUT PUINT SelectedMediumIndex,
  763. IN PNDIS_MEDIUM MediumArray,
  764. IN UINT MediumArraySize,
  765. IN NDIS_HANDLE MiniportAdapterHandle,
  766. IN NDIS_HANDLE WrapperConfigurationContext
  767. );
  768. EXTERN
  769. VOID
  770. AtmLaneMSendPackets(
  771. IN NDIS_HANDLE MiniportAdapterContext,
  772. IN PPNDIS_PACKET PacketArray,
  773. IN UINT NumberOfPackets
  774. );
  775. EXTERN
  776. VOID
  777. AtmLaneMReturnPacket(
  778. IN NDIS_HANDLE MiniportAdapterContext,
  779. IN PNDIS_PACKET Packet
  780. );
  781. EXTERN
  782. NDIS_STATUS
  783. AtmLaneMQueryInformation(
  784. IN NDIS_HANDLE MiniportAdapterContext,
  785. IN NDIS_OID Oid,
  786. IN PVOID InformationBuffer,
  787. IN ULONG InformationBufferLength,
  788. OUT PULONG BytesWritten,
  789. OUT PULONG BytesNeeded
  790. );
  791. EXTERN
  792. NDIS_STATUS
  793. AtmLaneMSetInformation(
  794. IN NDIS_HANDLE MiniportAdapterContext,
  795. IN NDIS_OID Oid,
  796. IN PVOID InformationBuffer,
  797. IN ULONG InformationBufferLength,
  798. OUT PULONG BytesRead,
  799. OUT PULONG BytesNeeded
  800. );
  801. EXTERN
  802. NDIS_STATUS
  803. AtmLaneMReset(
  804. OUT PBOOLEAN AddressingReset,
  805. IN NDIS_HANDLE MiniportAdapterContext
  806. );
  807. EXTERN
  808. VOID
  809. AtmLaneMHalt(
  810. IN NDIS_HANDLE MiniportAdapterContext
  811. );
  812. EXTERN
  813. PNDIS_PACKET
  814. AtmLaneWrapSendPacket(
  815. IN PATMLANE_ELAN pElan,
  816. IN PNDIS_PACKET pSendNdisPacket,
  817. OUT ULONG * pMacAddrType,
  818. OUT PMAC_ADDRESS pMacAddress,
  819. OUT BOOLEAN * pSendViaBUS
  820. );
  821. EXTERN
  822. PNDIS_PACKET
  823. AtmLaneUnwrapSendPacket(
  824. IN PATMLANE_ELAN pElan,
  825. IN PNDIS_PACKET pNdisPacket
  826. );
  827. EXTERN
  828. PNDIS_PACKET
  829. AtmLaneWrapRecvPacket(
  830. IN PATMLANE_ELAN pElan,
  831. IN PNDIS_PACKET pRecvNdisPacket,
  832. OUT ULONG * pMacHdrSize,
  833. OUT ULONG * pDestAddrType,
  834. OUT PMAC_ADDRESS pDestAddr,
  835. OUT BOOLEAN * pDestIsMulticast
  836. )
  837. ;
  838. EXTERN
  839. PNDIS_PACKET
  840. AtmLaneUnwrapRecvPacket(
  841. IN PATMLANE_ELAN pElan,
  842. IN PNDIS_PACKET pNdisPacket
  843. );
  844. EXTERN
  845. NDIS_STATUS
  846. AtmLaneMSetNetworkAddresses(
  847. IN PATMLANE_ELAN pElan,
  848. IN PVOID InformationBuffer,
  849. IN ULONG InformationBufferLength,
  850. OUT PULONG BytesRead,
  851. OUT PULONG BytesNeeded
  852. );
  853. //
  854. // --------------- From space.c ----------------------------
  855. //
  856. #if 0
  857. EXTERN VOID Space();
  858. #endif
  859. EXTERN PATMLANE_GLOBALS pAtmLaneGlobalInfo;
  860. EXTERN ATM_ADDRESS gWellKnownLecsAddress;
  861. EXTERN ATM_ADDRESS gWellKnownLecsAddress;
  862. EXTERN MAC_ADDRESS gMacBroadcastAddress;
  863. EXTERN ULONG AtmLaneMaxTimerValue[];
  864. EXTERN ULONG AtmLaneTimerListSize[];
  865. EXTERN ULONG AtmLaneTimerPeriod[];
  866. //
  867. // --------------- From utils.c ----------------------------
  868. //
  869. #if 0
  870. EXTERN VOID Utils();
  871. #endif
  872. EXTERN
  873. VOID
  874. AtmLaneInitGlobals(
  875. VOID
  876. );
  877. EXTERN
  878. PATMLANE_ADAPTER
  879. AtmLaneAllocAdapter(
  880. IN PNDIS_STRING pDeviceName,
  881. IN PVOID SystemSpecific1
  882. );
  883. EXTERN
  884. VOID
  885. AtmLaneDeallocateAdapter(
  886. IN PATMLANE_ADAPTER pAdapter
  887. );
  888. EXTERN
  889. BOOLEAN
  890. AtmLaneReferenceAdapter(
  891. IN PATMLANE_ADAPTER pAdapter,
  892. IN PUCHAR String
  893. );
  894. EXTERN
  895. ULONG
  896. AtmLaneDereferenceAdapter(
  897. IN PATMLANE_ADAPTER pAdapter,
  898. IN PUCHAR String
  899. );
  900. EXTERN
  901. NDIS_STATUS
  902. AtmLaneAllocElan(
  903. IN PATMLANE_ADAPTER pAdapter,
  904. IN OUT PATMLANE_ELAN *ppElan
  905. );
  906. EXTERN
  907. VOID
  908. AtmLaneDeallocateElan(
  909. IN PATMLANE_ELAN pElan
  910. );
  911. EXTERN
  912. VOID
  913. AtmLaneReferenceElan(
  914. IN PATMLANE_ELAN pElan,
  915. IN PUCHAR String
  916. );
  917. EXTERN
  918. ULONG
  919. AtmLaneDereferenceElan(
  920. IN PATMLANE_ELAN pElan,
  921. IN PUCHAR String
  922. );
  923. EXTERN
  924. VOID
  925. AtmLaneUnlinkElanFromAdapter(
  926. IN PATMLANE_ELAN pElan
  927. );
  928. EXTERN
  929. PATMLANE_ATM_ENTRY
  930. AtmLaneAllocateAtmEntry(
  931. IN PATMLANE_ELAN pElan
  932. );
  933. EXTERN
  934. VOID
  935. AtmLaneDeallocateAtmEntry(
  936. IN PATMLANE_ATM_ENTRY pAtmEntry
  937. );
  938. EXTERN
  939. VOID
  940. AtmLaneReferenceAtmEntry(
  941. IN PATMLANE_ATM_ENTRY pAtmEntry,
  942. IN PUCHAR String
  943. );
  944. EXTERN
  945. ULONG
  946. AtmLaneDereferenceAtmEntry(
  947. IN PATMLANE_ATM_ENTRY pAtmEntry,
  948. IN PUCHAR String
  949. );
  950. EXTERN
  951. PATMLANE_VC
  952. AtmLaneAllocateVc(
  953. IN PATMLANE_ELAN pElan
  954. );
  955. EXTERN
  956. VOID
  957. AtmLaneDeallocateVc(
  958. IN PATMLANE_VC pVc
  959. );
  960. EXTERN
  961. VOID
  962. AtmLaneReferenceVc(
  963. IN PATMLANE_VC pVc,
  964. IN PUCHAR String
  965. );
  966. EXTERN
  967. ULONG
  968. AtmLaneDereferenceVc(
  969. IN PATMLANE_VC pVc,
  970. IN PUCHAR String
  971. );
  972. EXTERN
  973. PATMLANE_MAC_ENTRY
  974. AtmLaneAllocateMacEntry(
  975. IN PATMLANE_ELAN pElan
  976. );
  977. EXTERN
  978. VOID
  979. AtmLaneDeallocateMacEntry(
  980. IN PATMLANE_MAC_ENTRY pMacEntry
  981. );
  982. EXTERN
  983. VOID
  984. AtmLaneReferenceMacEntry(
  985. IN PATMLANE_MAC_ENTRY pMacEntry,
  986. IN PUCHAR String
  987. );
  988. EXTERN
  989. ULONG
  990. AtmLaneDereferenceMacEntry(
  991. IN PATMLANE_MAC_ENTRY pMacEntry,
  992. IN PUCHAR String
  993. );
  994. EXTERN
  995. PNDIS_PACKET
  996. AtmLaneAllocProtoPacket(
  997. IN PATMLANE_ELAN pElan
  998. );
  999. VOID
  1000. AtmLaneFreeProtoPacket(
  1001. IN PATMLANE_ELAN pElan,
  1002. IN PNDIS_PACKET pNdisPacket
  1003. );
  1004. EXTERN
  1005. PNDIS_BUFFER
  1006. AtmLaneGrowHeaders(
  1007. IN PATMLANE_ELAN pElan
  1008. );
  1009. EXTERN
  1010. PNDIS_BUFFER
  1011. AtmLaneAllocateHeader(
  1012. IN PATMLANE_ELAN pElan,
  1013. OUT PUCHAR * pBufferAddress
  1014. );
  1015. EXTERN
  1016. VOID
  1017. AtmLaneFreeHeader(
  1018. IN PATMLANE_ELAN pElan,
  1019. IN PNDIS_BUFFER pNdisBuffer,
  1020. IN BOOLEAN LockHeld
  1021. );
  1022. EXTERN
  1023. VOID
  1024. AtmLaneDeallocateHeaderBuffers(
  1025. IN PATMLANE_ELAN pElan
  1026. );
  1027. EXTERN
  1028. PNDIS_BUFFER
  1029. AtmLaneGrowPadBufs(
  1030. IN PATMLANE_ELAN pElan
  1031. );
  1032. EXTERN
  1033. PNDIS_BUFFER
  1034. AtmLaneAllocatePadBuf(
  1035. IN PATMLANE_ELAN pElan,
  1036. OUT PUCHAR * pBufferAddress
  1037. );
  1038. EXTERN
  1039. VOID
  1040. AtmLaneFreePadBuf(
  1041. IN PATMLANE_ELAN pElan,
  1042. IN PNDIS_BUFFER pNdisBuffer,
  1043. IN BOOLEAN LockHeld
  1044. );
  1045. EXTERN
  1046. VOID
  1047. AtmLaneDeallocatePadBufs(
  1048. IN PATMLANE_ELAN pElan
  1049. );
  1050. EXTERN
  1051. PNDIS_BUFFER
  1052. AtmLaneAllocateProtoBuffer(
  1053. IN PATMLANE_ELAN pElan,
  1054. IN ULONG Length,
  1055. OUT PUCHAR * pBufferAddress
  1056. );
  1057. EXTERN
  1058. VOID
  1059. AtmLaneFreeProtoBuffer(
  1060. IN PATMLANE_ELAN pElan,
  1061. IN PNDIS_BUFFER pNdisBuffer
  1062. );
  1063. EXTERN
  1064. NDIS_STATUS
  1065. AtmLaneInitProtoBuffers(
  1066. IN PATMLANE_ELAN pElan
  1067. );
  1068. EXTERN
  1069. VOID
  1070. AtmLaneDeallocateProtoBuffers(
  1071. IN PATMLANE_ELAN pElan
  1072. );
  1073. EXTERN
  1074. VOID
  1075. AtmLaneLinkVcToAtmEntry(
  1076. IN PATMLANE_VC pVc,
  1077. IN PATMLANE_ATM_ENTRY pAtmEntry,
  1078. IN BOOLEAN ServerIncoming
  1079. );
  1080. EXTERN
  1081. BOOLEAN
  1082. AtmLaneUnlinkVcFromAtmEntry(
  1083. IN PATMLANE_VC pVc
  1084. );
  1085. EXTERN
  1086. BOOLEAN
  1087. AtmLaneUnlinkMacEntryFromAtmEntry(
  1088. IN PATMLANE_MAC_ENTRY pMacEntry
  1089. );
  1090. EXTERN
  1091. VOID
  1092. AtmLaneStartTimer(
  1093. IN PATMLANE_ELAN pElan,
  1094. IN PATMLANE_TIMER pTimer,
  1095. IN ATMLANE_TIMEOUT_HANDLER TimeoutHandler,
  1096. IN ULONG SecondsToGo,
  1097. IN PVOID ContextPtr
  1098. );
  1099. EXTERN
  1100. BOOLEAN
  1101. AtmLaneStopTimer(
  1102. IN PATMLANE_TIMER pTimer,
  1103. IN PATMLANE_ELAN pElan
  1104. );
  1105. EXTERN
  1106. VOID
  1107. AtmLaneRefreshTimer(
  1108. IN PATMLANE_TIMER pTimer
  1109. );
  1110. EXTERN
  1111. VOID
  1112. AtmLaneTickHandler(
  1113. IN PVOID SystemSpecific1,
  1114. IN PVOID Context,
  1115. IN PVOID SystemSpecific2,
  1116. IN PVOID SystemSpecific3
  1117. );
  1118. EXTERN
  1119. ULONG
  1120. AtmLaneSystemTimeMs(
  1121. void
  1122. );
  1123. EXTERN
  1124. VOID
  1125. AtmLaneBitSwapMacAddr(
  1126. IN OUT PUCHAR ap
  1127. );
  1128. EXTERN
  1129. BOOLEAN
  1130. AtmLaneCopyUnicodeString(
  1131. IN OUT PUNICODE_STRING pDestString,
  1132. IN OUT PUNICODE_STRING pSrcString,
  1133. IN BOOLEAN AllocDest,
  1134. IN BOOLEAN ConvertToUpper
  1135. );
  1136. EXTERN
  1137. PWSTR
  1138. AtmLaneStrTok(
  1139. IN PWSTR StrToken,
  1140. IN WCHAR ChrDelim,
  1141. OUT PUSHORT pStrLength
  1142. );
  1143. #endif // __ATMLANE_EXTERNS_H