Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 83de47cd authored by Hua Zhong's avatar Hua Zhong Committed by David S. Miller
Browse files

[TCP]: Fix unlikely usage in tcp_transmit_skb()



The following unlikely should be replaced by likely because the
condition happens every time unless there is a hard error to transmit
a packet.

Signed-off-by: default avatarHua Zhong <hzhong@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 8dff7c29
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -465,7 +465,7 @@ static int tcp_transmit_skb(struct sock *sk, struct sk_buff *skb, int clone_it,
	TCP_INC_STATS(TCP_MIB_OUTSEGS);

	err = icsk->icsk_af_ops->queue_xmit(skb, 0);
	if (unlikely(err <= 0))
	if (likely(err <= 0))
		return err;

	tcp_enter_cwr(sk);