Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Aug 2016 19:18:10 +0000 (UTC)
From:      Ryan Stone <rstone@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-releng@freebsd.org
Subject:   svn commit: r304179 - releng/11.0/sys/dev/bxe
Message-ID:  <201608151918.u7FJIA5A095745@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rstone
Date: Mon Aug 15 19:18:10 2016
New Revision: 304179
URL: https://svnweb.freebsd.org/changeset/base/304179

Log:
  MFC r304163
  
      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 cause 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
  Approved by:	re (kib)
  Differential Revision:        https://reviews.freebsd.org/D7041

Modified:
  releng/11.0/sys/dev/bxe/bxe.c
Directory Properties:
  releng/11.0/   (props changed)

Modified: releng/11.0/sys/dev/bxe/bxe.c
==============================================================================
--- releng/11.0/sys/dev/bxe/bxe.c	Mon Aug 15 19:17:00 2016	(r304178)
+++ releng/11.0/sys/dev/bxe/bxe.c	Mon Aug 15 19:18:10 2016	(r304179)
@@ -5624,7 +5624,8 @@ bxe_tx_mq_start_locked(struct bxe_softc 
     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;
     }
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201608151918.u7FJIA5A095745>