diff options
| author | Stephen Hemminger <shemminger@osdl.org> | 2004-08-15 09:16:25 -0700 |
|---|---|---|
| committer | James Morris <jmorris@redhat.com> | 2004-08-15 09:16:25 -0700 |
| commit | b9b78dbe1fc9ffd0536323941f3d24fced91b7ab (patch) | |
| tree | a491425b4029a4b916dba549f88357e46487cfba /include/linux/net.h | |
| parent | 4ce99e97a0dfe8d1f45c115d681e0fa22c333655 (diff) | |
[NET]: Enhanced version of net_random().
Here is another alternative, using tansworthe generator. It uses percpu
state. The one small semantic change is the net_srandom() only affects
the current cpu's seed. The problem was that having it change all cpu's
seed would mean adding locking and the only user's today are a couple of
places that feed in mac address to try make sure address resolution to
collide.
Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Signed-off-by: David S. Miller <davem@redhat.com>
Diffstat (limited to 'include/linux/net.h')
| -rw-r--r-- | include/linux/net.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/net.h b/include/linux/net.h index cec1482f28e2..80e7fec727e3 100644 --- a/include/linux/net.h +++ b/include/linux/net.h @@ -169,6 +169,7 @@ extern struct socket *sockfd_lookup(int fd, int *err); extern int net_ratelimit(void); extern unsigned long net_random(void); extern void net_srandom(unsigned long); +extern void net_random_init(void); extern int kernel_sendmsg(struct socket *sock, struct msghdr *msg, struct kvec *vec, size_t num, size_t len); |
