aboutsummaryrefslogtreecommitdiffstats
path: root/net/tipc
diff options
context:
space:
mode:
Diffstat (limited to 'net/tipc')
-rw-r--r--net/tipc/bcast.c2
-rw-r--r--net/tipc/link.c9
-rw-r--r--net/tipc/link.h18
3 files changed, 9 insertions, 20 deletions
diff --git a/net/tipc/bcast.c b/net/tipc/bcast.c
index a5eb7dbfa0c3..63df42b2d101 100644
--- a/net/tipc/bcast.c
+++ b/net/tipc/bcast.c
@@ -418,8 +418,6 @@ int tipc_bclink_send_msg(struct sk_buff *buf)
418 else 418 else
419 bclink_set_last_sent(); 419 bclink_set_last_sent();
420 420
421 if (bcl->out_queue_size > bcl->stats.max_queue_sz)
422 bcl->stats.max_queue_sz = bcl->out_queue_size;
423 bcl->stats.queue_sz_counts++; 421 bcl->stats.queue_sz_counts++;
424 bcl->stats.accu_queue_sz += bcl->out_queue_size; 422 bcl->stats.accu_queue_sz += bcl->out_queue_size;
425 423
diff --git a/net/tipc/link.c b/net/tipc/link.c
index 0cb773b7ee21..d1818fbc19a3 100644
--- a/net/tipc/link.c
+++ b/net/tipc/link.c
@@ -246,9 +246,6 @@ static void link_timeout(struct link *l_ptr)
246 l_ptr->stats.accu_queue_sz += l_ptr->out_queue_size; 246 l_ptr->stats.accu_queue_sz += l_ptr->out_queue_size;
247 l_ptr->stats.queue_sz_counts++; 247 l_ptr->stats.queue_sz_counts++;
248 248
249 if (l_ptr->out_queue_size > l_ptr->stats.max_queue_sz)
250 l_ptr->stats.max_queue_sz = l_ptr->out_queue_size;
251
252 if (l_ptr->first_out) { 249 if (l_ptr->first_out) {
253 struct tipc_msg *msg = buf_msg(l_ptr->first_out); 250 struct tipc_msg *msg = buf_msg(l_ptr->first_out);
254 u32 length = msg_size(msg); 251 u32 length = msg_size(msg);
@@ -824,7 +821,10 @@ static void link_add_to_outqueue(struct link *l_ptr,
824 l_ptr->last_out = buf; 821 l_ptr->last_out = buf;
825 } else 822 } else
826 l_ptr->first_out = l_ptr->last_out = buf; 823 l_ptr->first_out = l_ptr->last_out = buf;
824
827 l_ptr->out_queue_size++; 825 l_ptr->out_queue_size++;
826 if (l_ptr->out_queue_size > l_ptr->stats.max_queue_sz)
827 l_ptr->stats.max_queue_sz = l_ptr->out_queue_size;
828} 828}
829 829
830/* 830/*
@@ -867,9 +867,6 @@ int tipc_link_send_buf(struct link *l_ptr, struct sk_buff *buf)
867 867
868 /* Packet can be queued or sent: */ 868 /* Packet can be queued or sent: */
869 869
870 if (queue_size > l_ptr->stats.max_queue_sz)
871 l_ptr->stats.max_queue_sz = queue_size;
872
873 if (likely(!tipc_bearer_congested(l_ptr->b_ptr, l_ptr) && 870 if (likely(!tipc_bearer_congested(l_ptr->b_ptr, l_ptr) &&
874 !link_congested(l_ptr))) { 871 !link_congested(l_ptr))) {
875 link_add_to_outqueue(l_ptr, buf, msg); 872 link_add_to_outqueue(l_ptr, buf, msg);
diff --git a/net/tipc/link.h b/net/tipc/link.h
index bdb0fa263d20..a7794e7ede29 100644
--- a/net/tipc/link.h
+++ b/net/tipc/link.h
@@ -196,18 +196,12 @@ struct link {
196 u32 bearer_congs; 196 u32 bearer_congs;
197 u32 deferred_recv; 197 u32 deferred_recv;
198 u32 duplicates; 198 u32 duplicates;
199 199 u32 max_queue_sz; /* send queue size high water mark */
200 /* for statistical profiling of send queue size */ 200 u32 accu_queue_sz; /* used for send queue size profiling */
201 201 u32 queue_sz_counts; /* used for send queue size profiling */
202 u32 max_queue_sz; 202 u32 msg_length_counts; /* used for message length profiling */
203 u32 accu_queue_sz; 203 u32 msg_lengths_total; /* used for message length profiling */
204 u32 queue_sz_counts; 204 u32 msg_length_profile[7]; /* used for msg. length profiling */
205
206 /* for statistical profiling of message lengths */
207
208 u32 msg_length_counts;
209 u32 msg_lengths_total;
210 u32 msg_length_profile[7];
211 } stats; 205 } stats;
212}; 206};
213 207