summaryrefslogtreecommitdiffstats
path: root/private/nw/rdr/exchange.h
blob: dcfb7006081be501a170992c288c85b8817a848f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
/*++

Copyright (c) 1992  Microsoft Corporation

Module Name:

    Exchange.h

Abstract:

    This module defines all of the objects exported by exchange.c in the
    NetWare redirector.

Author:

    Colin Watson    [ColinW]    1-Feb-1993

Revision History:

--*/

#ifndef _NWEXCHANGE_
#define _NWEXCHANGE_

//
// Define the prototype for post_exchange routines.
//

struct _IRP_CONTEXT;
struct _NONPAGED_SCB;

//
//  Prototype for the exchange routine which starts an NCB transmission
//

NTSTATUS
_cdecl
Exchange
(
    struct _IRP_CONTEXT*    pIrpC,
    PEX             pEx,
    char*           f,
    ...
);

//
//  Prototype of routine that can be used to process the response packet
//

NTSTATUS
_cdecl
ExchangeReply(
    IN PUCHAR RspData,
    IN ULONG BytesIndicated,
    char*           f,
    ...                         //  format specific parameters
    );

USHORT
NextSocket(
    IN USHORT OldValue
    );

VOID
KickQueue(
    struct _NONPAGED_SCB*   pNpScb
    );

NTSTATUS
ServerDatagramHandler(
    IN PVOID TdiEventContext,       // the event context - pNpScb
    IN int SourceAddressLength,     // length of the originator of the datagram
    IN PVOID SourceAddress,         // string describing the originator of the datagram
    IN int OptionsLength,           // options for the receive
    IN PVOID Options,               //
    IN ULONG ReceiveDatagramFlags,  //
    IN ULONG BytesIndicated,        // number of bytes this indication
    IN ULONG BytesAvailable,        // number of bytes in complete Tsdu
    OUT ULONG *BytesTaken,          // number of bytes used
    IN PVOID Tsdu,                  // pointer describing this TSDU, typically a lump of bytes
    OUT PIRP *IoRequestPacket        // TdiReceive IRP if MORE_PROCESSING_REQUIRED.
    );

NTSTATUS
WatchDogDatagramHandler(
    IN PVOID TdiEventContext,       // the event context - pNpScb
    IN int SourceAddressLength,     // length of the originator of the datagram
    IN PVOID SourceAddress,         // string describing the originator of the datagram
    IN int OptionsLength,           // options for the receive
    IN PVOID Options,               //
    IN ULONG ReceiveDatagramFlags,  //
    IN ULONG BytesIndicated,        // number of bytes this indication
    IN ULONG BytesAvailable,        // number of bytes in complete Tsdu
    OUT ULONG *BytesTaken,          // number of bytes used
    IN PVOID Tsdu,                  // pointer describing this TSDU, typically a lump of bytes
    OUT PIRP *IoRequestPacket        // TdiReceive IRP if MORE_PROCESSING_REQUIRED.
    );

NTSTATUS
SendDatagramHandler(
    IN PVOID TdiEventContext,       // the event context - pNpScb
    IN int SourceAddressLength,     // length of the originator of the datagram
    IN PVOID SourceAddress,         // string describing the originator of the datagram
    IN int OptionsLength,           // options for the receive
    IN PVOID Options,               //
    IN ULONG ReceiveDatagramFlags,  //
    IN ULONG BytesIndicated,        // number of bytes this indication
    IN ULONG BytesAvailable,        // number of bytes in complete Tsdu
    OUT ULONG *BytesTaken,          // number of bytes used
    IN PVOID Tsdu,                  // pointer describing this TSDU, typically a lump of bytes
    OUT PIRP *IoRequestPacket        // TdiReceive IRP if MORE_PROCESSING_REQUIRED.
    );

#endif // _NWEXCHANGE_