svn commit: r311091 - stable/10/sys/dev/sfxge
Andrew Rybchenko
arybchik at FreeBSD.org
Mon Jan 2 09:45:21 UTC 2017
Author: arybchik
Date: Mon Jan 2 09:45:20 2017
New Revision: 311091
URL: https://svnweb.freebsd.org/changeset/base/311091
Log:
MFC r310770
sfxge(4): cleanup: clarify/unify variable name used for put-list length
get_count is used for get-list.
Sponsored by: Solarflare Communications, Inc.
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 Mon Jan 2 09:43:46 2017 (r311090)
+++ stable/10/sys/dev/sfxge/sfxge_tx.c Mon Jan 2 09:45:20 2017 (r311091)
@@ -601,7 +601,7 @@ sfxge_tx_qdpl_put_unlocked(struct sfxge_
volatile uintptr_t *putp;
uintptr_t old;
uintptr_t new;
- unsigned old_len;
+ unsigned int put_count;
KASSERT(mbuf->m_nextpkt == NULL, ("mbuf->m_nextpkt != NULL"));
@@ -615,14 +615,14 @@ sfxge_tx_qdpl_put_unlocked(struct sfxge_
old = *putp;
if (old != 0) {
struct mbuf *mp = (struct mbuf *)old;
- old_len = mp->m_pkthdr.csum_data;
+ put_count = mp->m_pkthdr.csum_data;
} else
- old_len = 0;
- if (old_len >= stdp->std_put_max) {
+ put_count = 0;
+ if (put_count >= stdp->std_put_max) {
atomic_add_long(&txq->put_overflow, 1);
return (ENOBUFS);
}
- mbuf->m_pkthdr.csum_data = old_len + 1;
+ mbuf->m_pkthdr.csum_data = put_count + 1;
mbuf->m_nextpkt = (void *)old;
} while (atomic_cmpset_ptr(putp, old, new) == 0);
More information about the svn-src-all
mailing list