afs: Always define our own osi_timeval32_t
[openafs.git] / src / afs / UKERNEL / afs_usrops.c
index 009d27a..8fbc109 100644 (file)
@@ -26,8 +26,6 @@
 #include "afs/auth.h"
 #include "afs/cellconfig.h"
 #include "afs/vice.h"
-#include "afs/kauth.h"
-#include "afs/kautils.h"
 #include "afs/afsutil.h"
 #include "afs/afs_bypasscache.h"
 #include "rx/rx_globals.h"
@@ -168,13 +166,13 @@ getf(int fd)
  * Every user is a super user
  */
 int
-afs_osi_suser(void *credp)
+afs_osi_suser(afs_ucred_t *credp)
 {
     return 1;
 }
 
 int
-afs_suser(void *credp)
+afs_suser(afs_ucred_t *credp)
 {
     return 1;
 }
@@ -183,12 +181,6 @@ afs_suser(void *credp)
  * These are no-ops in user space
  */
 
-void
-afs_osi_SetTime(osi_timeval_t * atv)
-{
-    return;
-}
-
 /*
  * xflock should never fall through, the only files we know
  * about are AFS files
@@ -944,19 +936,6 @@ afs_osi_Visible(void)
 }
 
 int
-osi_GetTime(struct timeval *tv)
-{
-    gettimeofday(tv, NULL);
-    return 0;
-}
-
-int
-osi_SetTime(struct timeval *tv)
-{
-    return 0;
-}
-
-int
 osi_Active(struct vcache *avc)
 {
     AFS_STATCNT(osi_Active);
@@ -2407,11 +2386,10 @@ uafs_pread_nocache_r(int fd, char *buf, int len, off_t offset)
 
     /* these get freed in PrefetchNoCache, so... */
     bparms = afs_osi_Alloc(sizeof(struct nocache_read_request));
-    bparms->areq = afs_osi_Alloc(sizeof(struct vrequest));
 
-    code = afs_InitReq(bparms->areq, get_user_struct()->u_cred);
+    code = afs_CreateReq(&bparms->areq, get_user_struct()->u_cred);
     if (code) {
-       afs_osi_Free(bparms->areq, sizeof(struct vrequest));
+       afs_DestroyReq(bparms->areq);
        afs_osi_Free(bparms, sizeof(struct nocache_read_request));
        errno = code;
        return -1;
@@ -3055,7 +3033,7 @@ uafs_symlink_r(char *target, char *source)
     attrs.va_uid = afs_cr_uid(get_user_struct()->u_cred);
     attrs.va_gid = afs_cr_gid(get_user_struct()->u_cred);
     code = afs_symlink(VTOAFS(dirP), nameP, &attrs, target, NULL,
-                      get_user_struct()->u_cred);
+                      get_user_struct()->u_cred);
     VN_RELE(dirP);
     if (code != 0) {
        errno = code;