Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 75211
b: refs/heads/master
c: fae718d
h: refs/heads/master
i:
  75209: 19f8541
  75207: 5ddfb85
v: v3
  • Loading branch information
Patrick McHardy authored and David S. Miller committed Dec 27, 2007
1 parent cc7ab10 commit 9531e75
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 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: 81100eb80add328c4d2a377326f15aa0e7236398
refs/heads/master: fae718ddaf2b00e222dddec6717aca023376723c
1 change: 1 addition & 0 deletions trunk/include/net/netfilter/nf_conntrack.h
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,7 @@ static inline int nf_ct_is_untracked(const struct sk_buff *skb)
return (skb->nfct == &nf_conntrack_untracked.ct_general);
}

extern int nf_conntrack_set_hashsize(const char *val, struct kernel_param *kp);
extern unsigned int nf_conntrack_htable_size;
extern int nf_conntrack_checksum;
extern atomic_t nf_conntrack_count;
Expand Down
3 changes: 3 additions & 0 deletions trunk/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c
Original file line number Diff line number Diff line change
Expand Up @@ -419,6 +419,9 @@ struct nf_conntrack_l3proto nf_conntrack_l3proto_ipv4 __read_mostly = {
.me = THIS_MODULE,
};

module_param_call(hashsize, nf_conntrack_set_hashsize, param_get_uint,
&nf_conntrack_htable_size, 0600);

MODULE_ALIAS("nf_conntrack-" __stringify(AF_INET));
MODULE_ALIAS("ip_conntrack");
MODULE_LICENSE("GPL");
Expand Down
5 changes: 3 additions & 2 deletions trunk/net/netfilter/nf_conntrack_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1016,7 +1016,7 @@ struct hlist_head *nf_ct_alloc_hashtable(int *sizep, int *vmalloced)
}
EXPORT_SYMBOL_GPL(nf_ct_alloc_hashtable);

int set_hashsize(const char *val, struct kernel_param *kp)
int nf_conntrack_set_hashsize(const char *val, struct kernel_param *kp)
{
int i, bucket, hashsize, vmalloced;
int old_vmalloced, old_size;
Expand Down Expand Up @@ -1063,8 +1063,9 @@ int set_hashsize(const char *val, struct kernel_param *kp)
nf_ct_free_hashtable(old_hash, old_vmalloced, old_size);
return 0;
}
EXPORT_SYMBOL_GPL(nf_conntrack_set_hashsize);

module_param_call(hashsize, set_hashsize, param_get_uint,
module_param_call(hashsize, nf_conntrack_set_hashsize, param_get_uint,
&nf_conntrack_htable_size, 0600);

int __init nf_conntrack_init(void)
Expand Down

0 comments on commit 9531e75

Please sign in to comment.