i want to update single ring use the ringid
like code:
struct netmap_ring *ring = NETMAP_TXRING(me->nifp, ringid);
i can't find a way to do this.
so i try to change the netmap core.
add code sys/net/netmap.h
struct node {
int ringid;
int update;
};
#define NIOCTXNODE _IOWR('i', 150, struct node)
add code in sys/dev/netmap/netmap.c
case NIOCTXNODE:
if (priv == NULL) {
error = ENXIO;
break;
}
ifp = priv->np_ifp;
na = NA(ifp);
node->ringid += priv->np_qfirst;
na->nm_txsync(ifp, node->ringid, 1 /* do lock */);
break;
in my case.
struct node node;
node.ringid = s;
node.update = 0;
ioctl(me->fd, NIOCTXNODE, &node);
but her can't work.
have some error in somewhere, i can't found it.
can your help me ? luigi.
_______________________________________________
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"