summaryrefslogtreecommitdiffstats
path: root/sys/kern/vfs_aio.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>2002-05-24 06:06:18 +0000
committerpeter <peter@FreeBSD.org>2002-05-24 06:06:18 +0000
commitc952c3ce19c501f738ac8e55f27dafc2acc40e18 (patch)
treea9e078aab9657ae9b1f957e08b409c03f5687d13 /sys/kern/vfs_aio.c
parent631d66bee1b5e3186b84f03f117b52a8d0868509 (diff)
downloadFreeBSD-src-c952c3ce19c501f738ac8e55f27dafc2acc40e18.zip
FreeBSD-src-c952c3ce19c501f738ac8e55f27dafc2acc40e18.tar.gz
Fix warnings. Also, removed an unused variable that I found that was just
initialized and never used afterwards.
Diffstat (limited to 'sys/kern/vfs_aio.c')
-rw-r--r--sys/kern/vfs_aio.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/sys/kern/vfs_aio.c b/sys/kern/vfs_aio.c
index 3e1fe8e..7489c3a 100644
--- a/sys/kern/vfs_aio.c
+++ b/sys/kern/vfs_aio.c
@@ -1640,7 +1640,7 @@ aio_suspend(struct thread *td, struct aio_suspend_args *uap)
cbptr = uap->aiocbp;
for (i = 0; i < uap->nent; i++) {
- cbp = (struct aiocb *)(intptr_t)fuword((caddr_t)&cbptr[i]);
+ cbp = (struct aiocb *)fuword((caddr_t)(uintptr_t)&cbptr[i]);
if (cbp == 0)
continue;
ujoblist[njoblist] = cbp;
@@ -1995,7 +1995,7 @@ lio_listio(struct thread *td, struct lio_listio_args *uap)
nentqueued = 0;
cbptr = uap->acb_list;
for (i = 0; i < uap->nent; i++) {
- iocb = (struct aiocb *)(intptr_t)fuword((caddr_t)&cbptr[i]);
+ iocb = (struct aiocb *)fuword((caddr_t)(uintptr_t)&cbptr[i]);
if (((intptr_t)iocb != -1) && ((intptr_t)iocb != NULL)) {
error = _aio_aqueue(td, iocb, lj, 0);
if (error == 0)
@@ -2028,7 +2028,8 @@ lio_listio(struct thread *td, struct lio_listio_args *uap)
* Fetch address of the control buf pointer in
* user space.
*/
- iocb = (struct aiocb *)(intptr_t)fuword((caddr_t)&cbptr[i]);
+ iocb = (struct aiocb *)
+ fuword((caddr_t)(uintptr_t)&cbptr[i]);
if (((intptr_t)iocb == -1) || ((intptr_t)iocb
== 0))
continue;
@@ -2198,7 +2199,6 @@ aio_waitcomplete(struct thread *td, struct aio_waitcomplete_args *uap)
struct proc *p = td->td_proc;
struct timeval atv;
struct timespec ts;
- struct aiocb **cbptr;
struct kaioinfo *ki;
struct aiocblist *cb = NULL;
int error, s, timo;
@@ -2225,8 +2225,6 @@ aio_waitcomplete(struct thread *td, struct aio_waitcomplete_args *uap)
if (ki == NULL)
return EAGAIN;
- cbptr = uap->aiocbp;
-
for (;;) {
if ((cb = TAILQ_FIRST(&ki->kaio_jobdone)) != 0) {
suword(uap->aiocbp, (uintptr_t)cb->uuaiocb);
OpenPOWER on IntegriCloud