tipc: Avoid reliable broadcast preparation for NACK messages
authorAllan Stephens <Allan.Stephens@windriver.com>
Tue, 25 Jan 2011 21:12:39 +0000 (16:12 -0500)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Wed, 23 Feb 2011 23:05:23 +0000 (18:05 -0500)
Enhance TIPC to skip unnecessary (and, in some cases, redundant)
preparation work when sending a broadcast link NACK message, since this
preparation is only required for broadcast messages that are sent in a
reliable manner. This change also fixes a bug that caused NACK messages
to be improperly counted as "TX packets" in TIPC's broadcast link
statistics.

Signed-off-by: Allan Stephens <Allan.Stephens@windriver.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
net/tipc/bcast.c

index 63df42b..7dc1dc7 100644 (file)
@@ -298,6 +298,7 @@ static void bclink_send_nack(struct tipc_node *n_ptr)
                msg = buf_msg(buf);
                tipc_msg_init(msg, BCAST_PROTOCOL, STATE_MSG,
                         INT_H_SIZE, n_ptr->addr);
+               msg_set_non_seq(msg, 1);
                msg_set_mc_netid(msg, tipc_net_id);
                msg_set_bcast_ack(msg, mod(n_ptr->bclink.last_in));
                msg_set_bcgap_after(msg, n_ptr->bclink.gap_after);