aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/netmap
diff options
context:
space:
mode:
authorLuigi Rizzo <luigi@FreeBSD.org>2014-06-05 21:12:41 +0000
committerLuigi Rizzo <luigi@FreeBSD.org>2014-06-05 21:12:41 +0000
commit43ed1d3c768e40343ea3035369f0b578a037a227 (patch)
tree6506e00e3f9b51d0780bfeb78bf83f75c03f51f4 /sys/dev/netmap
parentc257f99e9b780a17756af5200ff895551f4f04fe (diff)
Notes
Diffstat (limited to 'sys/dev/netmap')
-rw-r--r--sys/dev/netmap/netmap.c6
-rw-r--r--sys/dev/netmap/netmap_kern.h4
-rw-r--r--sys/dev/netmap/netmap_mem2.c2
-rw-r--r--sys/dev/netmap/netmap_pipe.c14
-rw-r--r--sys/dev/netmap/netmap_vale.c2
5 files changed, 14 insertions, 14 deletions
diff --git a/sys/dev/netmap/netmap.c b/sys/dev/netmap/netmap.c
index 6fd8028dbc86..52b5f3286e1d 100644
--- a/sys/dev/netmap/netmap.c
+++ b/sys/dev/netmap/netmap.c
@@ -1019,7 +1019,7 @@ netmap_rxsync_from_host(struct netmap_adapter *na, struct thread *td, void *pwai
nm_i = kring->nr_hwtail;
stop_i = nm_prev(nm_i, lim);
- while ( nm_i != stop_i && (m = mbq_dequeue(q)) != NULL ) {
+ while ( nm_i != stop_i && (m = mbq_dequeue(q)) != NULL ) {
int len = MBUF_LEN(m);
struct netmap_slot *slot = &ring->slot[nm_i];
@@ -1515,7 +1515,7 @@ netmap_set_ringid(struct netmap_priv_d *priv, uint16_t ringid, uint32_t flags)
if (nm_rx_si_user(priv))
na->rx_si_users++;
if (netmap_verbose) {
- D("%s: tx [%d,%d) rx [%d,%d) id %d",
+ D("%s: tx [%d,%d) rx [%d,%d) id %d",
NM_IFPNAME(na->ifp),
priv->np_txqfirst,
priv->np_txqlast,
@@ -2120,7 +2120,7 @@ do_retry_rx:
* Transparent mode: marked bufs on rx rings between
* kring->nr_hwcur and ring->head
* are passed to the other endpoint.
- *
+ *
* In this mode we also scan the sw rxring, which in
* turn passes packets up.
*
diff --git a/sys/dev/netmap/netmap_kern.h b/sys/dev/netmap/netmap_kern.h
index e6acd4d7ab16..dd5d058fafca 100644
--- a/sys/dev/netmap/netmap_kern.h
+++ b/sys/dev/netmap/netmap_kern.h
@@ -678,7 +678,7 @@ static inline uint32_t
nm_kr_rxspace(struct netmap_kring *k)
{
int space = k->nr_hwtail - k->nr_hwcur;
- if (space < 0)
+ if (space < 0)
space += k->nkr_num_slots;
ND("preserving %d rx slots %d -> %d", space, k->nr_hwcur, k->nr_hwtail);
@@ -827,7 +827,7 @@ nm_txsync_finalize(struct netmap_kring *kring)
{
/* update ring tail to what the kernel knows */
kring->ring->tail = kring->rtail = kring->nr_hwtail;
-
+
/* note, head/rhead/hwcur might be behind cur/rcur
* if no carrier
*/
diff --git a/sys/dev/netmap/netmap_mem2.c b/sys/dev/netmap/netmap_mem2.c
index 5491845090e7..d237794311cf 100644
--- a/sys/dev/netmap/netmap_mem2.c
+++ b/sys/dev/netmap/netmap_mem2.c
@@ -992,7 +992,7 @@ netmap_mem_private_new(const char *name, u_int txr, u_int txd,
if (p[NETMAP_RING_POOL].num < v)
p[NETMAP_RING_POOL].num = v;
/* for each pipe we only need the buffers for the 4 "real" rings.
- * On the other end, the pipe ring dimension may be different from
+ * On the other end, the pipe ring dimension may be different from
* the parent port ring dimension. As a compromise, we allocate twice the
* space actually needed if the pipe rings were the same size as the parent rings
*/
diff --git a/sys/dev/netmap/netmap_pipe.c b/sys/dev/netmap/netmap_pipe.c
index f8f29fa1770a..9fcc4d22c874 100644
--- a/sys/dev/netmap/netmap_pipe.c
+++ b/sys/dev/netmap/netmap_pipe.c
@@ -391,7 +391,7 @@ err:
/* netmap_pipe_reg.
*
* There are two cases on registration (onoff==1)
- *
+ *
* 1.a) state is
*
* usr1 --> e1 --> e2
@@ -403,7 +403,7 @@ err:
* usr1 --> e1 --> e2 <-- usr2
*
* and we are e2. Drop the ref e1 is holding.
- *
+ *
* There are two additional cases on unregister (onoff==0)
*
* 2.a) state is
@@ -462,14 +462,14 @@ netmap_pipe_reg(struct netmap_adapter *na, int onoff)
*
* 1) state is
*
- * usr1 --> e1 --> e2
+ * usr1 --> e1 --> e2
*
- * and we are e1 (e2 is not registered, so krings_delete cannot be
+ * and we are e1 (e2 is not registered, so krings_delete cannot be
* called on it);
*
* 2) state is
*
- * usr1 --> e1 e2 <-- usr2
+ * usr1 --> e1 e2 <-- usr2
*
* and we are either e1 or e2.
*
@@ -519,7 +519,7 @@ netmap_pipe_dtor(struct netmap_adapter *na)
pna->peer_ref = 0;
netmap_adapter_put(&pna->peer->up);
}
- if (pna->role == NR_REG_PIPE_MASTER)
+ if (pna->role == NR_REG_PIPE_MASTER)
netmap_pipe_remove(pna->parent, pna);
netmap_adapter_put(pna->parent);
free(na->ifp, M_DEVBUF);
@@ -587,7 +587,7 @@ netmap_get_pipe_na(struct nmreq *nmr, struct netmap_adapter **na, int create)
error = ENODEV;
goto put_out;
}
- /* we create both master and slave.
+ /* we create both master and slave.
* The endpoint we were asked for holds a reference to
* the other one.
*/
diff --git a/sys/dev/netmap/netmap_vale.c b/sys/dev/netmap/netmap_vale.c
index 34e39126e525..242185da6029 100644
--- a/sys/dev/netmap/netmap_vale.c
+++ b/sys/dev/netmap/netmap_vale.c
@@ -1783,7 +1783,7 @@ netmap_bwrap_intr_notify(struct netmap_adapter *na, u_int ring_nr, enum txrx tx,
if (is_host_ring) {
vpna = hostna;
ring_nr = 0;
- }
+ }
/* simulate a user wakeup on the rx ring */
/* fetch packets that have arrived.
* XXX maybe do this in a loop ?