1 /**************************************************************************/ 2 /* */ 3 /* Copyright (c) Microsoft Corporation. All rights reserved. */ 4 /* */ 5 /* This software is licensed under the Microsoft Software License */ 6 /* Terms for Microsoft Azure RTOS. Full text of the license can be */ 7 /* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA */ 8 /* and in the root directory of this software. */ 9 /* */ 10 /**************************************************************************/ 11 12 13 /**************************************************************************/ 14 /**************************************************************************/ 15 /** */ 16 /** NetX Component */ 17 /** */ 18 /** PPP Over Ethernet (PPPoE) */ 19 /** */ 20 /**************************************************************************/ 21 /**************************************************************************/ 22 23 24 /**************************************************************************/ 25 /* */ 26 /* APPLICATION INTERFACE DEFINITION RELEASE */ 27 /* */ 28 /* nx_pppoe_server.h PORTABLE C */ 29 /* 6.1.9 */ 30 /* AUTHOR */ 31 /* */ 32 /* Yuxin Zhou, Microsoft Corporation */ 33 /* */ 34 /* DESCRIPTION */ 35 /* */ 36 /* This file defines the NetX PPP Over Ethernet (PPPoE) Server */ 37 /* componet, including all data types and external references. It is */ 38 /* assumed that nx_api.h and nx_port.h have already been included. */ 39 /* */ 40 /* RELEASE HISTORY */ 41 /* */ 42 /* DATE NAME DESCRIPTION */ 43 /* */ 44 /* 05-19-2020 Yuxin Zhou Initial Version 6.0 */ 45 /* 09-30-2020 Yuxin Zhou Modified comment(s), */ 46 /* resulting in version 6.1 */ 47 /* 02-02-2021 Yuxin Zhou Modified comment(s), */ 48 /* fixed the compiler errors, */ 49 /* resulting in version 6.1.4 */ 50 /* 10-15-2021 Yuxin Zhou Modified comment(s), included */ 51 /* necessary header file, */ 52 /* resulting in version 6.1.9 */ 53 /* */ 54 /**************************************************************************/ 55 56 #ifndef NX_PPPOE_SERVER_H 57 #define NX_PPPOE_SERVER_H 58 59 /* Determine if a C++ compiler is being used. If so, ensure that standard 60 C is used to process the API information. */ 61 62 #ifdef __cplusplus 63 64 /* Yes, C++ compiler is present. Use standard C. */ 65 extern "C" { 66 67 #endif 68 69 #include "nx_api.h" 70 71 /* Note: Prerequisite for using PPPoE. 72 Redefine NX_PHYSICAL_HEADER to 24 to ensure enough space for filling in physical header. 73 Physical header:14(Ethernet header) + 6(PPPoE header) + 2(PPP header) + 2(four-byte aligment). */ 74 75 /* Define the Driver command for PPPoE packet. */ 76 #ifndef NX_LINK_PPPOE_DISCOVERY_SEND 77 #define NX_LINK_PPPOE_DISCOVERY_SEND 51 78 #endif 79 #ifndef NX_LINK_PPPOE_SESSION_SEND 80 #define NX_LINK_PPPOE_SESSION_SEND 52 81 #endif 82 83 /* Define the PPPoE Server ID. */ 84 #define NX_PPPOE_SERVER_ID 0x50505045UL 85 86 /* Enable the feature to control the session established. */ 87 /* 88 #define NX_PPPOE_SERVER_SESSION_CONTROL_ENABLE 89 */ 90 91 /* If the driver is not initialized in other module, enable the feature to initialize the driver in PPPoE module . */ 92 /* 93 #define NX_PPPOE_SERVER_INITIALIZE_DRIVER_ENABLE 94 */ 95 96 /* Define the PPPoE Thread time slice. */ 97 #ifndef NX_PPPOE_SERVER_THREAD_TIME_SLICE 98 #define NX_PPPOE_SERVER_THREAD_TIME_SLICE TX_NO_TIME_SLICE 99 #endif 100 101 /* Define the number of pppoe clients. */ 102 #ifndef NX_PPPOE_SERVER_MAX_CLIENT_SESSION_NUMBER 103 #define NX_PPPOE_SERVER_MAX_CLIENT_SESSION_NUMBER 10 104 #endif 105 106 /* Define the size of pppoe Host-Uniq. */ 107 #ifndef NX_PPPOE_SERVER_MAX_HOST_UNIQ_SIZE 108 #define NX_PPPOE_SERVER_MAX_HOST_UNIQ_SIZE 32 109 #endif 110 111 /* Define the size of pppoe Relay-Session-Id. */ 112 #ifndef NX_PPPOE_SERVER_MAX_RELAY_SESSION_ID_SIZE 113 #define NX_PPPOE_SERVER_MAX_RELAY_SESSION_ID_SIZE 12 114 #endif 115 116 /* Define the minimum size of packet payload to avoid packet chained. Maximum Payload Size of Ethernet(1500) + Ethernet Header + CRC + Four-byte alignment. */ 117 118 #ifndef NX_PPPOE_SERVER_MIN_PACKET_PAYLOAD_SIZE 119 #define NX_PPPOE_SERVER_MIN_PACKET_PAYLOAD_SIZE 1520 120 #endif 121 122 /* The time out in timer ticks on allocating packets or appending data into packets. */ 123 #ifndef NX_PPPOE_SERVER_PACKET_TIMEOUT 124 #define NX_PPPOE_SERVER_PACKET_TIMEOUT (NX_IP_PERIODIC_RATE) /* 1 second */ 125 #endif 126 127 /* Set the start Session ID for assigning to the PPPoE session. */ 128 #ifndef NX_PPPOE_SERVER_START_SESSION_ID 129 #define NX_PPPOE_SERVER_START_SESSION_ID 0x4944 130 #endif 131 132 /* Define PPPoE ethernet header size. */ 133 #define NX_PPPOE_SERVER_ETHER_HEADER_SIZE 14 134 135 /* Define PPPoE ethernet types. */ 136 #define NX_PPPOE_SERVER_ETHER_TYPE_DISCOVERY 0x8863 137 #define NX_PPPOE_SERVER_ETHER_TYPE_SESSION 0x8864 138 139 /* Define PPPoE version and type. */ 140 #define NX_PPPOE_SERVER_VERSION_TYPE 0x11 /* Version 1, Type 1. */ 141 142 /* Define PPPoE codes. */ 143 #define NX_PPPOE_SERVER_CODE_ZERO 0x00 144 #define NX_PPPOE_SERVER_CODE_PADI 0x09 145 #define NX_PPPOE_SERVER_CODE_PADO 0x07 146 #define NX_PPPOE_SERVER_CODE_PADR 0x19 147 #define NX_PPPOE_SERVER_CODE_PADS 0x65 148 #define NX_PPPOE_SERVER_CODE_PADT 0xa7 149 150 /* Define the PPPoE Area Offsets. */ 151 #define NX_PPPOE_SERVER_OFFSET_VER_TYPE 0 /* 1 byte, version + type: 0x11 */ 152 #define NX_PPPOE_SERVER_OFFSET_CODE 1 /* 1 byte, code: Discovery or Session */ 153 #define NX_PPPOE_SERVER_OFFSET_SESSION_ID 2 /* 2 bytes, session id: unique session identifieer */ 154 #define NX_PPPOE_SERVER_OFFSET_LENGTH 4 /* 2 bytes, length: the length of PPPoE payload */ 155 #define NX_PPPOE_SERVER_OFFSET_PAYLOAD 6 /* variable, payload */ 156 157 /* Define the PPPoE Tag Types. */ 158 #define NX_PPPOE_SERVER_TAG_TYPE_END_OF_LIST 0x0000 159 #define NX_PPPOE_SERVER_TAG_TYPE_SERVICE_NAME 0x0101 160 #define NX_PPPOE_SERVER_TAG_TYPE_AC_NAME 0x0102 161 #define NX_PPPOE_SERVER_TAG_TYPE_HOST_UNIQ 0x0103 162 #define NX_PPPOE_SERVER_TAG_TYPE_AC_COOKIE 0x0104 163 #define NX_PPPOE_SERVER_TAG_TYPE_VENDOR_SPECIFIC 0x0105 164 #define NX_PPPOE_SERVER_TAG_TYPE_RELAY_SESSION_ID 0x0110 165 #define NX_PPPOE_SERVER_TAG_TYPE_SERVICE_NAME_ERROR 0x0201 166 #define NX_PPPOE_SERVER_TAG_TYPE_AC_SYSTEM_ERROR 0x0202 167 #define NX_PPPOE_SERVER_TAG_TYPE_GENERIC_ERROR 0x0203 168 169 /* Define the PPPoE Error flags. */ 170 #define NX_PPPOE_SERVER_ERROR_SERVICE_NAME ((ULONG) 0x00000001) /* Service Name Error. */ 171 #define NX_PPPOE_SERVER_ERROR_AC_SYSTEM ((ULONG) 0x00000002) /* AC-System Error */ 172 #define NX_PPPOE_SERVER_ERROR_GENERIC ((ULONG) 0x00000004) /* Generic Error */ 173 174 /* Define event flags for PPPoE thread control. */ 175 #define NX_PPPOE_SERVER_ALL_EVENTS ((ULONG) 0xFFFFFFFF) /* All event flags */ 176 #define NX_PPPOE_SERVER_PACKET_RECEIVE_EVENT ((ULONG) 0x00000001) /* PPPoE Server receive packet event */ 177 #define NX_PPPOE_SERVER_SESSION_RECEIVE_EVENT ((ULONG) 0x00000002) /* PPPoE Session receive packet event */ 178 179 /* Define error codes from PPPoE Server operation. */ 180 #define NX_PPPOE_SERVER_SUCCESS 0x00 /* Success */ 181 #define NX_PPPOE_SERVER_PTR_ERROR 0xC1 /* Invalid input pointers */ 182 #define NX_PPPOE_SERVER_INVALID_INTERFACE 0xC2 /* Invalid interface */ 183 #define NX_PPPOE_SERVER_PACKET_PAYLOAD_ERROR 0xC3 /* Invalid payload size of packet */ 184 #define NX_PPPOE_SERVER_MEMORY_SIZE_ERROR 0xC4 /* Invalid memory size */ 185 #define NX_PPPOE_SERVER_PRIORITY_ERROR 0xC5 /* Invalid priority */ 186 #define NX_PPPOE_SERVER_NOT_ENABLED 0xC6 /* PPPoE is not enabled */ 187 #define NX_PPPOE_SERVER_INVALID_SESSION 0xC7 /* Invalid Session */ 188 #define NX_PPPOE_SERVER_SESSION_NOT_ESTABLISHED 0xC8 /* PPPoE Session is not established */ 189 #define NX_PPPOE_SERVER_SERVICE_NAME_ERROR 0xC9 /* Service name error */ 190 #define NX_PPPOE_SERVER_AC_NAME_ERROR 0xCA /* AC Name error */ 191 #define NX_PPPOE_SERVER_CLIENT_SESSION_FULL 0xCB /* Client Session full */ 192 #define NX_PPPOE_SERVER_CLIENT_SESSION_NOT_FOUND 0xCC /* Not found the client session */ 193 #define NX_PPPOE_SERVER_HOST_UNIQ_CACHE_ERROR 0xCD /* The cache is not enough to record the Host Uniq */ 194 #define NX_PPPOE_SERVER_RELAY_SESSION_ID_CACHE_ERROR 0xCF /* The cache is not enough to record Relay Session ID*/ 195 196 /* Define the PPPoE Client Session structure containing the session id and physical address. */ 197 198 typedef struct NX_PPPOE_CLIENT_SESSION_STRUCT 199 { 200 201 USHORT nx_pppoe_valid; 202 USHORT nx_pppoe_session_id; 203 ULONG nx_pppoe_physical_address_msw; 204 ULONG nx_pppoe_physical_address_lsw; 205 UCHAR *nx_pppoe_service_name; 206 #ifdef NX_PPPOE_SERVER_SESSION_CONTROL_ENABLE 207 UINT nx_pppoe_service_name_length; 208 UINT nx_pppoe_packet_receive_stopped; 209 NX_PACKET *nx_pppoe_deferred_received_packet_head, 210 *nx_pppoe_deferred_received_packet_tail; 211 UCHAR *nx_pppoe_generic_error; 212 #endif 213 UCHAR nx_pppoe_host_uniq[NX_PPPOE_SERVER_MAX_HOST_UNIQ_SIZE]; 214 UINT nx_pppoe_host_uniq_size; 215 UCHAR nx_pppoe_relay_session_id[NX_PPPOE_SERVER_MAX_RELAY_SESSION_ID_SIZE]; 216 UINT nx_pppoe_relay_session_id_size; 217 UINT nx_pppoe_error_flag; 218 } NX_PPPOE_CLIENT_SESSION; 219 220 221 222 /* Define the main PPPoE Server data structure. */ 223 224 typedef struct NX_PPPOE_SERVER_STRUCT 225 { 226 227 ULONG nx_pppoe_id; 228 UINT nx_pppoe_enabled; 229 UCHAR *nx_pppoe_name; 230 UINT nx_pppoe_name_length; 231 UCHAR *nx_pppoe_ac_name; 232 UINT nx_pppoe_ac_name_length; 233 NX_IP *nx_pppoe_ip_ptr; 234 NX_INTERFACE *nx_pppoe_interface_ptr; 235 NX_PACKET_POOL *nx_pppoe_packet_pool_ptr; 236 TX_EVENT_FLAGS_GROUP nx_pppoe_events; 237 TX_THREAD nx_pppoe_thread; 238 NX_PACKET *nx_pppoe_deferred_received_packet_head, 239 *nx_pppoe_deferred_received_packet_tail; 240 UCHAR **nx_pppoe_service_name; 241 UINT nx_pppoe_service_name_count; 242 USHORT nx_pppoe_session_id; 243 USHORT nx_pppoe_reserved[2]; 244 NX_PPPOE_CLIENT_SESSION nx_pppoe_client_session[NX_PPPOE_SERVER_MAX_CLIENT_SESSION_NUMBER]; 245 246 /* Define the callback nofiy function. */ 247 VOID (*nx_pppoe_discover_initiation_notify)(UINT session_index); 248 VOID (*nx_pppoe_discover_request_notify)(UINT session_index, ULONG length, UCHAR *data); 249 VOID (*nx_pppoe_discover_terminate_notify)(UINT session_index); 250 VOID (*nx_pppoe_discover_terminate_confirm)(UINT session_index); 251 VOID (*nx_pppoe_data_receive_notify)(UINT session_index, ULONG length, UCHAR *data, UINT packet_id); 252 VOID (*nx_pppoe_data_send_notify)(UINT session_index, UCHAR *data); 253 254 /* Define the Link Driver entry point. */ 255 VOID (*nx_pppoe_link_driver_entry)(struct NX_IP_DRIVER_STRUCT *); 256 257 } NX_PPPOE_SERVER; 258 259 260 #ifndef NX_PPPOE_SERVER_SOURCE_CODE 261 262 /* Application caller is present, perform API mapping. */ 263 264 /* Determine if error checking is desired. If so, map API functions 265 to the appropriate error checking front-ends. Otherwise, map API 266 functions to the core functions that actually perform the work. 267 Note: error checking is enabled by default. */ 268 269 #ifdef NX_DISABLE_ERROR_CHECKING 270 271 /* Services without error checking. */ 272 273 #define nx_pppoe_server_create _nx_pppoe_server_create 274 #define nx_pppoe_server_delete _nx_pppoe_server_delete 275 #define nx_pppoe_server_enable _nx_pppoe_server_enable 276 #define nx_pppoe_server_disable _nx_pppoe_server_disable 277 #define nx_pppoe_server_callback_notify_set _nx_pppoe_server_callback_notify_set 278 #define nx_pppoe_server_ac_name_set _nx_pppoe_server_ac_name_set 279 #define nx_pppoe_server_service_name_set _nx_pppoe_server_service_name_set 280 #define nx_pppoe_server_session_send _nx_pppoe_server_session_send 281 #define nx_pppoe_server_session_packet_send _nx_pppoe_server_session_packet_send 282 #define nx_pppoe_server_session_terminate _nx_pppoe_server_session_terminate 283 #define nx_pppoe_server_session_get _nx_pppoe_server_session_get 284 285 #else 286 287 /* Services with error checking. */ 288 289 #define nx_pppoe_server_create _nxe_pppoe_server_create 290 #define nx_pppoe_server_delete _nxe_pppoe_server_delete 291 #define nx_pppoe_server_enable _nxe_pppoe_server_enable 292 #define nx_pppoe_server_disable _nxe_pppoe_server_disable 293 #define nx_pppoe_server_callback_notify_set _nxe_pppoe_server_callback_notify_set 294 #define nx_pppoe_server_ac_name_set _nxe_pppoe_server_ac_name_set 295 #define nx_pppoe_server_service_name_set _nxe_pppoe_server_service_name_set 296 #define nx_pppoe_server_session_send _nxe_pppoe_server_session_send 297 #define nx_pppoe_server_session_packet_send _nxe_pppoe_server_session_packet_send 298 #define nx_pppoe_server_session_terminate _nxe_pppoe_server_session_terminate 299 #define nx_pppoe_server_session_get _nxe_pppoe_server_session_get 300 301 #endif /* NX_DISABLE_ERROR_CHECKING */ 302 303 /* Define the prototypes accessible to the application software. */ 304 305 UINT nx_pppoe_server_create(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR *name, NX_IP *ip_ptr, UINT interface_index, 306 VOID (*pppoe_link_driver)(struct NX_IP_DRIVER_STRUCT *), NX_PACKET_POOL *pool_ptr, 307 VOID *stack_ptr, ULONG stack_size, UINT priority); 308 UINT nx_pppoe_server_delete(NX_PPPOE_SERVER *pppoe_server_ptr); 309 UINT nx_pppoe_server_enable(NX_PPPOE_SERVER *pppoe_server_ptr); 310 UINT nx_pppoe_server_disable(NX_PPPOE_SERVER *pppoe_server_ptr); 311 UINT nx_pppoe_server_callback_notify_set(NX_PPPOE_SERVER *pppoe_server_ptr, 312 VOID (* pppoe_discover_initiation_notify)(UINT session_index), 313 VOID (* pppoe_discover_request_notify)(UINT session_index, ULONG length, UCHAR *data), 314 VOID (* pppoe_discover_terminate_notify)(UINT session_index), 315 VOID (* pppoe_discover_terminate_confirm)(UINT session_index), 316 VOID (* pppoe_data_receive_notify)(UINT session_index, ULONG length, UCHAR *data, UINT packet_id), 317 VOID (* pppoe_data_send_notify)(UINT session_index, UCHAR *data)); 318 UINT nx_pppoe_server_ac_name_set(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR *ac_name, UINT ac_name_length); 319 UINT nx_pppoe_server_service_name_set(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR **service_name, UINT service_name_count); 320 UINT nx_pppoe_server_session_send(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, UCHAR *data_ptr, UINT data_length); 321 UINT nx_pppoe_server_session_packet_send(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, NX_PACKET *packet_ptr); 322 UINT nx_pppoe_server_session_terminate(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index); 323 UINT nx_pppoe_server_session_get(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, ULONG *client_mac_msw, ULONG *client_mac_lsw, ULONG *session_id); 324 VOID _nx_pppoe_server_packet_deferred_receive(NX_PACKET *packet_ptr); 325 326 #else 327 328 UINT _nxe_pppoe_server_create(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR *name, NX_IP *ip_ptr, UINT interface_index, 329 VOID (*pppoe_link_driver)(struct NX_IP_DRIVER_STRUCT *), NX_PACKET_POOL *pool_ptr, 330 VOID *stack_ptr, ULONG stack_size, UINT priority); 331 UINT _nx_pppoe_server_create(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR *name, NX_IP *ip_ptr, UINT interface_index, 332 VOID (*pppoe_link_driver)(struct NX_IP_DRIVER_STRUCT *), NX_PACKET_POOL *pool_ptr, 333 VOID *stack_ptr, ULONG stack_size, UINT priority); 334 UINT _nxe_pppoe_server_delete(NX_PPPOE_SERVER *pppoe_server_ptr); 335 UINT _nx_pppoe_server_delete(NX_PPPOE_SERVER *pppoe_server_ptr); 336 UINT _nxe_pppoe_server_enable(NX_PPPOE_SERVER *pppoe_server_ptr); 337 UINT _nx_pppoe_server_enable(NX_PPPOE_SERVER *pppoe_server_ptr); 338 UINT _nxe_pppoe_server_disable(NX_PPPOE_SERVER *pppoe_server_ptr); 339 UINT _nx_pppoe_server_disable(NX_PPPOE_SERVER *pppoe_server_ptr); 340 UINT _nxe_pppoe_server_callback_notify_set(NX_PPPOE_SERVER *pppoe_server_ptr, 341 VOID (* pppoe_discover_initiation_notify)(UINT session_index), 342 VOID (* pppoe_discover_request_notify)(UINT session_index, ULONG length, UCHAR *data), 343 VOID (* pppoe_discover_terminate_notify)(UINT session_index), 344 VOID (* pppoe_discover_terminate_confirm)(UINT session_index), 345 VOID (* pppoe_data_receive_notify)(UINT session_index, ULONG length, UCHAR *data, UINT packet_id), 346 VOID (* pppoe_data_send_notify)(UINT session_index, UCHAR *data)); 347 UINT _nx_pppoe_server_callback_notify_set(NX_PPPOE_SERVER *pppoe_server_ptr, 348 VOID (* pppoe_discover_initiation_notify)(UINT session_index), 349 VOID (* pppoe_discover_request_notify)(UINT session_index, ULONG length, UCHAR *data), 350 VOID (* pppoe_discover_terminate_notify)(UINT session_index), 351 VOID (* pppoe_discover_terminate_confirm)(UINT session_index), 352 VOID (* pppoe_data_receive_notify)(UINT session_index, ULONG length, UCHAR *data, UINT packet_id), 353 VOID (* pppoe_data_send_notify)(UINT session_index, UCHAR *data)); 354 UINT _nxe_pppoe_server_ac_name_set(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR *ac_name, UINT ac_name_length); 355 UINT _nx_pppoe_server_ac_name_set(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR *ac_name, UINT ac_name_length); 356 UINT _nxe_pppoe_server_service_name_set(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR **service_name, UINT service_name_count); 357 UINT _nx_pppoe_server_service_name_set(NX_PPPOE_SERVER *pppoe_server_ptr, UCHAR **service_name, UINT service_name_count); 358 UINT _nxe_pppoe_server_session_send(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, UCHAR *data_ptr, UINT data_length); 359 UINT _nx_pppoe_server_session_send(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, UCHAR *data_ptr, UINT data_length); 360 UINT _nxe_pppoe_server_session_packet_send(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, NX_PACKET *packet_ptr); 361 UINT _nx_pppoe_server_session_packet_send(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, NX_PACKET *packet_ptr); 362 UINT _nxe_pppoe_server_session_terminate(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index); 363 UINT _nx_pppoe_server_session_terminate(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index); 364 UINT _nxe_pppoe_server_session_get(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, ULONG *client_mac_msw, ULONG *client_mac_lsw, ULONG *session_id); 365 UINT _nx_pppoe_server_session_get(NX_PPPOE_SERVER *pppoe_server_ptr, UINT session_index, ULONG *client_mac_msw, ULONG *client_mac_lsw, ULONG *session_id); 366 VOID _nx_pppoe_server_packet_deferred_receive(NX_PACKET *packet_ptr); 367 368 #endif /* NX_PPPOE_SERVER_SOURCE_CODE */ 369 370 #ifdef NX_PPPOE_SERVER_SESSION_CONTROL_ENABLE 371 VOID PppInitInd(UINT length, UCHAR *aData); 372 VOID PppDiscoverCnf(UINT length, UCHAR *aData, UINT interfaceHandle); 373 VOID PppOpenCnf(UCHAR accept, UINT interfaceHandle); 374 VOID PppCloseInd(UINT interfaceHandle, UCHAR *causeCode); 375 VOID PppCloseCnf(UINT interfaceHandle); 376 VOID PppTransmitDataCnf(UINT interfaceHandle, UCHAR *aData, UINT packet_id); 377 VOID PppReceiveDataInd(UINT interfaceHandle, UINT length, UCHAR *aData); 378 #endif 379 380 /* Determine if a C++ compiler is being used. If so, complete the standard 381 C conditional started above. */ 382 #ifdef __cplusplus 383 } 384 #endif 385 386 #endif /* NX_PPPOE_SERVER_H */ 387