netfilter: ipset: Check CIDR value only when attribute is given
authorSergey Popovich <popovich_sergei@mail.ua>
Fri, 12 Jun 2015 19:30:57 +0000 (21:30 +0200)
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Sun, 14 Jun 2015 08:40:14 +0000 (10:40 +0200)
commitaff227581ed1ac299e3a50eef4bb1cef944e1404
treeb967141fc9a101defd0f18d5089996bc7d02c317
parenta212e08e8e0a5c689e61dd175b6e99223dda835c
netfilter: ipset: Check CIDR value only when attribute is given

There is no reason to check CIDR value regardless attribute
specifying CIDR is given.

Initialize cidr array in element structure on element structure
declaration to let more freedom to the compiler to optimize
initialization right before element structure is used.

Remove local variables cidr and cidr2 for netnet and netportnet
hashes as we do not use packed cidr value for such set types and
can store value directly in e.cidr[].

Signed-off-by: Sergey Popovich <popovich_sergei@mail.ua>
Signed-off-by: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
net/netfilter/ipset/ip_set_hash_net.c
net/netfilter/ipset/ip_set_hash_netiface.c
net/netfilter/ipset/ip_set_hash_netnet.c
net/netfilter/ipset/ip_set_hash_netportnet.c
This page took 0.039087 seconds and 5 git commands to generate.