From: Sasha Levin Date: Sat, 14 Apr 2012 16:37:47 +0000 (-0400) Subject: ipvs: use GFP_KERNEL allocation where possible X-Git-Tag: Ubuntu-5.0.0-8.9~16013^2~140^2~14 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=9615e61e6f23f18fc192ed44735725bb5b500bad;p=mirror_ubuntu-disco-kernel.git ipvs: use GFP_KERNEL allocation where possible Use GFP_KERNEL instead of GFP_ATOMIC when registering an ipvs protocol. This is safe since it will always run from a process context. Signed-off-by: Sasha Levin Acked-by: Julian Anastasov Signed-off-by: Simon Horman Signed-off-by: Pablo Neira Ayuso --- diff --git a/net/netfilter/ipvs/ip_vs_proto.c b/net/netfilter/ipvs/ip_vs_proto.c index ca1647618081..e91c8982dfac 100644 --- a/net/netfilter/ipvs/ip_vs_proto.c +++ b/net/netfilter/ipvs/ip_vs_proto.c @@ -68,7 +68,7 @@ register_ip_vs_proto_netns(struct net *net, struct ip_vs_protocol *pp) struct netns_ipvs *ipvs = net_ipvs(net); unsigned int hash = IP_VS_PROTO_HASH(pp->protocol); struct ip_vs_proto_data *pd = - kzalloc(sizeof(struct ip_vs_proto_data), GFP_ATOMIC); + kzalloc(sizeof(struct ip_vs_proto_data), GFP_KERNEL); if (!pd) return -ENOMEM;