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

Commit 0a6957e7 authored by ZHAO Gang's avatar ZHAO Gang Committed by David S. Miller
Browse files

net: remove function sk_reset_txq()



What sk_reset_txq() does is just calls function sk_tx_queue_reset(),
and sk_reset_txq() is used only in sock.h, by dst_negative_advice().
Let dst_negative_advice() calls sk_tx_queue_reset() directly so we
can remove unneeded sk_reset_txq().

Signed-off-by: default avatarZHAO Gang <gamerh2o@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1a0176da
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -1746,8 +1746,6 @@ sk_dst_get(struct sock *sk)
	return dst;
}

void sk_reset_txq(struct sock *sk);

static inline void dst_negative_advice(struct sock *sk)
{
	struct dst_entry *ndst, *dst = __sk_dst_get(sk);
@@ -1757,7 +1755,7 @@ static inline void dst_negative_advice(struct sock *sk)

		if (ndst != dst) {
			rcu_assign_pointer(sk->sk_dst_cache, ndst);
			sk_reset_txq(sk);
			sk_tx_queue_clear(sk);
		}
	}
}
+0 −6
Original line number Diff line number Diff line
@@ -475,12 +475,6 @@ int sk_receive_skb(struct sock *sk, struct sk_buff *skb, const int nested)
}
EXPORT_SYMBOL(sk_receive_skb);

void sk_reset_txq(struct sock *sk)
{
	sk_tx_queue_clear(sk);
}
EXPORT_SYMBOL(sk_reset_txq);

struct dst_entry *__sk_dst_check(struct sock *sk, u32 cookie)
{
	struct dst_entry *dst = __sk_dst_get(sk);