Move ETCP packet and carrier diagnostics from debug to etcp trace
This commit is contained in:
1 parent
8ca7c3cc15
commit
b0fe663109
3 files changed
+6
-6
No files matched your search
@@ -933,7 +933,7 @@ static void input_queue_cb(struct ll_queue* q, void* arg) {
|
||||
// memory_pool_free(etcp->io_pool, in_pkt);// перемещаем из io_pool в inflight_pool
|
||||
queue_entry_free(&in_pkt->ll);
|
||||
|
||||
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "[%s] TX input -> inflight seq=%u len=%u input=%d send=%d wait=%d",
|
||||
DEBUG_TRACE(DEBUG_CATEGORY_ETCP, "[%s] TX input -> inflight seq=%u len=%u input=%d send=%d wait=%d",
|
||||
etcp->log_name, p->seq, p->ll.len, etcp->input_queue->count, etcp->input_send_q->count, etcp->input_wait_ack->count);
|
||||
int len=p->ll.len;// сохраним len
|
||||
|
||||
@@ -1079,9 +1079,9 @@ static void etcp_link_ready_callback(struct ETCP_CONN* etcp) {
|
||||
}
|
||||
|
||||
/* Снимок после прохода отправителя: причины могут пересекаться, full относится к голове очереди.
|
||||
* Только BLE и включённая debug-категория; не вызывает selection/BBR и не меняет состояние очередей. */
|
||||
* Только BLE при etcp=trace; не вызывает selection/BBR и не меняет состояние очередей. */
|
||||
static void trace_ble_tx_wait(struct ETCP_CONN* conn) {
|
||||
if (!debug_should_output(DEBUG_LEVEL_DEBUG, DEBUG_CATEGORY_DEBUG) || conn->close_requested || conn->state == 2) return;
|
||||
if (!debug_should_output(DEBUG_LEVEL_TRACE, DEBUG_CATEGORY_ETCP) || conn->close_requested || conn->state == 2) return;
|
||||
struct PKTNORM* pn = conn->normalizer;
|
||||
if (!conn->input_send_q->count && !conn->input_queue->count &&
|
||||
(!pn || (!queue_entry_count(pn->input) && !pn->pending && !pn->data_ptr))) return;
|
||||
@@ -1097,7 +1097,7 @@ static void trace_ble_tx_wait(struct ETCP_CONN* conn) {
|
||||
int input_full = input_len && (input_len > conn->optimal_inflight || conn->unacked_bytes > conn->optimal_inflight - input_len);
|
||||
uint64_t pacing_tb = link->shaper_load_time_tb >= now + SHAPER_BURST_DELAY_TB ?
|
||||
link->shaper_load_time_tb - now - SHAPER_BURST_DELAY_TB + 1 : 0;
|
||||
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "[%s] TX gate path=%u head_seq=%u bytes=%u retry=%u io=%d up=%u init=%u "
|
||||
DEBUG_TRACE(DEBUG_CATEGORY_ETCP, "[%s] TX gate path=%u head_seq=%u bytes=%u retry=%u io=%d up=%u init=%u "
|
||||
"cwnd_full=%d attempts_full=%d pacing=%d pacing_us=%llu rate_Bps=%u flight=%u/%u "
|
||||
"input_full=%d unacked=%u/%u peer_full=%d input=%d send=%d norm=%d pending=%u buffered=%u token=%d",
|
||||
conn->log_name, link->local_link_id, head ? head->seq : 0, bytes, head && head->last_attempt_id != 0,
|
||||
|
||||
@@ -160,7 +160,7 @@ static void changed(struct packet_link* channel, void* arg) {
|
||||
}
|
||||
}
|
||||
if (state.tx_ready) {
|
||||
if (!io->native) DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "[%s] carrier ready path=%u driver=%s input=%d send=%d token=%d",
|
||||
if (!io->native) DEBUG_TRACE(DEBUG_CATEGORY_ETCP, "[%s] carrier ready path=%u driver=%s input=%d send=%d token=%d",
|
||||
conn->log_name, owner->local_link_id, packet_link_name(channel), queue_entry_count(conn->input_queue),
|
||||
queue_entry_count(conn->input_send_q), conn->tx_token != NULL);
|
||||
etcp_conn_wake_sender(conn);
|
||||
|
||||
@@ -217,7 +217,7 @@ static int pn_send_to_etcp(struct PKTNORM* pn) {
|
||||
pn->data = NULL;
|
||||
pn->data_ptr = 0;
|
||||
|
||||
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "[%s] normalizer TX fragment bytes=%u capacity=%u frag_size=%u input=%d",
|
||||
DEBUG_TRACE(DEBUG_CATEGORY_ETCP, "[%s] normalizer TX fragment bytes=%u capacity=%u frag_size=%u input=%d",
|
||||
pn->etcp->log_name, frag->ll.len, frag->ll.memlen, pn->frag_size, queue_entry_count(pn->input));
|
||||
if (debug_should_output(DEBUG_LEVEL_DEBUG, DEBUG_CATEGORY_DUMP)) log_dump(DEBUG_LEVEL_DEBUG, DEBUG_CATEGORY_DUMP, "NORM->ETCP", frag->ll.dgram, frag->ll.len);
|
||||
|
||||
|
||||
Reference in new issue
Block a user