From owner-svn-src-head@FreeBSD.ORG Fri Feb 20 19:44:03 2015 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8EC2F4AB; Fri, 20 Feb 2015 19:44:03 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7A284DC9; Fri, 20 Feb 2015 19:44:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t1KJi3L8048429; Fri, 20 Feb 2015 19:44:03 GMT (envelope-from arybchik@FreeBSD.org) Received: (from arybchik@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t1KJi3SW048428; Fri, 20 Feb 2015 19:44:03 GMT (envelope-from arybchik@FreeBSD.org) Message-Id: <201502201944.t1KJi3SW048428@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: arybchik set sender to arybchik@FreeBSD.org using -f From: Andrew Rybchenko Date: Fri, 20 Feb 2015 19:44:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r279080 - head/sys/dev/sfxge X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Feb 2015 19:44:03 -0000 Author: arybchik Date: Fri Feb 20 19:44:02 2015 New Revision: 279080 URL: https://svnweb.freebsd.org/changeset/base/279080 Log: sfxge: reap Tx descriptors on unblock Otherwise when processing finally comes to efx_tx_qdesc_post() it could be insufficient space between reaped and added to post pending descriptors. Sponsored by: Solarflare Communications, Inc. Approved by: gnn (mentor) Modified: head/sys/dev/sfxge/sfxge_tx.c Modified: head/sys/dev/sfxge/sfxge_tx.c ============================================================================== --- head/sys/dev/sfxge/sfxge_tx.c Fri Feb 20 19:42:26 2015 (r279079) +++ head/sys/dev/sfxge/sfxge_tx.c Fri Feb 20 19:44:02 2015 (r279080) @@ -1143,8 +1143,11 @@ sfxge_tx_qunblock(struct sfxge_txq *txq) unsigned int level; level = txq->added - txq->completed; - if (level <= SFXGE_TXQ_UNBLOCK_LEVEL(txq->entries)) + if (level <= SFXGE_TXQ_UNBLOCK_LEVEL(txq->entries)) { + /* reaped must be in sync with blocked */ + sfxge_tx_qreap(txq); txq->blocked = 0; + } } sfxge_tx_qdpl_service(txq);