|
version 1.31.2.1, 2024/10/29 01:31:25
|
version 1.33.2.1, 2025/03/31 17:02:29
|
|
Line 12 terms:
|
Line 12 terms:
|
| All of the documentation and software included in the ELWIX and AITNET |
All of the documentation and software included in the ELWIX and AITNET |
| Releases is copyrighted by ELWIX - Sofia/Bulgaria <info@elwix.org> |
Releases is copyrighted by ELWIX - Sofia/Bulgaria <info@elwix.org> |
| |
|
| Copyright 2004 - 2024 | Copyright 2004 - 2025 |
| by Michael Pounov <misho@elwix.org>. All rights reserved. |
by Michael Pounov <misho@elwix.org>. All rights reserved. |
| |
|
| Redistribution and use in source and binary forms, with or without |
Redistribution and use in source and binary forms, with or without |
|
Line 69 static void *txBPFPacket(sched_task_t *);
|
Line 69 static void *txBPFPacket(sched_task_t *);
|
| static void *rxEXTPacket(sched_task_t *); |
static void *rxEXTPacket(sched_task_t *); |
| static void *txEXTPacket(sched_task_t *); |
static void *txEXTPacket(sched_task_t *); |
| |
|
| |
#ifdef __linux__ |
| |
#ifdef __mips__ |
| |
static sched_task_func_t cbProto[SOCK_MAX_SUPPORT][4] = { |
| |
{ acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
| |
{ rxUDPPacket, freeClient, NULL /*rxUDPPacket*/, txUDPPacket }, /* SOCK_DGRAM */ |
| |
{ acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
| |
{ rxRAWPacket, freeClient, NULL /*rxRAWPacket*/, txRAWPacket }, /* SOCK_RAW */ |
| |
{ rxBPFPacket, freeClient, NULL /*rxBPFPacket*/, txBPFPacket }, /* SOCK_BPF */ |
| |
{ rxEXTPacket, freeClient, NULL /*rxEXTPacket*/, txEXTPacket } /* SOCK_EXT */ |
| |
}; |
| |
#else |
| |
static sched_task_func_t cbProto[SOCK_MAX_SUPPORT][4] = { |
| |
{ acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
| |
{ acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
| |
{ rxUDPPacket, freeClient, NULL /*rxUDPPacket*/, txUDPPacket }, /* SOCK_DGRAM */ |
| |
{ rxRAWPacket, freeClient, NULL /*rxRAWPacket*/, txRAWPacket }, /* SOCK_RAW */ |
| |
{ rxBPFPacket, freeClient, NULL /*rxBPFPacket*/, txBPFPacket }, /* SOCK_BPF */ |
| |
{ rxEXTPacket, freeClient, NULL /*rxEXTPacket*/, txEXTPacket } /* SOCK_EXT */ |
| |
}; |
| |
#endif |
| |
#else |
| static sched_task_func_t cbProto[SOCK_MAX_SUPPORT][4] = { |
static sched_task_func_t cbProto[SOCK_MAX_SUPPORT][4] = { |
| { acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
{ acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
| { acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
{ acceptClients, closeClient, rxPacket, txPacket }, /* SOCK_STREAM */ |
|
Line 77 static sched_task_func_t cbProto[SOCK_MAX_SUPPORT][4]
|
Line 98 static sched_task_func_t cbProto[SOCK_MAX_SUPPORT][4]
|
| { rxBPFPacket, freeClient, NULL /*rxBPFPacket*/, txBPFPacket }, /* SOCK_BPF */ |
{ rxBPFPacket, freeClient, NULL /*rxBPFPacket*/, txBPFPacket }, /* SOCK_BPF */ |
| { rxEXTPacket, freeClient, NULL /*rxEXTPacket*/, txEXTPacket } /* SOCK_EXT */ |
{ rxEXTPacket, freeClient, NULL /*rxEXTPacket*/, txEXTPacket } /* SOCK_EXT */ |
| }; |
}; |
| |
#endif |
| |
|
| /* Global Signal Argument when kqueue support disabled */ |
/* Global Signal Argument when kqueue support disabled */ |
| |
|
|
Line 1562 rpc_srv_initServer(u_char InstID, int concurentClients
|
Line 1584 rpc_srv_initServer(u_char InstID, int concurentClients
|
| /* init functions */ |
/* init functions */ |
| pthread_mutex_init(&srv->srv_funcs.mtx, NULL); |
pthread_mutex_init(&srv->srv_funcs.mtx, NULL); |
| SLIST_INIT(&srv->srv_funcs); |
SLIST_INIT(&srv->srv_funcs); |
| AVL_INIT(&srv->srv_funcs); | RB_INIT(&srv->srv_funcs); |
| |
|
| /* init scheduler */ |
/* init scheduler */ |
| srv->srv_root = schedBegin(); |
srv->srv_root = schedBegin(); |
|
Line 1722 rpc_srv_loopServer(rpc_srv_t * __restrict srv)
|
Line 1744 rpc_srv_loopServer(rpc_srv_t * __restrict srv)
|
| AIT_FREE_VAL(&f->func_name); |
AIT_FREE_VAL(&f->func_name); |
| e_free(f); |
e_free(f); |
| } |
} |
| srv->srv_funcs.avlh_root = NULL; | srv->srv_funcs.rbh_root = NULL; |
| RPC_FUNCS_UNLOCK(&srv->srv_funcs); |
RPC_FUNCS_UNLOCK(&srv->srv_funcs); |
| |
|
| return 0; |
return 0; |
|
Line 1822 rpc_srv_initServer2(u_char InstID, int concurentClient
|
Line 1844 rpc_srv_initServer2(u_char InstID, int concurentClient
|
| /* init functions */ |
/* init functions */ |
| pthread_mutex_init(&srv->srv_funcs.mtx, NULL); |
pthread_mutex_init(&srv->srv_funcs.mtx, NULL); |
| SLIST_INIT(&srv->srv_funcs); |
SLIST_INIT(&srv->srv_funcs); |
| AVL_INIT(&srv->srv_funcs); | RB_INIT(&srv->srv_funcs); |
| |
|
| /* init scheduler */ |
/* init scheduler */ |
| srv->srv_root = schedBegin(); |
srv->srv_root = schedBegin(); |
|
Line 1940 rpc_srv_initServerExt(u_char InstID, int netBuf, int f
|
Line 1962 rpc_srv_initServerExt(u_char InstID, int netBuf, int f
|
| /* init functions */ |
/* init functions */ |
| pthread_mutex_init(&srv->srv_funcs.mtx, NULL); |
pthread_mutex_init(&srv->srv_funcs.mtx, NULL); |
| SLIST_INIT(&srv->srv_funcs); |
SLIST_INIT(&srv->srv_funcs); |
| AVL_INIT(&srv->srv_funcs); | RB_INIT(&srv->srv_funcs); |
| |
|
| /* init scheduler */ |
/* init scheduler */ |
| srv->srv_root = schedBegin(); |
srv->srv_root = schedBegin(); |