summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrstone <rstone@FreeBSD.org>2016-08-15 15:23:45 +0000
committerrstone <rstone@FreeBSD.org>2016-08-15 15:23:45 +0000
commitbdf6ecc5e6663cf315031bec7696e4418f02bd24 (patch)
tree370838d1b08d70337501d3b7e0aac282763d1264
parent57dc175a34ff457a71a1b9dd76dd0ab79131f07c (diff)
downloadFreeBSD-src-bdf6ecc5e6663cf315031bec7696e4418f02bd24.zip
FreeBSD-src-bdf6ecc5e6663cf315031bec7696e4418f02bd24.tar.gz
MFC r303836
Don't enqueue NULL on a drbr In one corner case in the bxe TX path, a NULL mbuf could be enqueued onto a drbr queue. This could case a KASSERT to fire with INVARIANTS enabled, or the processing of packets from the queue to be prematurely ended later on. Submitted by: Matt Joras (matt.joras AT isilon.com) Reviewed by: davidcs Sponsored by: EMC / Isilon Storage Division Differential Revision: https://reviews.freebsd.org/D7041
-rw-r--r--sys/dev/bxe/bxe.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/bxe/bxe.c b/sys/dev/bxe/bxe.c
index e832389..329801d 100644
--- a/sys/dev/bxe/bxe.c
+++ b/sys/dev/bxe/bxe.c
@@ -5624,7 +5624,8 @@ bxe_tx_mq_start_locked(struct bxe_softc *sc,
if (!sc->link_vars.link_up ||
(if_getdrvflags(ifp) &
(IFF_DRV_RUNNING | IFF_DRV_OACTIVE)) != IFF_DRV_RUNNING) {
- rc = drbr_enqueue(ifp, tx_br, m);
+ if (m != NULL)
+ rc = drbr_enqueue(ifp, tx_br, m);
goto bxe_tx_mq_start_locked_exit;
}
OpenPOWER on IntegriCloud