summaryrefslogtreecommitdiff
path: root/lib/libzpool/common/kernel.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libzpool/common/kernel.c')
-rw-r--r--lib/libzpool/common/kernel.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/lib/libzpool/common/kernel.c b/lib/libzpool/common/kernel.c
index 04d530727f5c6..f323bf60b0990 100644
--- a/lib/libzpool/common/kernel.c
+++ b/lib/libzpool/common/kernel.c
@@ -20,7 +20,6 @@
*/
/*
* Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
- * Copyright (c) 2012 by Delphix. All rights reserved.
*/
#include <assert.h>
@@ -46,7 +45,6 @@ int aok;
uint64_t physmem;
vnode_t *rootdir = (vnode_t *)0xabcd1234;
char hw_serial[HW_HOSTID_LEN];
-vmem_t *zio_arena = NULL;
struct utsname utsname = {
"userland", "libzpool", "1", "1", "na"
@@ -426,9 +424,7 @@ vn_rdwr(int uio, vnode_t *vp, void *addr, ssize_t len, offset_t offset,
* To simulate partial disk writes, we split writes into two
* system calls so that the process can be killed in between.
*/
- int sectors = len >> SPA_MINBLOCKSHIFT;
- split = (sectors > 0 ? rand() % sectors : 0) <<
- SPA_MINBLOCKSHIFT;
+ split = (len > 0 ? rand() % len : 0);
iolen = pwrite64(vp->v_fd, addr, split, offset);
iolen += pwrite64(vp->v_fd, (char *)addr + split,
len - split, offset + split);
@@ -871,12 +867,6 @@ crgetuid(cred_t *cr)
return (0);
}
-uid_t
-crgetruid(cred_t *cr)
-{
- return (0);
-}
-
gid_t
crgetgid(cred_t *cr)
{