RTEMS CPU Kit with SuperCore  4.11.3
Data Structures | Macros | Typedefs | Functions
svc_udp.c File Reference
#include <sys/param.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <rpc/rpc.h>
#include <sys/socket.h>
#include <errno.h>
Include dependency graph for svc_udp.c:

Data Structures

struct  svcudp_data
 
struct  cache_node
 
struct  udp_cache
 

Macros

#define rpc_buffer(xprt)   ((xprt)->xp_p1)
 
#define su_data(xprt)   ((struct svcudp_data *)(xprt->xp_p2))
 
#define SPARSENESS   4 /* 75% sparse */
 
#define CACHE_PERROR(msg)   (void) fprintf(stderr,"%s\n", msg)
 
#define ALLOC(type, size)   (type *) mem_alloc((unsigned) (sizeof(type) * (size)))
 
#define BZERO(addr, type, size)   memset((char *) addr, 0, sizeof(type) * (int) (size))
 
#define CACHE_LOC(transp, xid)   (xid % (SPARSENESS*((struct udp_cache *) su_data(transp)->su_cache)->uc_size))
 
#define EQADDR(a1, a2)   (memcmp(&a1, &a2, sizeof(a1)) == 0)
 

Typedefs

typedef struct cache_nodecache_ptr
 

Functions

SVCXPRTsvcudp_bufcreate (int sock, u_int sendsz, u_int recvsz)
 
SVCXPRTsvcudp_create (int sock)
 
int svcudp_enablecache (SVCXPRT *transp, u_long size)