Author: zbb Date: Fri Apr 8 16:14:18 2016 New Revision: 297721 URL: https://svnweb.freebsd.org/changeset/base/297721
Log: Fix sending TSO packets larger than single DMA segment on VNIC Due to the bug in the number of 'GATHER' subdescriptors for TSO packets, VNIC was not able to transmit more than one DMA segment with TSO enabled. Obtained from: Semihalf Sponsored by: Cavium Modified: head/sys/dev/vnic/nicvf_queues.c Modified: head/sys/dev/vnic/nicvf_queues.c ============================================================================== --- head/sys/dev/vnic/nicvf_queues.c Fri Apr 8 15:48:10 2016 (r297720) +++ head/sys/dev/vnic/nicvf_queues.c Fri Apr 8 16:14:18 2016 (r297721) @@ -1904,7 +1904,6 @@ static int nicvf_tx_mbuf_locked(struct snd_queue *sq, struct mbuf **mbufp) { bus_dma_segment_t segs[256]; - struct nicvf *nic; struct snd_buff *snd_buff; size_t seg; int nsegs, qentry; @@ -1928,12 +1927,7 @@ nicvf_tx_mbuf_locked(struct snd_queue *s } /* Set how many subdescriptors is required */ - nic = sq->nic; - if ((*mbufp)->m_pkthdr.tso_segsz != 0 && nic->hw_tso) - subdesc_cnt = MIN_SQ_DESC_PER_PKT_XMIT; - else - subdesc_cnt = MIN_SQ_DESC_PER_PKT_XMIT + nsegs - 1; - + subdesc_cnt = MIN_SQ_DESC_PER_PKT_XMIT + nsegs - 1; if (subdesc_cnt > sq->free_cnt) { /* ARM64TODO: Add mbuf defragmentation if we lack descriptors */ bus_dmamap_unload(sq->snd_buff_dmat, snd_buff->dmap); _______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"