Author: glebius
Date: Wed Feb  3 20:39:52 2016
New Revision: 295218
URL: https://svnweb.freebsd.org/changeset/base/295218

Log:
  Fix inverse logic. If this is zone_pack, then we shouldn't free the
  cluster ourselves.
  
  Found by review. Since this code is !386 and !amd64 and is executed
  on error path, pretty sure no one ever executed it.

Modified:
  head/sys/dev/cxgb/cxgb_sge.c

Modified: head/sys/dev/cxgb/cxgb_sge.c
==============================================================================
--- head/sys/dev/cxgb/cxgb_sge.c        Wed Feb  3 20:24:21 2016        
(r295217)
+++ head/sys/dev/cxgb/cxgb_sge.c        Wed Feb  3 20:39:52 2016        
(r295218)
@@ -738,7 +738,7 @@ refill_fl(adapter_t *sc, struct sge_fl *
                    cl, q->buf_size, refill_fl_cb, &cb_arg, 0);
                
                if (err != 0 || cb_arg.error) {
-                       if (q->zone == zone_pack)
+                       if (q->zone != zone_pack)
                                uma_zfree(q->zone, cl);
                        m_free(m);
                        goto done;
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to