Date: Wed, 25 Mar 2015 11:08:42 +0000 (UTC) From: Andrew Rybchenko <arybchik@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r280566 - stable/10/sys/dev/sfxge Message-ID: <201503251108.t2PB8g7C006037@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: arybchik Date: Wed Mar 25 11:08:41 2015 New Revision: 280566 URL: https://svnweb.freebsd.org/changeset/base/280566 Log: MFC: 279144 sfxge: packet can't require more than n_dma_seg descriptors plus one Use remaining number of DMA segment instead of maximum number in mapping when checking space for one more TSO segment packet. Sponsored by: Solarflare Communications, Inc. Approved by: gnn (mentor) Modified: stable/10/sys/dev/sfxge/sfxge_tx.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/sfxge/sfxge_tx.c ============================================================================== --- stable/10/sys/dev/sfxge/sfxge_tx.c Wed Mar 25 11:07:56 2015 (r280565) +++ stable/10/sys/dev/sfxge/sfxge_tx.c Wed Mar 25 11:08:41 2015 (r280566) @@ -1103,8 +1103,8 @@ sfxge_tx_queue_tso(struct sfxge_txq *txq * the remainder of the input mbuf but do not * roll back the work we have done. */ - if (txq->n_pend_desc > - SFXGE_TSO_MAX_DESC - (1 + SFXGE_TX_MAPPING_MAX_SEG)) { + if (txq->n_pend_desc + 1 /* header */ + n_dma_seg > + SFXGE_TSO_MAX_DESC) { txq->tso_pdrop_too_many++; break; }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201503251108.t2PB8g7C006037>