Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 223652
b: refs/heads/master
c: e058464
h: refs/heads/master
v: v3
  • Loading branch information
David S. Miller committed Dec 23, 2010
1 parent 8cdd87e commit c7243de
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0e214ad81545a35c5e62a4c2d6cf7275fd7a545f
refs/heads/master: e058464990c2ef1f3ecd6b83a154913c3c06f02a
1 change: 0 additions & 1 deletion trunk/include/net/flow.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ struct flowi {
__u8 proto;
__u8 flags;
#define FLOWI_FLAG_ANYSRC 0x01
#define FLOWI_FLAG_MATCH_ANY_IIF 0x02
union {
struct {
__be16 sport;
Expand Down
3 changes: 1 addition & 2 deletions trunk/net/core/fib_rules.c
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,7 @@ static int fib_rule_match(struct fib_rule *rule, struct fib_rules_ops *ops,
{
int ret = 0;

if (rule->iifindex && (rule->iifindex != fl->iif) &&
!(fl->flags & FLOWI_FLAG_MATCH_ANY_IIF))
if (rule->iifindex && (rule->iifindex != fl->iif))
goto out;

if (rule->oifindex && (rule->oifindex != fl->oif))
Expand Down
10 changes: 8 additions & 2 deletions trunk/net/ipv4/fib_frontend.c
Original file line number Diff line number Diff line change
Expand Up @@ -163,13 +163,19 @@ struct net_device *__ip_dev_find(struct net *net, __be32 addr, bool devref)
.daddr = addr
}
},
.flags = FLOWI_FLAG_MATCH_ANY_IIF
};
struct fib_result res = { 0 };
struct net_device *dev = NULL;
struct fib_table *local_table;

#ifdef CONFIG_IP_MULTIPLE_TABLES
res.r = NULL;
#endif

rcu_read_lock();
if (fib_lookup(net, &fl, &res)) {
local_table = fib_get_table(net, RT_TABLE_LOCAL);
if (!local_table ||
fib_table_lookup(local_table, &fl, &res, FIB_LOOKUP_NOREF)) {
rcu_read_unlock();
return NULL;
}
Expand Down

0 comments on commit c7243de

Please sign in to comment.