Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 121847
b: refs/heads/master
c: 7a12122
h: refs/heads/master
i:
  121845: 0c9dbdc
  121843: a1d5ff6
  121839: 0b14746
v: v3
  • Loading branch information
Arnaud Ebalard authored and David S. Miller committed Nov 13, 2008
1 parent 3322120 commit 371c129
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 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: 2378982487c492541d17adc0a870e7e83b07ba43
refs/heads/master: 7a12122c7a00347da9669cfcde82954c9e3d6f5e
6 changes: 3 additions & 3 deletions trunk/net/xfrm/xfrm_policy.c
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ static DECLARE_WORK(xfrm_hash_work, xfrm_hash_resize);

/* Generate new index... KAME seems to generate them ordered by cost
* of an absolute inpredictability of ordering of rules. This will not pass. */
static u32 xfrm_gen_index(u8 type, int dir)
static u32 xfrm_gen_index(int dir)
{
static u32 idx_generator;

Expand Down Expand Up @@ -608,7 +608,7 @@ int xfrm_policy_insert(int dir, struct xfrm_policy *policy, int excl)
list_del(&delpol->walk.all);
xfrm_policy_count[dir]--;
}
policy->index = delpol ? delpol->index : xfrm_gen_index(policy->type, dir);
policy->index = delpol ? delpol->index : xfrm_gen_index(dir);
hlist_add_head(&policy->byidx, xfrm_policy_byidx+idx_hash(policy->index));
policy->curlft.add_time = get_seconds();
policy->curlft.use_time = 0;
Expand Down Expand Up @@ -1138,7 +1138,7 @@ int xfrm_sk_policy_insert(struct sock *sk, int dir, struct xfrm_policy *pol)
sk->sk_policy[dir] = pol;
if (pol) {
pol->curlft.add_time = get_seconds();
pol->index = xfrm_gen_index(pol->type, XFRM_POLICY_MAX+dir);
pol->index = xfrm_gen_index(XFRM_POLICY_MAX+dir);
__xfrm_policy_link(pol, XFRM_POLICY_MAX+dir);
}
if (old_pol)
Expand Down

0 comments on commit 371c129

Please sign in to comment.