Date: Mon, 19 Feb 2018 16:41:20 +0100 From: Vincenzo Maffione <v.maffione@gmail.com> To: Navdeep Parhar <np@freebsd.org>, Matthew Macy <mmacy@nextbsd.org> Cc: FreeBSD Net <freebsd-net@freebsd.org> Subject: fix for some netmap drivers Message-ID: <CA%2B_eA9iUzCUj%2BRRsNVjO%2BaiOPbrLTS%2BDMerEMROgGJX2UH_eiw@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
Hello,
Can anyone please apply the attached patch? It follows up the removal of
the nkr_slot_flags in the upstream netmap.
The change fixes compilation issues and has no effect on functionality.
Thanks,
Vincenzo
--
Vincenzo Maffione
[-- Attachment #2 --]
diff --git a/sys/dev/cxgbe/t4_netmap.c b/sys/dev/cxgbe/t4_netmap.c
index fa3bbb9fc8f..45083fb9a39 100644
--- a/sys/dev/cxgbe/t4_netmap.c
+++ b/sys/dev/cxgbe/t4_netmap.c
@@ -974,7 +974,7 @@ t4_nm_intr(void *arg)
case CPL_RX_PKT:
ring->slot[fl_cidx].len = G_RSPD_LEN(lq) -
sc->params.sge.fl_pktshift;
- ring->slot[fl_cidx].flags = kring->nkr_slot_flags;
+ ring->slot[fl_cidx].flags = 0;
fl_cidx += (lq & F_RSPD_NEWBUF) ? 1 : 0;
fl_credits += (lq & F_RSPD_NEWBUF) ? 1 : 0;
if (__predict_false(fl_cidx == nm_rxq->fl_sidx))
diff --git a/sys/net/iflib.c b/sys/net/iflib.c
index ba7d2547ed1..44a276e67d7 100644
--- a/sys/net/iflib.c
+++ b/sys/net/iflib.c
@@ -1068,7 +1068,6 @@ iflib_netmap_rxsync(struct netmap_kring *kring, int flags)
if (netmap_no_pendintr || force_update) {
int crclen = iflib_crcstrip ? 0 : 4;
int error, avail;
- uint16_t slot_flags = kring->nkr_slot_flags;
for (i = 0; i < rxq->ifr_nfl; i++) {
fl = &rxq->ifr_fl[i];
@@ -1084,7 +1083,7 @@ iflib_netmap_rxsync(struct netmap_kring *kring, int flags)
error = ctx->isc_rxd_pkt_get(ctx->ifc_softc, &ri);
ring->slot[nm_i].len = error ? 0 : ri.iri_len - crclen;
- ring->slot[nm_i].flags = slot_flags;
+ ring->slot[nm_i].flags = 0;
if (fl->ifl_sds.ifsd_map)
bus_dmamap_sync(fl->ifl_ifdi->idi_tag,
fl->ifl_sds.ifsd_map[nic_i], BUS_DMASYNC_POSTREAD);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2B_eA9iUzCUj%2BRRsNVjO%2BaiOPbrLTS%2BDMerEMROgGJX2UH_eiw>
