inet: Decrease overhead of on-stack inet_cork.
When we fast path datagram sends to avoid locking by putting the inet_cork on the stack we use up lots of space that isn't necessary. This is because inet_cork contains a "struct flowi" which isn't used in these code paths. Split inet_cork to two parts, "inet_cork" and "inet_cork_full". Only the latter of which has the "struct flowi" and is what is stored in inet_sock. Signed-off-by: David S. Miller <davem@davemloft.net> Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
This commit is contained in:
@@ -132,7 +132,7 @@ extern struct sk_buff *ip_make_skb(struct sock *sk,
|
||||
|
||||
static inline struct sk_buff *ip_finish_skb(struct sock *sk)
|
||||
{
|
||||
return __ip_make_skb(sk, &sk->sk_write_queue, &inet_sk(sk)->cork);
|
||||
return __ip_make_skb(sk, &sk->sk_write_queue, &inet_sk(sk)->cork.base);
|
||||
}
|
||||
|
||||
/* datagram.c */
|
||||
|
Reference in New Issue
Block a user