diff options
author | markm <markm@FreeBSD.org> | 2000-09-12 13:13:22 +0000 |
---|---|---|
committer | markm <markm@FreeBSD.org> | 2000-09-12 13:13:22 +0000 |
commit | 8310a0865410b67ec838360f16defef0a527224a (patch) | |
tree | c02650341183775ee94904ddd1e037ae2ab669b1 /sys | |
parent | cfc3af2b90d9b43540d328bb174e8b479e75addd (diff) | |
download | FreeBSD-src-8310a0865410b67ec838360f16defef0a527224a.zip FreeBSD-src-8310a0865410b67ec838360f16defef0a527224a.tar.gz |
The "struct proc" argument to read_random was ill-conceived, and a
hangover from previous experimentation. Remove it. This will clean
up gratuitous needs for forward references and other namespace
pollution.
Moaned about by: bde
Brought to my attention by: bp
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/random/randomdev.c | 2 | ||||
-rw-r--r-- | sys/dev/random/yarrow.c | 2 | ||||
-rw-r--r-- | sys/dev/randomdev/randomdev.c | 2 | ||||
-rw-r--r-- | sys/dev/randomdev/yarrow.c | 2 | ||||
-rw-r--r-- | sys/sys/random.h | 4 |
5 files changed, 5 insertions, 7 deletions
diff --git a/sys/dev/random/randomdev.c b/sys/dev/random/randomdev.c index aba955f..d5730c4 100644 --- a/sys/dev/random/randomdev.c +++ b/sys/dev/random/randomdev.c @@ -109,7 +109,7 @@ random_read(dev_t dev, struct uio *uio, int flag) c = min(uio->uio_resid, PAGE_SIZE); random_buf = (void *)malloc(c, M_TEMP, M_WAITOK); while (uio->uio_resid > 0 && error == 0) { - ret = read_random(uio->uio_procp, random_buf, c); + ret = read_random(random_buf, c); error = uiomove(random_buf, ret, uio); } free(random_buf, M_TEMP); diff --git a/sys/dev/random/yarrow.c b/sys/dev/random/yarrow.c index df34f65..76ae515 100644 --- a/sys/dev/random/yarrow.c +++ b/sys/dev/random/yarrow.c @@ -369,7 +369,7 @@ reseed(int fastslow) } u_int -read_random(struct proc *proc, void *buf, u_int count) +read_random(void *buf, u_int count) { static u_int64_t genval; static int cur = 0; diff --git a/sys/dev/randomdev/randomdev.c b/sys/dev/randomdev/randomdev.c index aba955f..d5730c4 100644 --- a/sys/dev/randomdev/randomdev.c +++ b/sys/dev/randomdev/randomdev.c @@ -109,7 +109,7 @@ random_read(dev_t dev, struct uio *uio, int flag) c = min(uio->uio_resid, PAGE_SIZE); random_buf = (void *)malloc(c, M_TEMP, M_WAITOK); while (uio->uio_resid > 0 && error == 0) { - ret = read_random(uio->uio_procp, random_buf, c); + ret = read_random(random_buf, c); error = uiomove(random_buf, ret, uio); } free(random_buf, M_TEMP); diff --git a/sys/dev/randomdev/yarrow.c b/sys/dev/randomdev/yarrow.c index df34f65..76ae515 100644 --- a/sys/dev/randomdev/yarrow.c +++ b/sys/dev/randomdev/yarrow.c @@ -369,7 +369,7 @@ reseed(int fastslow) } u_int -read_random(struct proc *proc, void *buf, u_int count) +read_random(void *buf, u_int count) { static u_int64_t genval; static int cur = 0; diff --git a/sys/sys/random.h b/sys/sys/random.h index e085cb0..9fadb54 100644 --- a/sys/sys/random.h +++ b/sys/sys/random.h @@ -31,9 +31,7 @@ #ifdef _KERNEL -struct proc; - -u_int read_random(struct proc *, void *, u_int); +u_int read_random(void *, u_int); enum esource { RANDOM_WRITE, RANDOM_KEYBOARD, RANDOM_MOUSE, RANDOM_NET, \ ENTROPYSOURCE }; |