Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/netmap/netmap_pipe.c
Show First 20 Lines • Show All 651 Lines • ▼ Show 20 Lines | |||||
int | int | ||||
netmap_get_pipe_na(struct nmreq_header *hdr, struct netmap_adapter **na, | netmap_get_pipe_na(struct nmreq_header *hdr, struct netmap_adapter **na, | ||||
struct netmap_mem_d *nmd, int create) | struct netmap_mem_d *nmd, int create) | ||||
{ | { | ||||
struct nmreq_register *req = (struct nmreq_register *)(uintptr_t)hdr->nr_body; | struct nmreq_register *req = (struct nmreq_register *)(uintptr_t)hdr->nr_body; | ||||
struct netmap_adapter *pna; /* parent adapter */ | struct netmap_adapter *pna; /* parent adapter */ | ||||
struct netmap_pipe_adapter *mna, *sna, *reqna; | struct netmap_pipe_adapter *mna, *sna, *reqna; | ||||
struct ifnet *ifp = NULL; | if_t ifp = NULL; | ||||
const char *pipe_id = NULL; | const char *pipe_id = NULL; | ||||
int role = 0; | int role = 0; | ||||
int error, retries = 0; | int error, retries = 0; | ||||
char *cbra, pipe_char; | char *cbra, pipe_char; | ||||
/* Try to parse the pipe syntax 'xx{yy' or 'xx}yy'. */ | /* Try to parse the pipe syntax 'xx{yy' or 'xx}yy'. */ | ||||
cbra = strrchr(hdr->nr_name, '{'); | cbra = strrchr(hdr->nr_name, '{'); | ||||
if (cbra != NULL) { | if (cbra != NULL) { | ||||
▲ Show 20 Lines • Show All 196 Lines • Show Last 20 Lines |