#include "afs/afs_stats.h" /* statistics */
#include <vm/vm_object.h>
#include <vm/vm_map.h>
-#include <limits.h>
+#include <sys/limits.h>
#if __FreeBSD_version >= 1000030
#include <sys/rwlock.h>
#endif
#include <sys/malloc.h>
#include <sys/namei.h>
#include <sys/unistd.h>
-#include <vm/vm_page.h>
-#include <vm/vm_object.h>
-#include <vm/vm_pager.h>
#if __FreeBSD_version >= 1000030
#include <sys/rwlock.h>
#endif
+#include <vm/vm_page.h>
+#include <vm/vm_object.h>
+#include <vm/vm_pager.h>
#include <vm/vnode_pager.h>
extern int afs_pbuf_freecnt;
}
if (i != ap->a_reqpage) {
+#if __FreeBSD_version >= 1000042
+ vm_page_readahead_finish(m);
+#else
/*
* Whether or not to leave the page activated is up in
* the air, but we should put the page on a page queue
vm_page_free(m);
ma_vm_page_unlock(m);
}
+#endif /* __FreeBSD_version 1000042 */
}
}
ma_vm_page_unlock_queues();
#if defined(AFS_NBSD50_ENV)
if ((fd = fd_getfile(SCARG(uap, fd))) == NULL)
return (EBADF);
+#elif defined(AFS_FBSD100_ENV)
+ if ((uap->fd >= fdp->fd_nfiles)
+ || ((fd = fdp->fd_ofiles[uap->fd].fde_file) == NULL))
+ return EBADF;
#else
if ((uap->fd >= fdp->fd_nfiles)
|| ((fd = fdp->fd_ofiles[uap->fd]) == NULL))
# include <net/if.h>
# if defined(AFS_SUN5_ENV)
# include <sys/varargs.h>
+# elif defined(AFS_FBSD_ENV)
+# include <machine/stdarg.h>
# else
# include <stdarg.h>
# endif
# include "h/protosw.h"
# if defined(AFS_FBSD_ENV)
-# include "limits.h"
+# include "sys/limits.h"
# endif
# ifdef AFS_HPUX_ENV
LIBAFSNONFS= libafs.ko
DEFINES= -DAFSDEBUG -DKERNEL -DAFS -DVICE -DNFS -DUFS -DINET -DQUOTA -DGETMOUNT
-CFLAGS+= $(DEFINES) ${COMMON_INCLUDE} -I@/sys -Imachine
+CFLAGS+= $(DEFINES) ${COMMON_INCLUDE}
INST_LIBAFS = ${DESTDIR}${afskerneldir}/${LIBAFS}
INST_LIBAFSNONFS = ${DESTDIR}${afskerneldir}/${LIBAFSNONFS}
#include "h/errno.h"
#if !(defined(AFS_SUN5_ENV) && defined(KERNEL))
/* if sys/systm.h includes varargs.h some versions of solaris have conflicts */
-#include "stdarg.h"
+# if defined(AFS_FBSD_ENV)
+# include "machine/stdarg.h"
+# else
+# include "stdarg.h"
+# endif
#endif
#ifdef KERNEL
#include "afs/sysincludes.h"