mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 20:51:03 +02:00
inet: frags: use kmem_cache for inet_frag_queue
Use kmem_cache to allocate/free inet_frag_queue objects since they're all the same size per inet_frags user and are alloced/freed in high volumes thus making it a perfect case for kmem_cache. Signed-off-by: Nikolay Aleksandrov <nikolay@redhat.com> Acked-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
2e404f632f
commit
d4ad4d22e7
@@ -101,9 +101,11 @@ struct inet_frags {
|
||||
void (*destructor)(struct inet_frag_queue *);
|
||||
void (*skb_free)(struct sk_buff *);
|
||||
void (*frag_expire)(unsigned long data);
|
||||
struct kmem_cache *frags_cachep;
|
||||
const char *frags_cache_name;
|
||||
};
|
||||
|
||||
void inet_frags_init(struct inet_frags *);
|
||||
int inet_frags_init(struct inet_frags *);
|
||||
void inet_frags_fini(struct inet_frags *);
|
||||
|
||||
void inet_frags_init_net(struct netns_frags *nf);
|
||||
|
Reference in New Issue
Block a user