diff options
Diffstat (limited to 'sys/dev/sfxge/sfxge_tx.h')
-rw-r--r-- | sys/dev/sfxge/sfxge_tx.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/sys/dev/sfxge/sfxge_tx.h b/sys/dev/sfxge/sfxge_tx.h index d18e757..510cb3f 100644 --- a/sys/dev/sfxge/sfxge_tx.h +++ b/sys/dev/sfxge/sfxge_tx.h @@ -130,8 +130,16 @@ enum sfxge_txq_type { #define SFXGE_TX_SCALE(sc) 1 #endif -#define SFXGE_TXQ_LOCK_INIT(_txq, _name) \ - mtx_init(&(_txq)->lock, (_name), NULL, MTX_DEF) +#define SFXGE_TXQ_LOCK_INIT(_txq, _ifname, _txq_index) \ + do { \ + struct sfxge_txq *__txq = (_txq); \ + \ + snprintf((__txq)->lock_name, \ + sizeof((__txq)->lock_name), \ + "%s:txq%u", (_ifname), (_txq_index)); \ + mtx_init(&(__txq)->lock, (__txq)->lock_name, \ + NULL, MTX_DEF); \ + } while (B_FALSE) #define SFXGE_TXQ_LOCK_DESTROY(_txq) \ mtx_destroy(&(_txq)->lock) #define SFXGE_TXQ_LOCK(_txq) \ @@ -164,6 +172,8 @@ struct sfxge_txq { efsys_mem_t *tsoh_buffer; + char lock_name[SFXGE_LOCK_NAME_MAX]; + /* This field changes more often and is read regularly on both * the initiation and completion paths */ @@ -191,6 +201,8 @@ struct sfxge_txq { unsigned long get_non_tcp_overflow; unsigned long put_overflow; unsigned long netdown_drops; + unsigned long tso_pdrop_too_many; + unsigned long tso_pdrop_no_rsrc; /* The following fields change more often, and are used mostly * on the completion path |