diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2015-02-10 21:56:11 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2015-02-10 21:56:11 +0000 |
commit | fb06ed88b5810f53d16a2f3f90904ed7ea4de07a (patch) | |
tree | 0ad268ca945306e22e87692f6bb02fcd1220d0e4 /sys/dev/rnd.c | |
parent | 4ed4205fc6bdb404dcf67f9f19347eea957f5982 (diff) |
First step towards making uiomove() take a size_t size argument:
- rename uiomove() to uiomovei() and update all its users.
- introduce uiomove(), which is similar to uiomovei() but with a size_t.
- rewrite uiomovei() as an uiomove() wrapper.
ok kettenis@
Diffstat (limited to 'sys/dev/rnd.c')
-rw-r--r-- | sys/dev/rnd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/rnd.c b/sys/dev/rnd.c index a01e491ad28..cd5c6991a04 100644 --- a/sys/dev/rnd.c +++ b/sys/dev/rnd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rnd.c,v 1.170 2015/02/07 01:19:40 deraadt Exp $ */ +/* $OpenBSD: rnd.c,v 1.171 2015/02/10 21:56:09 miod Exp $ */ /* * Copyright (c) 2011 Theo de Raadt. @@ -863,7 +863,7 @@ randomread(dev_t dev, struct uio *uio, int ioflag) chacha_encrypt_bytes(&lctx, buf, buf, n); } else arc4random_buf(buf, n); - ret = uiomove(buf, n, uio); + ret = uiomovei(buf, n, uio); if (ret == 0 && uio->uio_resid > 0) yield(); } @@ -888,7 +888,7 @@ randomwrite(dev_t dev, struct uio *uio, int flags) while (ret == 0 && uio->uio_resid > 0) { int n = min(POOLBYTES, uio->uio_resid); - ret = uiomove(buf, n, uio); + ret = uiomovei(buf, n, uio); if (ret != 0) break; while (n % sizeof(u_int32_t)) |