diff options
| author | David S. Miller <davem@davemloft.net> | 2017-03-21 14:28:08 -0700 | 
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2017-03-21 14:28:08 -0700 | 
| commit | 41e95736b30833710c1e77a2877c2d71133450f7 (patch) | |
| tree | cebd559e5eefc9ab9fd83e16355105e3535125ac /net/netfilter/nft_objref.c | |
| parent | b9974d76f2f505ab0fe9101766b302511988dece (diff) | |
| parent | 4485a841be171dbd8d3f0701b00f59d389e94ce6 (diff) | |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next
Pablo Neira Ayuso says:
====================
Netfilter/IPVS updates for net-next
The following patchset contains Netfilter/IPVS updates for your
net-next tree. A couple of new features for nf_tables, and unsorted
cleanups and incremental updates for the Netfilter tree. More
specifically, they are:
1) Allow to check for TCP option presence via nft_exthdr, patch
   from Phil Sutter.
2) Add symmetric hash support to nft_hash, from Laura Garcia Liebana.
3) Use pr_cont() in ebt_log, from Joe Perches.
4) Remove some dead code in arp_tables reported via static analysis
   tool, from Colin Ian King.
5) Consolidate nf_tables expression validation, from Liping Zhang.
6) Consolidate set lookup via nft_set_lookup().
7) Remove unnecessary rcu read lock side in bridge netfilter, from
   Florian Westphal.
8) Remove unused variable in nf_reject_ipv4, from Tahee Yoo.
9) Pass nft_ctx struct to object initialization indirections, from
   Florian Westphal.
10) Add code to integrate conntrack helper into nf_tables, also from
    Florian.
11) Allow to check if interface index or name exists via
    NFTA_FIB_F_PRESENT, from Phil Sutter.
12) Simplify resolve_normal_ct(), from Florian.
13) Use per-limit spinlock in nft_limit and xt_limit, from Liping Zhang.
14) Use rwlock in nft_set_rbtree set, also from Liping Zhang.
15) One patch to remove a useless printk at netns init path in ipvs,
    and several patches to document IPVS knobs.
16) Use refcount_t for reference counter in the Netfilter/IPVS code,
    from Elena Reshetova.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/netfilter/nft_objref.c')
| -rw-r--r-- | net/netfilter/nft_objref.c | 14 | 
1 files changed, 4 insertions, 10 deletions
| diff --git a/net/netfilter/nft_objref.c b/net/netfilter/nft_objref.c index 1ae8c49ca4a1..1dd428fbaaa3 100644 --- a/net/netfilter/nft_objref.c +++ b/net/netfilter/nft_objref.c @@ -116,16 +116,10 @@ static int nft_objref_map_init(const struct nft_ctx *ctx,  	struct nft_set *set;  	int err; -	set = nf_tables_set_lookup(ctx->table, tb[NFTA_OBJREF_SET_NAME], genmask); -	if (IS_ERR(set)) { -		if (tb[NFTA_OBJREF_SET_ID]) { -			set = nf_tables_set_lookup_byid(ctx->net, -							tb[NFTA_OBJREF_SET_ID], -							genmask); -		} -		if (IS_ERR(set)) -			return PTR_ERR(set); -	} +	set = nft_set_lookup(ctx->net, ctx->table, tb[NFTA_OBJREF_SET_NAME], +			     tb[NFTA_OBJREF_SET_ID], genmask); +	if (IS_ERR(set)) +		return PTR_ERR(set);  	if (!(set->flags & NFT_SET_OBJECT))  		return -EINVAL; | 
