summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorHans Insulander <hin@cvs.openbsd.org>2002-06-07 04:41:28 +0000
committerHans Insulander <hin@cvs.openbsd.org>2002-06-07 04:41:28 +0000
commit8e2018a6fd860d43426f03bb5960ea84cf3de007 (patch)
tree911f381877c3bff9da225331cb8a982a65880e7b /usr.sbin
parenta33fb3163e6bbb9562e3cd3a5ca26a9515c2a24a (diff)
merge
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/afs/src/cf/auth-modules.m42
-rw-r--r--usr.sbin/afs/src/cf/broken-glob.m42
-rw-r--r--usr.sbin/afs/src/cf/broken-snprintf.m42
-rw-r--r--usr.sbin/afs/src/cf/broken.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-func-lockmgr.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-func-lockstatus.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-func-suser.m43
-rw-r--r--usr.sbin/afs/src/cf/bsd-func-vfs-getnewfsid.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-header-vnode-if-h.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-vfs-busy.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-vfs-object-create.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-vget.m42
-rw-r--r--usr.sbin/afs/src/cf/bsd-vop-lock.m42
-rw-r--r--usr.sbin/afs/src/cf/c-attribute.m43
-rw-r--r--usr.sbin/afs/src/cf/c-function.m42
-rw-r--r--usr.sbin/afs/src/cf/check-declaration.m42
-rw-r--r--usr.sbin/afs/src/cf/check-dirsiz.m42
-rw-r--r--usr.sbin/afs/src/cf/check-getpwnam_r-posix.m42
-rw-r--r--usr.sbin/afs/src/cf/check-glibc.m42
-rw-r--r--usr.sbin/afs/src/cf/check-kafs.m434
-rw-r--r--usr.sbin/afs/src/cf/check-kerberos.m456
-rw-r--r--usr.sbin/afs/src/cf/check-kernel-func.m42
-rw-r--r--usr.sbin/afs/src/cf/check-kernel-funcs.m42
-rw-r--r--usr.sbin/afs/src/cf/check-kernel-var.m42
-rw-r--r--usr.sbin/afs/src/cf/check-kernel-vop-t.m42
-rw-r--r--usr.sbin/afs/src/cf/check-kernel.m410
-rw-r--r--usr.sbin/afs/src/cf/check-lfs.m42
-rw-r--r--usr.sbin/afs/src/cf/check-man.m42
-rw-r--r--usr.sbin/afs/src/cf/check-type-extra.m42
-rw-r--r--usr.sbin/afs/src/cf/check-var.m42
-rw-r--r--usr.sbin/afs/src/cf/check-x.m42
-rw-r--r--usr.sbin/afs/src/cf/check-xau.m42
-rw-r--r--usr.sbin/afs/src/cf/elf-object-format.m42
-rw-r--r--usr.sbin/afs/src/cf/find-func-no-libs.m42
-rw-r--r--usr.sbin/afs/src/cf/find-func-no-libs2.m42
-rw-r--r--usr.sbin/afs/src/cf/find-func.m42
-rw-r--r--usr.sbin/afs/src/cf/find-if-not-broken.m42
-rw-r--r--usr.sbin/afs/src/cf/func-hstrerror-const.m42
-rw-r--r--usr.sbin/afs/src/cf/func-krb-get-default-tkt-root.m42
-rw-r--r--usr.sbin/afs/src/cf/func-krb-get-err-text.m42
-rw-r--r--usr.sbin/afs/src/cf/func-krb-kdctimeofday.m42
-rw-r--r--usr.sbin/afs/src/cf/func-ntohl.m42
-rw-r--r--usr.sbin/afs/src/cf/grok-type.m42
-rw-r--r--usr.sbin/afs/src/cf/have-def.m44
-rw-r--r--usr.sbin/afs/src/cf/have-kernel-struct-field.m46
-rw-r--r--usr.sbin/afs/src/cf/have-linux-kernel-type.m42
-rw-r--r--usr.sbin/afs/src/cf/have-linux-kernel-types.m42
-rw-r--r--usr.sbin/afs/src/cf/have-pragma-weak.m42
-rw-r--r--usr.sbin/afs/src/cf/have-struct-field.m46
-rw-r--r--usr.sbin/afs/src/cf/have-type.m42
-rw-r--r--usr.sbin/afs/src/cf/have-types.m42
-rw-r--r--usr.sbin/afs/src/cf/header-dirent-dir-h.m42
-rw-r--r--usr.sbin/afs/src/cf/kernel-have-def.m44
-rw-r--r--usr.sbin/afs/src/cf/kernel.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-bigendian.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-find-db.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-func-getcwd-broken.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-ipv6.m4188
-rw-r--r--usr.sbin/afs/src/cf/krb-prog-ln-s.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-prog-ranlib.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-prog-yacc.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-struct-sockaddr-sa-len.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-struct-spwd.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-struct-winsize.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-sys-aix.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-sys-nextstep.m42
-rw-r--r--usr.sbin/afs/src/cf/krb-version.m42
-rw-r--r--usr.sbin/afs/src/cf/linux-func-d_alloc_root-two_args.m42
-rw-r--r--usr.sbin/afs/src/cf/linux-func-devfs-register-eleven-args.m42
-rw-r--r--usr.sbin/afs/src/cf/linux-func-init-mutex.m47
-rw-r--r--usr.sbin/afs/src/cf/linux-func-init-wait-queue-head.m48
-rw-r--r--usr.sbin/afs/src/cf/linux-type-wait-queue-head.m42
-rw-r--r--usr.sbin/afs/src/cf/mips-abi.m42
-rw-r--r--usr.sbin/afs/src/cf/misc.m42
-rw-r--r--usr.sbin/afs/src/cf/need-proto.m42
-rw-r--r--usr.sbin/afs/src/cf/osf-func-ubc-lookup.m42
-rw-r--r--usr.sbin/afs/src/cf/osfc2.m42
-rw-r--r--usr.sbin/afs/src/cf/prog-cc-flags.m42
-rw-r--r--usr.sbin/afs/src/cf/proto-compat.m42
-rw-r--r--usr.sbin/afs/src/cf/shared-libs.m42
-rw-r--r--usr.sbin/afs/src/cf/test-package.m42
-rw-r--r--usr.sbin/afs/src/cf/try-compile-kernel.m47
-rw-r--r--usr.sbin/afs/src/cf/try-cpp-kernel.m42
-rw-r--r--usr.sbin/afs/src/cf/type-iovec.m42
-rw-r--r--usr.sbin/afs/src/cf/type-krb-principal.m42
-rw-r--r--usr.sbin/afs/src/cf/type-msghdr.m42
-rw-r--r--usr.sbin/afs/src/cf/wflags.m42
-rw-r--r--usr.sbin/afs/src/conf/CellServDB43
-rw-r--r--usr.sbin/afs/src/conf/Makefile.in3
-rw-r--r--usr.sbin/afs/src/conf/arla.conf15
-rw-r--r--usr.sbin/afs/src/conf/arla.spec.in21
-rw-r--r--usr.sbin/afs/src/conf/bos.conf53
-rw-r--r--usr.sbin/afs/src/conf/services2
-rw-r--r--usr.sbin/afs/src/doc/Makefile.in18
-rw-r--r--usr.sbin/afs/src/doc/ack.texi110
-rw-r--r--usr.sbin/afs/src/doc/ack.texi.in12
-rw-r--r--usr.sbin/afs/src/doc/afs-basics.texi142
-rw-r--r--usr.sbin/afs/src/doc/arla.info955
-rw-r--r--usr.sbin/afs/src/doc/arla.texi171
-rw-r--r--usr.sbin/afs/src/doc/authors.texi13
-rw-r--r--usr.sbin/afs/src/doc/debugging.texi277
-rw-r--r--usr.sbin/afs/src/doc/intro.texi37
-rw-r--r--usr.sbin/afs/src/doc/oddities.texi6
-rw-r--r--usr.sbin/afs/src/doc/partsofarla.texi8
-rw-r--r--usr.sbin/afs/src/doc/porting.texi65
-rw-r--r--usr.sbin/afs/src/doc/servers.texi33
-rw-r--r--usr.sbin/afs/src/doc/storage.texi88
-rw-r--r--usr.sbin/afs/src/doc/timeline.texi17
-rw-r--r--usr.sbin/afs/src/doc/tools.texi14
-rw-r--r--usr.sbin/afs/src/doc/xfs.txt2
-rw-r--r--usr.sbin/afs/src/include/Makefile.in15
-rw-r--r--usr.sbin/afs/src/include/bits.c4
-rw-r--r--usr.sbin/afs/src/include/stds.h9
-rw-r--r--usr.sbin/afs/src/lib/Makefile.in6
-rw-r--r--usr.sbin/afs/src/lib/acl/Makefile.in4
-rw-r--r--usr.sbin/afs/src/lib/acl/acl.h9
-rw-r--r--usr.sbin/afs/src/lib/acl/acl_files.c2
-rw-r--r--usr.sbin/afs/src/lib/bufdir/Makefile.in5
-rw-r--r--usr.sbin/afs/src/lib/bufdir/afs_dir.h9
-rw-r--r--usr.sbin/afs/src/lib/bufdir/fbuf.c39
-rw-r--r--usr.sbin/afs/src/lib/bufdir/fbuf.h9
-rw-r--r--usr.sbin/afs/src/lib/bufdir/fdir.c9
-rw-r--r--usr.sbin/afs/src/lib/bufdir/fdir.h9
-rw-r--r--usr.sbin/afs/src/lib/cmd/Makefile.in7
-rw-r--r--usr.sbin/afs/src/lib/cmd/cmd.32
-rw-r--r--usr.sbin/afs/src/lib/cmd/cmd.c7
-rw-r--r--usr.sbin/afs/src/lib/cmd/cmd.h2
-rw-r--r--usr.sbin/afs/src/lib/cmd/frame.ctx2
-rw-r--r--usr.sbin/afs/src/lib/cmd/testc.c42
-rw-r--r--usr.sbin/afs/src/lib/cmd/testc.ctx2
-rw-r--r--usr.sbin/afs/src/lib/editline/ChangeLog5
-rw-r--r--usr.sbin/afs/src/lib/editline/Makefile.in7
-rw-r--r--usr.sbin/afs/src/lib/editline/README2
-rw-r--r--usr.sbin/afs/src/lib/editline/complete.c2
-rw-r--r--usr.sbin/afs/src/lib/editline/edit_compat.c2
-rw-r--r--usr.sbin/afs/src/lib/editline/editline.32
-rw-r--r--usr.sbin/afs/src/lib/editline/editline.c108
-rw-r--r--usr.sbin/afs/src/lib/editline/editline.h2
-rw-r--r--usr.sbin/afs/src/lib/editline/sysunix.c2
-rw-r--r--usr.sbin/afs/src/lib/editline/testit.c2
-rw-r--r--usr.sbin/afs/src/lib/editline/unix.h2
-rw-r--r--usr.sbin/afs/src/lib/ko/Makefile.in23
-rw-r--r--usr.sbin/afs/src/lib/ko/afsconf.c18
-rw-r--r--usr.sbin/afs/src/lib/ko/auth.c9
-rw-r--r--usr.sbin/afs/src/lib/ko/auth.h9
-rw-r--r--usr.sbin/afs/src/lib/ko/cellconfig.h9
-rw-r--r--usr.sbin/afs/src/lib/ko/gensysname.c85
-rw-r--r--usr.sbin/afs/src/lib/ko/ko.h38
-rw-r--r--usr.sbin/afs/src/lib/ko/ko_locl.h13
-rw-r--r--usr.sbin/afs/src/lib/ko/kocell.c460
-rw-r--r--usr.sbin/afs/src/lib/ko/koerror.c56
-rw-r--r--usr.sbin/afs/src/lib/ko/kotest.c17
-rw-r--r--usr.sbin/afs/src/lib/ko/part.c9
-rw-r--r--usr.sbin/afs/src/lib/ko/part.h9
-rw-r--r--usr.sbin/afs/src/lib/ko/ports.c32
-rw-r--r--usr.sbin/afs/src/lib/ko/ports.h9
-rw-r--r--usr.sbin/afs/src/lib/ko/vlmisc.c67
-rw-r--r--usr.sbin/afs/src/lib/sl/ChangeLog8
-rw-r--r--usr.sbin/afs/src/lib/sl/Makefile.in16
-rw-r--r--usr.sbin/afs/src/lib/sl/lex.l4
-rw-r--r--usr.sbin/afs/src/lib/sl/make_cmds.c8
-rw-r--r--usr.sbin/afs/src/lib/sl/make_cmds.h2
-rw-r--r--usr.sbin/afs/src/lib/sl/parse.y2
-rw-r--r--usr.sbin/afs/src/lib/sl/sl.c2
-rw-r--r--usr.sbin/afs/src/lib/sl/sl.h2
-rw-r--r--usr.sbin/afs/src/lib/sl/sl_locl.h2
-rw-r--r--usr.sbin/afs/src/lib/sl/ss.c2
-rw-r--r--usr.sbin/afs/src/lib/sl/ss.h2
-rw-r--r--usr.sbin/afs/src/lwp/Makefile.in14
-rw-r--r--usr.sbin/afs/src/lwp/fasttime.c2
-rw-r--r--usr.sbin/afs/src/lwp/iomgr.c2
-rw-r--r--usr.sbin/afs/src/lwp/lock.c3
-rw-r--r--usr.sbin/afs/src/lwp/lock.h100
-rw-r--r--usr.sbin/afs/src/lwp/lwp_asm.c51
-rw-r--r--usr.sbin/afs/src/lwp/lwp_asm.h12
-rw-r--r--usr.sbin/afs/src/lwp/lwp_elf.h10
-rw-r--r--usr.sbin/afs/src/lwp/make-process.o.sh.in5
-rw-r--r--usr.sbin/afs/src/lwp/plwp.c2
-rw-r--r--usr.sbin/afs/src/lwp/plwp.h5
-rw-r--r--usr.sbin/afs/src/lwp/preempt.c2
-rw-r--r--usr.sbin/afs/src/lwp/preempt.h6
-rw-r--r--usr.sbin/afs/src/lwp/process-vpp.s2
-rw-r--r--usr.sbin/afs/src/lwp/process.aix22.S2
-rw-r--r--usr.sbin/afs/src/lwp/process.alpha.S2
-rw-r--r--usr.sbin/afs/src/lwp/process.i386.S2
-rw-r--r--usr.sbin/afs/src/lwp/process.ibm032.S2
-rw-r--r--usr.sbin/afs/src/lwp/process.m68k.S6
-rw-r--r--usr.sbin/afs/src/lwp/process.mips.S2
-rw-r--r--usr.sbin/afs/src/lwp/process.ppc.S27
-rw-r--r--usr.sbin/afs/src/lwp/process.rios.S2
-rw-r--r--usr.sbin/afs/src/lwp/process.sparc.S10
-rw-r--r--usr.sbin/afs/src/lwp/process.vax.S2
-rw-r--r--usr.sbin/afs/src/lwp/q.c2
-rw-r--r--usr.sbin/afs/src/lwp/q.h2
-rw-r--r--usr.sbin/afs/src/lwp/testlwp.c57
-rw-r--r--usr.sbin/afs/src/lwp/testprocess.c2
-rw-r--r--usr.sbin/afs/src/lwp/timer.c2
197 files changed, 2949 insertions, 1220 deletions
diff --git a/usr.sbin/afs/src/cf/auth-modules.m4 b/usr.sbin/afs/src/cf/auth-modules.m4
index 59f746e6d78..efbd6de893f 100644
--- a/usr.sbin/afs/src/cf/auth-modules.m4
+++ b/usr.sbin/afs/src/cf/auth-modules.m4
@@ -1,4 +1,4 @@
-dnl $Id: auth-modules.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: auth-modules.m4,v 1.1 1999/05/15 22:45:18 assar Exp $
dnl
dnl Figure what authentication modules should be built
diff --git a/usr.sbin/afs/src/cf/broken-glob.m4 b/usr.sbin/afs/src/cf/broken-glob.m4
index d158e0d5925..57ad1856df7 100644
--- a/usr.sbin/afs/src/cf/broken-glob.m4
+++ b/usr.sbin/afs/src/cf/broken-glob.m4
@@ -1,4 +1,4 @@
-dnl $Id: broken-glob.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: broken-glob.m4,v 1.1 1999/05/15 22:45:18 assar Exp $
dnl
dnl check for glob(3)
dnl
diff --git a/usr.sbin/afs/src/cf/broken-snprintf.m4 b/usr.sbin/afs/src/cf/broken-snprintf.m4
index 3b31ffa8a19..e73c0dc6cae 100644
--- a/usr.sbin/afs/src/cf/broken-snprintf.m4
+++ b/usr.sbin/afs/src/cf/broken-snprintf.m4
@@ -1,4 +1,4 @@
-dnl $Id: broken-snprintf.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: broken-snprintf.m4,v 1.1 1999/05/15 22:45:18 assar Exp $
dnl
AC_DEFUN(AC_BROKEN_SNPRINTF, [
AC_CACHE_CHECK(for working snprintf,ac_cv_func_snprintf_working,
diff --git a/usr.sbin/afs/src/cf/broken.m4 b/usr.sbin/afs/src/cf/broken.m4
index 74a3f351edd..b6d0936f871 100644
--- a/usr.sbin/afs/src/cf/broken.m4
+++ b/usr.sbin/afs/src/cf/broken.m4
@@ -1,4 +1,4 @@
-dnl $Id: broken.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: broken.m4,v 1.1 1999/05/15 22:45:18 assar Exp $
dnl
dnl
dnl Same as AC _REPLACE_FUNCS, just define HAVE_func if found in normal
diff --git a/usr.sbin/afs/src/cf/bsd-func-lockmgr.m4 b/usr.sbin/afs/src/cf/bsd-func-lockmgr.m4
index f9064df82c1..ce13fcbf7bd 100644
--- a/usr.sbin/afs/src/cf/bsd-func-lockmgr.m4
+++ b/usr.sbin/afs/src/cf/bsd-func-lockmgr.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-func-lockmgr.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: bsd-func-lockmgr.m4,v 1.3 2000/03/24 03:36:23 assar Exp $
dnl
AC_DEFUN(AC_BSD_FUNC_LOCKMGR, [
diff --git a/usr.sbin/afs/src/cf/bsd-func-lockstatus.m4 b/usr.sbin/afs/src/cf/bsd-func-lockstatus.m4
index 78bcb9f7a1c..d7a709d977c 100644
--- a/usr.sbin/afs/src/cf/bsd-func-lockstatus.m4
+++ b/usr.sbin/afs/src/cf/bsd-func-lockstatus.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-func-lockstatus.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: bsd-func-lockstatus.m4,v 1.6 2000/03/24 03:39:42 assar Exp $
dnl
AC_DEFUN(AC_BSD_FUNC_LOCKSTATUS, [
diff --git a/usr.sbin/afs/src/cf/bsd-func-suser.m4 b/usr.sbin/afs/src/cf/bsd-func-suser.m4
index c55e73b157c..72883773b61 100644
--- a/usr.sbin/afs/src/cf/bsd-func-suser.m4
+++ b/usr.sbin/afs/src/cf/bsd-func-suser.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-func-suser.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: bsd-func-suser.m4,v 1.4 2000/11/01 02:09:16 assar Exp $
dnl
AC_DEFUN(AC_BSD_FUNC_SUSER, [
@@ -13,6 +13,7 @@ AC_TRY_COMPILE_KERNEL([
#include <sys/param.h>
#include <sys/time.h>
#include <sys/proc.h>
+#include <sys/systm.h>
], [suser(NULL, NULL)],
ac_cv_func_suser_two_args=yes,
ac_cv_func_suser_two_args=no))
diff --git a/usr.sbin/afs/src/cf/bsd-func-vfs-getnewfsid.m4 b/usr.sbin/afs/src/cf/bsd-func-vfs-getnewfsid.m4
index f47531501c9..b0fa3470b9c 100644
--- a/usr.sbin/afs/src/cf/bsd-func-vfs-getnewfsid.m4
+++ b/usr.sbin/afs/src/cf/bsd-func-vfs-getnewfsid.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-func-vfs-getnewfsid.m4,v 1.1 2000/09/11 14:40:44 art Exp $
+dnl $KTH: bsd-func-vfs-getnewfsid.m4,v 1.2 2000/05/23 14:30:43 assar Exp $
dnl
AC_DEFUN(AC_BSD_FUNC_VFS_GETNEWFSID, [
diff --git a/usr.sbin/afs/src/cf/bsd-header-vnode-if-h.m4 b/usr.sbin/afs/src/cf/bsd-header-vnode-if-h.m4
index 03279217378..d5cfe2820f3 100644
--- a/usr.sbin/afs/src/cf/bsd-header-vnode-if-h.m4
+++ b/usr.sbin/afs/src/cf/bsd-header-vnode-if-h.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-header-vnode-if-h.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: bsd-header-vnode-if-h.m4,v 1.2 2000/03/16 10:34:32 assar Exp $
dnl
AC_DEFUN(AC_BSD_HEADER_VNODE_IF_H, [
diff --git a/usr.sbin/afs/src/cf/bsd-vfs-busy.m4 b/usr.sbin/afs/src/cf/bsd-vfs-busy.m4
index 15ef052ec3b..fdc694fd94c 100644
--- a/usr.sbin/afs/src/cf/bsd-vfs-busy.m4
+++ b/usr.sbin/afs/src/cf/bsd-vfs-busy.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-vfs-busy.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: bsd-vfs-busy.m4,v 1.3 2000/02/20 03:06:43 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/bsd-vfs-object-create.m4 b/usr.sbin/afs/src/cf/bsd-vfs-object-create.m4
index 8b338060047..f7bd455bf8d 100644
--- a/usr.sbin/afs/src/cf/bsd-vfs-object-create.m4
+++ b/usr.sbin/afs/src/cf/bsd-vfs-object-create.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-vfs-object-create.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: bsd-vfs-object-create.m4,v 1.1 1999/05/15 22:45:19 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/bsd-vget.m4 b/usr.sbin/afs/src/cf/bsd-vget.m4
index f6f40a6a0eb..7131830dfd7 100644
--- a/usr.sbin/afs/src/cf/bsd-vget.m4
+++ b/usr.sbin/afs/src/cf/bsd-vget.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-vget.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: bsd-vget.m4,v 1.4 2000/06/12 06:13:52 assar Exp $
dnl
AC_DEFUN(AC_BSD_FUNC_VGET, [
diff --git a/usr.sbin/afs/src/cf/bsd-vop-lock.m4 b/usr.sbin/afs/src/cf/bsd-vop-lock.m4
index 31155761d32..14fa85dea2b 100644
--- a/usr.sbin/afs/src/cf/bsd-vop-lock.m4
+++ b/usr.sbin/afs/src/cf/bsd-vop-lock.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: bsd-vop-lock.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: bsd-vop-lock.m4,v 1.3 2000/01/30 23:56:45 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/c-attribute.m4 b/usr.sbin/afs/src/cf/c-attribute.m4
index 39d5b3a1f00..d7fe01df296 100644
--- a/usr.sbin/afs/src/cf/c-attribute.m4
+++ b/usr.sbin/afs/src/cf/c-attribute.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: c-attribute.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: c-attribute.m4,v 1.4 2000/10/10 22:11:31 lha Exp $
dnl
dnl
@@ -28,6 +28,7 @@ bar(void)
exit (1);
}
+
],
ac_cv___attribute__=yes,
ac_cv___attribute__=no)])
diff --git a/usr.sbin/afs/src/cf/c-function.m4 b/usr.sbin/afs/src/cf/c-function.m4
index 50660b16f5b..4676977a347 100644
--- a/usr.sbin/afs/src/cf/c-function.m4
+++ b/usr.sbin/afs/src/cf/c-function.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: c-function.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: c-function.m4,v 1.1 1999/05/15 22:45:20 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/check-declaration.m4 b/usr.sbin/afs/src/cf/check-declaration.m4
index e6203a8e181..703e7bafddf 100644
--- a/usr.sbin/afs/src/cf/check-declaration.m4
+++ b/usr.sbin/afs/src/cf/check-declaration.m4
@@ -1,4 +1,4 @@
-dnl $Id: check-declaration.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: check-declaration.m4,v 1.2 1999/10/06 03:15:53 assar Exp $
dnl
dnl
dnl Check if we need the declaration of a variable
diff --git a/usr.sbin/afs/src/cf/check-dirsiz.m4 b/usr.sbin/afs/src/cf/check-dirsiz.m4
index 0589a6244e5..c11a75b7194 100644
--- a/usr.sbin/afs/src/cf/check-dirsiz.m4
+++ b/usr.sbin/afs/src/cf/check-dirsiz.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-dirsiz.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: check-dirsiz.m4,v 1.1 1999/05/15 22:45:21 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/check-getpwnam_r-posix.m4 b/usr.sbin/afs/src/cf/check-getpwnam_r-posix.m4
index cc70e9549bc..b3287735249 100644
--- a/usr.sbin/afs/src/cf/check-getpwnam_r-posix.m4
+++ b/usr.sbin/afs/src/cf/check-getpwnam_r-posix.m4
@@ -1,4 +1,4 @@
-dnl $Id: check-getpwnam_r-posix.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: check-getpwnam_r-posix.m4,v 1.1 1999/05/15 22:45:21 assar Exp $
dnl
dnl check for getpwnam_r, and if it's posix or not
diff --git a/usr.sbin/afs/src/cf/check-glibc.m4 b/usr.sbin/afs/src/cf/check-glibc.m4
index 5a825b2a499..4107057f704 100644
--- a/usr.sbin/afs/src/cf/check-glibc.m4
+++ b/usr.sbin/afs/src/cf/check-glibc.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-glibc.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: check-glibc.m4,v 1.2 2000/03/14 00:04:09 assar Exp $
dnl
dnl
dnl test for GNU libc
diff --git a/usr.sbin/afs/src/cf/check-kafs.m4 b/usr.sbin/afs/src/cf/check-kafs.m4
index 5f5871e6f7d..83b450b4ac0 100644
--- a/usr.sbin/afs/src/cf/check-kafs.m4
+++ b/usr.sbin/afs/src/cf/check-kafs.m4
@@ -1,9 +1,21 @@
dnl
-dnl $Id: check-kafs.m4,v 1.1 2000/09/11 14:40:45 art Exp $
+dnl $KTH: check-kafs.m4,v 1.7.2.1 2001/04/16 23:07:48 lha Exp $
dnl
dnl check for libkafs/krbafs
dnl
+dnl check_kafs_fluff(LIB_DIR,LIB_LIBS)
+define(check_kafs_fluff,[
+for b in "kafs" "krbafs"; do
+ LIBS="$saved_LIBS ${KAFS_LIBS_FLAGS} $1 -l$b $2"
+ AC_TRY_LINK([],
+ [k_hasafs()],
+ [ac_cv_funclib_k_hasafs=yes
+ ac_cv_libkafs_flags="$KAFS_LIBS_FLAGS $1 -l$b $2"
+ break 2],
+ [ac_cv_funclib_k_hasafs=no])
+done])
+
AC_DEFUN(AC_CHECK_KAFS,[
AC_ARG_WITH(krbafs,
@@ -22,20 +34,16 @@ AC_CACHE_CHECK([for libkafs/libkrbafs],
saved_LIBS="$LIBS"
-for a in "$KRB4_LIB_FLAGS" \
- "$KRB5_LIB_FLAGS" \
- "$KRB5_LIB_FLAGS $KRB4_LIB_FLAGS" ; do
- for b in "kafs" "krbafs"; do
- LIBS="$saved_LIBS ${KAFS_LIBS_FLAGS} $a -l$b"
- AC_TRY_LINK([],
- [k_hasafs();],
- [ac_cv_funclib_k_hasafs=yes
- ac_cv_libkafs_flags="$KAFS_LIBS_FLAGS $a -l$b"
- break 2],
- [ac_cv_funclib_k_hasafs=no])
- done
+for a in "foo" ; do
+check_kafs_fluff([],[])
+check_kafs_fluff([${KRB4_LIB_DIR}],[${KRB4_LIB_LIBS}])
+check_kafs_fluff([${KRB5_LIB_DIR}],[${KRB5_LIB_LIBS}])
+check_kafs_fluff([${KRB4_LIB_DIR} ${KRB5_LIB_DIR}],
+[${KRB5_LIB_LIBS} ${KRB4_LIB_LIBS}])
done
+undefine([check_kafs_fluff])
+
LIBS="$saved_LIBS"])
if test "X$ac_cv_funclib_k_hasafs" != "Xno"; then
diff --git a/usr.sbin/afs/src/cf/check-kerberos.m4 b/usr.sbin/afs/src/cf/check-kerberos.m4
index fe343e6928e..c63e7216ca4 100644
--- a/usr.sbin/afs/src/cf/check-kerberos.m4
+++ b/usr.sbin/afs/src/cf/check-kerberos.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-kerberos.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-kerberos.m4,v 1.38.2.2 2001/10/23 23:27:23 ahltorp Exp $
dnl
dnl Check if the dog is alive
dnl
@@ -18,10 +18,12 @@ dnl Set:
dnl ac_cv_found_krb4=[yes|no]
dnl KRB4_{LIB|INC}_DIR
dnl KRB4_{LIB,INC}_FLAGS
+dnl KRB4_LIB_LIBS
dnl
dnl ac_cv_found_krb5=[yes|no]
dnl KRB5_{LIB|INC}_DIR
dnl KRB5_{LIB,INC}_FLAGS
+dnl KRB5_LIB_LIBS
dnl
dnl
dnl Check order
@@ -227,11 +229,11 @@ if test "X$ac_cv_found_krb5" = "Xyes"; then
if test "X$KRB5_INC_DIR" != "X" ; then
KRB5_INC_FLAGS="-I${KRB5_INC_DIR}"
fi
- KRB5_LIB_FLAGS=
if test "X$KRB5_LIB_DIR" != "X" ; then
- KRB5_LIB_FLAGS="-L${KRB5_LIB_DIR}"
+ KRB5_LIB_DIR="-L$KRB5_LIB_DIR"
fi
- KRB5_LIB_FLAGS="$KRB5_LIB_FLAGS -lkrb5 -lcom_err $ac_cv_krb5_extralib"
+ KRB5_LIB_LIBS="-lkrb5 -lcom_err $ac_cv_krb5_extralib"
+ KRB5_LIB_FLAGS="$KRB5_LIB_DIR $KRB5_LIB_LIBS"
fi
]) dnl KRB5 VARS
@@ -245,11 +247,11 @@ if test "X$ac_cv_found_krb4" = "Xyes"; then
if test "X$KRB4_INC_DIR" != "X" ; then
KRB4_INC_FLAGS="-I${KRB4_INC_DIR}"
fi
- KRB4_LIB_FLAGS="$ac_cv_krb4_extralib"
+ KRB4_LIB_LIBS="$ac_cv_krb4_extralib"
if test "X$KRB4_LIB_DIR" != "X" ; then
- KRB4_LIB_FLAGS="-L${KRB4_LIB_DIR} ${KRB4_LIB_FLAGS}"
+ KRB4_LIB_DIR="-L${KRB4_LIB_DIR}"
fi
-
+ KRB4_LIB_FLAGS="$KRB4_LIB_DIR $KRB4_LIB_LIBS"
fi
]) dnl KRB4 VARS
@@ -283,6 +285,7 @@ ifelse(-1,regexp($1,5),[],[
AC_SUBST(KRB5_LIB_DIR)
AC_SUBST(KRB5_INC_DIR)
AC_SUBST(KRB5_INC_FLAGS)
+AC_SUBST(KRB5_LIB_LIBS)
AC_SUBST(KRB5_LIB_FLAGS)]) dnl END KRB5 - export
dnl KRB 4 - export
@@ -298,6 +301,7 @@ fi
AC_SUBST(KRB4_LIB_DIR)
AC_SUBST(KRB4_INC_DIR)
AC_SUBST(KRB4_INC_FLAGS)
+AC_SUBST(KRB4_LIB_LIBS)
AC_SUBST(KRB4_LIB_FLAGS)]) dnl END KRB4 - export
]) dnl END AC_CHECK_KERBEROS end of this short function
@@ -351,11 +355,13 @@ dnl
AC_DEFUN(AC_KRB4_LIB_WHERE1, [
saved_LIBS=$LIBS
+ac_cv_found_krb4_lib=no
for a in "-lkrb -ldes" dnl kth-krb && mit-krb
- "-lkrb -ldes -lroken" dnl kth-krb in nbsd
- "-lkrb -ldes -lroken -lcom_err" dnl kth-krb in nbsd for real
+ "-lkrb -ldes $LIB_roken" dnl kth-krb in nbsd
+ "-lkrb -ldes $LIB_roken -lcom_err" dnl kth-krb in nbsd for real
"-lkrb -ldes -lcom_err" dnl kth-krb in fbsd
"-lkrb -ldes -lcom_err -lcrypt" dnl CNS q96 à la SCS
+ "-lkrb -lcrypto" dnl kth-krb with openssl
; do
LIBS="$saved_LIBS"
if test "X$1" != "X"; then
@@ -367,21 +373,25 @@ for a in "-lkrb -ldes" dnl kth-krb && mit-krb
[ac_cv_found_krb4_lib=yes
ac_cv_krb4_extralib="$a"
ac_cv_found_krb4=yes
- break],
- [ac_cv_found_krb4_lib=no
+ break])
+done
+
if test "$ac_cv_found_krb4_lib" = "no"; then
+ for a in "-lkrb4 -ldes425 -lkrb5 -lcom_err $ac_cv_krb5_extralib" dnl
+ "-lkrb4 -ldes524 -lkrb5 -lcom_err $ac_cv_krb5_extralib" dnl
+ ; do
+ LIBS="$saved_LIBS"
if test "X$1" != "X"; then
- LIBS="$saved_LIBS -L$1"
+ LIBS="$LIBS -L$1"
fi
- LIBS="$LIBS -lkrb4 -ldes425 -lkrb5 -lcom_err $ac_cv_krb5_extralib"
+ LIBS="$LIBS $a"
AC_TRY_LINK([],
[dest_tkt();],
[ac_cv_found_krb4_lib=compat
- ac_cv_krb4_extralib="-lkrb4 -ldes425 -lkrb5 -lcom_err $ac_cv_krb5_extralib"
- break],
- [ac_cv_found_krb4_lib=no])
- fi])
+ ac_cv_krb4_extralib="$a"
+ break])
done
+fi
LIBS=$saved_LIBS
])
@@ -438,12 +448,12 @@ AC_DEFUN(AC_KRB5_LIB_WHERE1, [
saved_LIBS=$LIBS
for a in "-lk5crypto -lcom_err" dnl new mit krb
"-lcrypto -lcom_err" dnl old mit krb
- "-lasn1 -ldes -lroken" dnl heimdal w/ roken w/o dep on db
- "-lasn1 -ldes -lroken -lresolv" dnl heimdal w/ roken w/o dep on db w/ dep on resolv
- "-lasn1 -lcrypto -lcom_err -lroken" dnl heimdal-BSD w/ roken w/o dep on db
- "-lasn1 -ldes -lroken -ldb" dnl heimdal w/ roken w/ dep on db
- "-lasn1 -ldes -lroken -ldb -lresolv" dnl heimdal w/ roken w/ dep on db w/ dep on resolv
- "-lasn1 -lcrypto -lcom_err -lroken -ldb" dnl heimdal-BSD w/ roken w/ dep on db
+ "-lasn1 -ldes $LIB_roken" dnl heimdal w/ roken w/o dep on db
+ "-lasn1 -ldes $LIB_roken -lresolv" dnl heimdal w/ roken w/o dep on db w/ dep on resolv
+ "-lasn1 -lcrypto -lcom_err $LIB_roken" dnl heimdal-BSD w/ roken w/o dep on db
+ "-lasn1 -ldes $LIB_roken -ldb" dnl heimdal w/ roken w/ dep on db
+ "-lasn1 -ldes $LIB_roken -ldb -lresolv" dnl heimdal w/ roken w/ dep on db w/ dep on resolv
+ "-lasn1 -lcrypto -lcom_err $LIB_roken -ldb" dnl heimdal-BSD w/ roken w/ dep on db
; do
LIBS="$saved_LIBS"
if test "X$1" != "X"; then
diff --git a/usr.sbin/afs/src/cf/check-kernel-func.m4 b/usr.sbin/afs/src/cf/check-kernel-func.m4
index bcf2bc814f8..f21db505f2e 100644
--- a/usr.sbin/afs/src/cf/check-kernel-func.m4
+++ b/usr.sbin/afs/src/cf/check-kernel-func.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-kernel-func.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-kernel-func.m4,v 1.2 1999/08/09 23:02:01 assar Exp $
dnl
dnl AC_CHECK_KERNEL_FUNC(func, param, [includes])
diff --git a/usr.sbin/afs/src/cf/check-kernel-funcs.m4 b/usr.sbin/afs/src/cf/check-kernel-funcs.m4
index 56ada315768..6b4ee2b15a4 100644
--- a/usr.sbin/afs/src/cf/check-kernel-funcs.m4
+++ b/usr.sbin/afs/src/cf/check-kernel-funcs.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-kernel-funcs.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-kernel-funcs.m4,v 1.2 1999/08/09 23:02:45 assar Exp $
dnl
dnl AC_CHECK_KERNEL_FUNCS(functions...)
diff --git a/usr.sbin/afs/src/cf/check-kernel-var.m4 b/usr.sbin/afs/src/cf/check-kernel-var.m4
index 2775fdf1244..34c1f73e84d 100644
--- a/usr.sbin/afs/src/cf/check-kernel-var.m4
+++ b/usr.sbin/afs/src/cf/check-kernel-var.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-kernel-var.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-kernel-var.m4,v 1.2 2000/01/25 20:31:24 assar Exp $
dnl
dnl AC_CHECK_KERNEL_VAR(var, type, [includes])
diff --git a/usr.sbin/afs/src/cf/check-kernel-vop-t.m4 b/usr.sbin/afs/src/cf/check-kernel-vop-t.m4
index 16c44da5e6e..c05e6f3ebd8 100644
--- a/usr.sbin/afs/src/cf/check-kernel-vop-t.m4
+++ b/usr.sbin/afs/src/cf/check-kernel-vop-t.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-kernel-vop-t.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-kernel-vop-t.m4,v 1.1 1999/05/15 22:45:22 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/check-kernel.m4 b/usr.sbin/afs/src/cf/check-kernel.m4
index 179f772ab2a..17051885997 100644
--- a/usr.sbin/afs/src/cf/check-kernel.m4
+++ b/usr.sbin/afs/src/cf/check-kernel.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-kernel.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-kernel.m4,v 1.6.2.2 2001/04/27 11:43:40 ahltorp Exp $
dnl
dnl there are two different heuristics for doing the kernel tests
@@ -11,12 +11,18 @@ AC_DEFUN(AC_CHECK_KERNEL,
[AC_MSG_CHECKING([for $1 in kernel])
AC_CACHE_VAL($2,
[
-if test "$target_os" = "macos10.0"; then
+if expr "$target_os" : "darwin" > /dev/null 2>&1; then
if nm $KERNEL | egrep "\\<_?$1\\>" >/dev/null 2>&1; then
eval "$2=yes"
else
eval "$2=no"
fi
+elif expr "$target_os" : "osf" >/dev/null 2>&1; then
+ if nm $KERNEL | egrep "^$1 " > /dev/null 2>&1; then
+ eval "$2=yes"
+ else
+ eval "$2=no"
+ fi
else
cat > conftest.$ac_ext <<EOF
dnl This sometimes fails to find confdefs.h, for some reason.
diff --git a/usr.sbin/afs/src/cf/check-lfs.m4 b/usr.sbin/afs/src/cf/check-lfs.m4
index cceac950592..4eca32f7e3e 100644
--- a/usr.sbin/afs/src/cf/check-lfs.m4
+++ b/usr.sbin/afs/src/cf/check-lfs.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: check-lfs.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-lfs.m4,v 1.2 2000/03/14 00:04:10 assar Exp $
dnl
AC_DEFUN(AC_HAVE_GETCONF, [
diff --git a/usr.sbin/afs/src/cf/check-man.m4 b/usr.sbin/afs/src/cf/check-man.m4
index 7b1c7e020d3..708ed84618d 100644
--- a/usr.sbin/afs/src/cf/check-man.m4
+++ b/usr.sbin/afs/src/cf/check-man.m4
@@ -1,4 +1,4 @@
-dnl $Id: check-man.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-man.m4,v 1.1 1999/05/15 22:45:23 assar Exp $
dnl check how to format manual pages
dnl
diff --git a/usr.sbin/afs/src/cf/check-type-extra.m4 b/usr.sbin/afs/src/cf/check-type-extra.m4
index 90466c22584..6f5be8a23d0 100644
--- a/usr.sbin/afs/src/cf/check-type-extra.m4
+++ b/usr.sbin/afs/src/cf/check-type-extra.m4
@@ -1,4 +1,4 @@
-dnl $Id: check-type-extra.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-type-extra.m4,v 1.1 1999/05/15 22:45:23 assar Exp $
dnl
dnl ac_check_type + extra headers
diff --git a/usr.sbin/afs/src/cf/check-var.m4 b/usr.sbin/afs/src/cf/check-var.m4
index 060229cd688..c5d8efa0f2f 100644
--- a/usr.sbin/afs/src/cf/check-var.m4
+++ b/usr.sbin/afs/src/cf/check-var.m4
@@ -1,4 +1,4 @@
-dnl $Id: check-var.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-var.m4,v 1.1 1999/05/15 22:45:24 assar Exp $
dnl
dnl AC_CHECK_VAR(includes, variable)
AC_DEFUN(AC_CHECK_VAR, [
diff --git a/usr.sbin/afs/src/cf/check-x.m4 b/usr.sbin/afs/src/cf/check-x.m4
index 2b74b5554db..ad9d10481b6 100644
--- a/usr.sbin/afs/src/cf/check-x.m4
+++ b/usr.sbin/afs/src/cf/check-x.m4
@@ -1,7 +1,7 @@
dnl
dnl See if there is any X11 present
dnl
-dnl $Id: check-x.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-x.m4,v 1.1 1999/07/13 21:20:51 joda Exp $
AC_DEFUN(KRB_CHECK_X,[
AC_PATH_XTRA
diff --git a/usr.sbin/afs/src/cf/check-xau.m4 b/usr.sbin/afs/src/cf/check-xau.m4
index 7e142b7ca6b..ca87be3001f 100644
--- a/usr.sbin/afs/src/cf/check-xau.m4
+++ b/usr.sbin/afs/src/cf/check-xau.m4
@@ -1,4 +1,4 @@
-dnl $Id: check-xau.m4,v 1.1 2000/09/11 14:40:46 art Exp $
+dnl $KTH: check-xau.m4,v 1.1 1999/05/15 22:45:24 assar Exp $
dnl
dnl check for Xau{Read,Write}Auth
dnl
diff --git a/usr.sbin/afs/src/cf/elf-object-format.m4 b/usr.sbin/afs/src/cf/elf-object-format.m4
index 1bc51b44a53..4f8502a8be3 100644
--- a/usr.sbin/afs/src/cf/elf-object-format.m4
+++ b/usr.sbin/afs/src/cf/elf-object-format.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: elf-object-format.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: elf-object-format.m4,v 1.1 1999/05/15 22:45:24 assar Exp $
dnl
dnl test for ELF
diff --git a/usr.sbin/afs/src/cf/find-func-no-libs.m4 b/usr.sbin/afs/src/cf/find-func-no-libs.m4
index cf70a7a34ac..5a7184ff7d7 100644
--- a/usr.sbin/afs/src/cf/find-func-no-libs.m4
+++ b/usr.sbin/afs/src/cf/find-func-no-libs.m4
@@ -1,4 +1,4 @@
-dnl $Id: find-func-no-libs.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: find-func-no-libs.m4,v 1.3 1999/10/30 21:04:34 assar Exp $
dnl
dnl
dnl Look for function in any of the specified libraries
diff --git a/usr.sbin/afs/src/cf/find-func-no-libs2.m4 b/usr.sbin/afs/src/cf/find-func-no-libs2.m4
index 4c57fd432d4..ed7254c1386 100644
--- a/usr.sbin/afs/src/cf/find-func-no-libs2.m4
+++ b/usr.sbin/afs/src/cf/find-func-no-libs2.m4
@@ -1,4 +1,4 @@
-dnl $Id: find-func-no-libs2.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: find-func-no-libs2.m4,v 1.3 1999/10/30 21:03:36 assar Exp $
dnl
dnl
dnl Look for function in any of the specified libraries
diff --git a/usr.sbin/afs/src/cf/find-func.m4 b/usr.sbin/afs/src/cf/find-func.m4
index 9f41a9d1364..85d758b18af 100644
--- a/usr.sbin/afs/src/cf/find-func.m4
+++ b/usr.sbin/afs/src/cf/find-func.m4
@@ -1,4 +1,4 @@
-dnl $Id: find-func.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: find-func.m4,v 1.1 1999/05/15 22:45:25 assar Exp $
dnl
dnl AC_FIND_FUNC(func, libraries, includes, arguments)
AC_DEFUN(AC_FIND_FUNC, [
diff --git a/usr.sbin/afs/src/cf/find-if-not-broken.m4 b/usr.sbin/afs/src/cf/find-if-not-broken.m4
index 29e57d9c7e2..25e46fc4aff 100644
--- a/usr.sbin/afs/src/cf/find-if-not-broken.m4
+++ b/usr.sbin/afs/src/cf/find-if-not-broken.m4
@@ -1,4 +1,4 @@
-dnl $Id: find-if-not-broken.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: find-if-not-broken.m4,v 1.1 1999/05/15 22:45:25 assar Exp $
dnl
dnl
dnl Mix between AC_FIND_FUNC and AC_BROKEN
diff --git a/usr.sbin/afs/src/cf/func-hstrerror-const.m4 b/usr.sbin/afs/src/cf/func-hstrerror-const.m4
index c7dad234061..017cf3d94f5 100644
--- a/usr.sbin/afs/src/cf/func-hstrerror-const.m4
+++ b/usr.sbin/afs/src/cf/func-hstrerror-const.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: func-hstrerror-const.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: func-hstrerror-const.m4,v 1.2 1999/05/28 13:18:04 assar Exp $
dnl
dnl Test if hstrerror wants const or not
dnl
diff --git a/usr.sbin/afs/src/cf/func-krb-get-default-tkt-root.m4 b/usr.sbin/afs/src/cf/func-krb-get-default-tkt-root.m4
index 0760a082389..f6cde19844d 100644
--- a/usr.sbin/afs/src/cf/func-krb-get-default-tkt-root.m4
+++ b/usr.sbin/afs/src/cf/func-krb-get-default-tkt-root.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: func-krb-get-default-tkt-root.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: func-krb-get-default-tkt-root.m4,v 1.3 2000/01/23 16:53:21 lha Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/func-krb-get-err-text.m4 b/usr.sbin/afs/src/cf/func-krb-get-err-text.m4
index 619a6a9a56d..189d18d71c3 100644
--- a/usr.sbin/afs/src/cf/func-krb-get-err-text.m4
+++ b/usr.sbin/afs/src/cf/func-krb-get-err-text.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: func-krb-get-err-text.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: func-krb-get-err-text.m4,v 1.3 2000/01/23 13:01:51 lha Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/func-krb-kdctimeofday.m4 b/usr.sbin/afs/src/cf/func-krb-kdctimeofday.m4
index 446577aa856..0699374b4e8 100644
--- a/usr.sbin/afs/src/cf/func-krb-kdctimeofday.m4
+++ b/usr.sbin/afs/src/cf/func-krb-kdctimeofday.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: func-krb-kdctimeofday.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: func-krb-kdctimeofday.m4,v 1.4 2000/05/23 07:21:24 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/func-ntohl.m4 b/usr.sbin/afs/src/cf/func-ntohl.m4
index b2c001097f5..cc3b9be50f9 100644
--- a/usr.sbin/afs/src/cf/func-ntohl.m4
+++ b/usr.sbin/afs/src/cf/func-ntohl.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: func-ntohl.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: func-ntohl.m4,v 1.1 1999/05/15 22:45:26 assar Exp $
dnl
dnl test for how to do ntohl
dnl
diff --git a/usr.sbin/afs/src/cf/grok-type.m4 b/usr.sbin/afs/src/cf/grok-type.m4
index 7d840bac619..ed7a4b5723d 100644
--- a/usr.sbin/afs/src/cf/grok-type.m4
+++ b/usr.sbin/afs/src/cf/grok-type.m4
@@ -1,4 +1,4 @@
-dnl $Id: grok-type.m4,v 1.1 2000/09/11 14:40:47 art Exp $
+dnl $KTH: grok-type.m4,v 1.1 1999/05/15 22:45:26 assar Exp $
dnl
AC_DEFUN(AC_GROK_TYPE, [
AC_CACHE_VAL(ac_cv_type_$1,
diff --git a/usr.sbin/afs/src/cf/have-def.m4 b/usr.sbin/afs/src/cf/have-def.m4
index 3bd7ab3aa7e..f774f72e771 100644
--- a/usr.sbin/afs/src/cf/have-def.m4
+++ b/usr.sbin/afs/src/cf/have-def.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: have-def.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-def.m4,v 1.2.24.1 2001/04/16 23:07:50 lha Exp $
dnl
dnl AC_HAVE_DEF(includes, [struct|typedef])
@@ -13,7 +13,7 @@ cache_val=no)])
if test "$cache_val" = yes; then
define(foo, translit(HAVE_DEF_$2, [a-z ], [A-Z_]))
AC_DEFINE(foo, 1, [Define if you have $2])
- undefine(foo)
+ undefine([foo])
fi
undefine([cache_val])
])
diff --git a/usr.sbin/afs/src/cf/have-kernel-struct-field.m4 b/usr.sbin/afs/src/cf/have-kernel-struct-field.m4
index fa85b6b13e1..41044ea3715 100644
--- a/usr.sbin/afs/src/cf/have-kernel-struct-field.m4
+++ b/usr.sbin/afs/src/cf/have-kernel-struct-field.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: have-kernel-struct-field.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-kernel-struct-field.m4,v 1.3.22.1 2001/04/16 23:07:52 lha Exp $
dnl
dnl AC_HAVE_KERNEL_STRUCT_FIELD(includes, struct, type, field)
@@ -13,7 +13,7 @@ cache_val=no)])
if test "$cache_val" = yes; then
define(foo, translit(HAVE_STRUCT_$2_$4, [a-z ], [A-Z_]))
AC_DEFINE(foo, 1, [Define if struct $2 has field $4])
- undefine(foo)
+ undefine([foo])
fi
-undefine(cache_val)
+undefine([cache_val])
])
diff --git a/usr.sbin/afs/src/cf/have-linux-kernel-type.m4 b/usr.sbin/afs/src/cf/have-linux-kernel-type.m4
index 66409dd66ba..5197c8b2201 100644
--- a/usr.sbin/afs/src/cf/have-linux-kernel-type.m4
+++ b/usr.sbin/afs/src/cf/have-linux-kernel-type.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: have-linux-kernel-type.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-linux-kernel-type.m4,v 1.2 1999/12/05 10:33:09 assar Exp $
dnl
dnl Check for types in the Linux kernel
dnl
diff --git a/usr.sbin/afs/src/cf/have-linux-kernel-types.m4 b/usr.sbin/afs/src/cf/have-linux-kernel-types.m4
index b3d1b3a8a1a..18b3bcc5491 100644
--- a/usr.sbin/afs/src/cf/have-linux-kernel-types.m4
+++ b/usr.sbin/afs/src/cf/have-linux-kernel-types.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: have-linux-kernel-types.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-linux-kernel-types.m4,v 1.1 1999/05/15 22:45:27 assar Exp $
dnl
dnl Check for types in the Linux kernel
dnl
diff --git a/usr.sbin/afs/src/cf/have-pragma-weak.m4 b/usr.sbin/afs/src/cf/have-pragma-weak.m4
index fe5a42b1ab3..d566c1a03ec 100644
--- a/usr.sbin/afs/src/cf/have-pragma-weak.m4
+++ b/usr.sbin/afs/src/cf/have-pragma-weak.m4
@@ -1,4 +1,4 @@
-dnl $Id: have-pragma-weak.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-pragma-weak.m4,v 1.1 1999/05/15 22:45:27 assar Exp $
dnl
AC_DEFUN(AC_HAVE_PRAGMA_WEAK, [
if test "${enable_shared}" = "yes"; then
diff --git a/usr.sbin/afs/src/cf/have-struct-field.m4 b/usr.sbin/afs/src/cf/have-struct-field.m4
index 5bd77468597..527eccdbef9 100644
--- a/usr.sbin/afs/src/cf/have-struct-field.m4
+++ b/usr.sbin/afs/src/cf/have-struct-field.m4
@@ -1,4 +1,4 @@
-dnl $Id: have-struct-field.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-struct-field.m4,v 1.1.28.1 2001/04/16 23:07:54 lha Exp $
dnl
dnl check for fields in a structure
dnl
@@ -13,7 +13,7 @@ cache_val=no)])
if test "$cache_val" = yes; then
define(foo, translit(HAVE_$1_$2, [a-z ], [A-Z_]))
AC_DEFINE(foo, 1, [Define if $1 has field $2.])
- undefine(foo)
+ undefine([foo])
fi
-undefine(cache_val)
+undefine([cache_val])
])
diff --git a/usr.sbin/afs/src/cf/have-type.m4 b/usr.sbin/afs/src/cf/have-type.m4
index c0e069ca77a..dc328b8bccc 100644
--- a/usr.sbin/afs/src/cf/have-type.m4
+++ b/usr.sbin/afs/src/cf/have-type.m4
@@ -1,4 +1,4 @@
-dnl $Id: have-type.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-type.m4,v 1.2 1999/12/31 03:12:22 assar Exp $
dnl
dnl check for existance of a type
diff --git a/usr.sbin/afs/src/cf/have-types.m4 b/usr.sbin/afs/src/cf/have-types.m4
index dee39577292..b801004aba0 100644
--- a/usr.sbin/afs/src/cf/have-types.m4
+++ b/usr.sbin/afs/src/cf/have-types.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: have-types.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: have-types.m4,v 1.1 1999/05/15 22:45:28 assar Exp $
dnl
AC_DEFUN(AC_HAVE_TYPES, [
diff --git a/usr.sbin/afs/src/cf/header-dirent-dir-h.m4 b/usr.sbin/afs/src/cf/header-dirent-dir-h.m4
index 338cd920472..063e6d65369 100644
--- a/usr.sbin/afs/src/cf/header-dirent-dir-h.m4
+++ b/usr.sbin/afs/src/cf/header-dirent-dir-h.m4
@@ -1,4 +1,4 @@
-dnl $Id: header-dirent-dir-h.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: header-dirent-dir-h.m4,v 1.1 2000/03/24 04:07:32 assar Exp $
dnl
dnl Check if we can include both dirent.h and sys/dir.h
diff --git a/usr.sbin/afs/src/cf/kernel-have-def.m4 b/usr.sbin/afs/src/cf/kernel-have-def.m4
index 14eebecdfb3..3b45d783e0e 100644
--- a/usr.sbin/afs/src/cf/kernel-have-def.m4
+++ b/usr.sbin/afs/src/cf/kernel-have-def.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: kernel-have-def.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: kernel-have-def.m4,v 1.1.24.1 2001/04/16 23:07:57 lha Exp $
dnl
dnl AC_HAVE_KERNEL_DEF(includes, [struct|typedef])
@@ -13,7 +13,7 @@ cache_val=no)])
if test "$cache_val" = yes; then
define(foo, translit(HAVE_DEF_$2, [a-z ], [A-Z_]))
AC_DEFINE(foo, 1, [Define if you have $2])
- undefine(foo)
+ undefine([foo])
fi
undefine([cache_val])
])
diff --git a/usr.sbin/afs/src/cf/kernel.m4 b/usr.sbin/afs/src/cf/kernel.m4
index 8b9bda1d1a4..e117154ecd4 100644
--- a/usr.sbin/afs/src/cf/kernel.m4
+++ b/usr.sbin/afs/src/cf/kernel.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: kernel.m4,v 1.1 2000/09/11 14:40:48 art Exp $
+dnl $KTH: kernel.m4,v 1.1 1999/05/15 22:45:28 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/krb-bigendian.m4 b/usr.sbin/afs/src/cf/krb-bigendian.m4
index 89a395c2430..8932e15d700 100644
--- a/usr.sbin/afs/src/cf/krb-bigendian.m4
+++ b/usr.sbin/afs/src/cf/krb-bigendian.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: krb-bigendian.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-bigendian.m4,v 1.2 2000/08/19 15:34:21 assar Exp $
dnl
dnl check if this computer is little or big-endian
diff --git a/usr.sbin/afs/src/cf/krb-find-db.m4 b/usr.sbin/afs/src/cf/krb-find-db.m4
index f79088035af..882d5b8f5b5 100644
--- a/usr.sbin/afs/src/cf/krb-find-db.m4
+++ b/usr.sbin/afs/src/cf/krb-find-db.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-find-db.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-find-db.m4,v 1.1 1999/05/15 22:45:28 assar Exp $
dnl
dnl find a suitable database library
dnl
diff --git a/usr.sbin/afs/src/cf/krb-func-getcwd-broken.m4 b/usr.sbin/afs/src/cf/krb-func-getcwd-broken.m4
index 55dffc73e86..2f173b812e8 100644
--- a/usr.sbin/afs/src/cf/krb-func-getcwd-broken.m4
+++ b/usr.sbin/afs/src/cf/krb-func-getcwd-broken.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-func-getcwd-broken.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-func-getcwd-broken.m4,v 1.1 1999/05/15 22:45:28 assar Exp $
dnl
dnl
dnl test for broken getcwd in (SunOS braindamage)
diff --git a/usr.sbin/afs/src/cf/krb-ipv6.m4 b/usr.sbin/afs/src/cf/krb-ipv6.m4
index 70641511ddc..06773f13a19 100644
--- a/usr.sbin/afs/src/cf/krb-ipv6.m4
+++ b/usr.sbin/afs/src/cf/krb-ipv6.m4
@@ -1,10 +1,93 @@
-dnl $Id: krb-ipv6.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-ipv6.m4,v 1.2 2000/10/11 03:52:10 assar Exp $
dnl
dnl test for IPv6
dnl
AC_DEFUN(AC_KRB_IPV6, [
-AC_CACHE_CHECK(for IPv6,ac_cv_lib_ipv6,
-AC_TRY_COMPILE([
+AC_ARG_WITH(ipv6,
+[ --without-ipv6 do not enable IPv6 support],[
+if test "$withval" = "no"; then
+ ac_cv_lib_ipv6=no
+fi])
+AC_CACHE_VAL(ac_cv_lib_ipv6,
+[dnl check for different v6 implementations (by itojun)
+v6type=unknown
+v6lib=none
+
+AC_MSG_CHECKING([ipv6 stack type])
+for i in v6d toshiba kame inria zeta linux; do
+ case $i in
+ v6d)
+ AC_EGREP_CPP(yes, [dnl
+#include </usr/local/v6/include/sys/types.h>
+#ifdef __V6D__
+yes
+#endif],
+ [v6type=$i; v6lib=v6;
+ v6libdir=/usr/local/v6/lib;
+ CFLAGS="-I/usr/local/v6/include $CFLAGS"])
+ ;;
+ toshiba)
+ AC_EGREP_CPP(yes, [dnl
+#include <sys/param.h>
+#ifdef _TOSHIBA_INET6
+yes
+#endif],
+ [v6type=$i; v6lib=inet6;
+ v6libdir=/usr/local/v6/lib;
+ CFLAGS="-DINET6 $CFLAGS"])
+ ;;
+ kame)
+ AC_EGREP_CPP(yes, [dnl
+#include <netinet/in.h>
+#ifdef __KAME__
+yes
+#endif],
+ [v6type=$i; v6lib=inet6;
+ v6libdir=/usr/local/v6/lib;
+ CFLAGS="-DINET6 $CFLAGS"])
+ ;;
+ inria)
+ AC_EGREP_CPP(yes, [dnl
+#include <netinet/in.h>
+#ifdef IPV6_INRIA_VERSION
+yes
+#endif],
+ [v6type=$i; CFLAGS="-DINET6 $CFLAGS"])
+ ;;
+ zeta)
+ AC_EGREP_CPP(yes, [dnl
+#include <sys/param.h>
+#ifdef _ZETA_MINAMI_INET6
+yes
+#endif],
+ [v6type=$i; v6lib=inet6;
+ v6libdir=/usr/local/v6/lib;
+ CFLAGS="-DINET6 $CFLAGS"])
+ ;;
+ linux)
+ if test -d /usr/inet6; then
+ v6type=$i
+ v6lib=inet6
+ v6libdir=/usr/inet6
+ CFLAGS="-DINET6 $CFLAGS"
+ fi
+ ;;
+ esac
+ if test "$v6type" != "unknown"; then
+ break
+ fi
+done
+AC_MSG_RESULT($v6type)
+
+if test "$v6lib" != "none"; then
+ for dir in $v6libdir /usr/local/v6/lib /usr/local/lib; do
+ if test -d $dir -a -f $dir/lib$v6lib.a; then
+ LIBS="-L$dir -l$v6lib $LIBS"
+ break
+ fi
+ done
+fi
+AC_TRY_LINK([
#ifdef HAVE_SYS_TYPES_H
#include <sys/types.h>
#endif
@@ -19,13 +102,6 @@ AC_TRY_COMPILE([
#endif
],
[
-#if defined(IN6ADDR_ANY_INIT)
-struct in6_addr any = IN6ADDR_ANY_INIT;
-#elif defined(IPV6ADDR_ANY_INIT)
-struct in6_addr any = IPV6ADDR_ANY_INIT;
-#else
-#error no any?
-#endif
struct sockaddr_in6 sin6;
int s;
@@ -33,98 +109,14 @@ struct in6_addr any = IPV6ADDR_ANY_INIT;
sin6.sin6_family = AF_INET6;
sin6.sin6_port = htons(17);
- sin6.sin6_addr = any;
+ sin6.sin6_addr = in6addr_any;
bind(s, (struct sockaddr *)&sin6, sizeof(sin6));
],
ac_cv_lib_ipv6=yes,
-ac_cv_lib_ipv6=no))
+ac_cv_lib_ipv6=no)])
+AC_MSG_CHECKING(for IPv6)
+AC_MSG_RESULT($ac_cv_lib_ipv6)
if test "$ac_cv_lib_ipv6" = yes; then
AC_DEFINE(HAVE_IPV6, 1, [Define if you have IPv6.])
-
- dnl check for different v6 implementations (by itojun)
- v6type=unknown
- v6lib=none
-
- AC_MSG_CHECKING([ipv6 stack type])
- for i in v6d toshiba kame inria zeta linux; do
- case $i in
- v6d)
- AC_EGREP_CPP(yes, [dnl
-#include </usr/local/v6/include/sys/types.h>
-#ifdef __V6D__
-yes
-#endif],
- [v6type=$i; v6lib=v6;
- v6libdir=/usr/local/v6/lib;
- CFLAGS="-I/usr/local/v6/include $CFLAGS"])
- ;;
- toshiba)
- AC_EGREP_CPP(yes, [dnl
-#include <sys/param.h>
-#ifdef _TOSHIBA_INET6
-yes
-#endif],
- [v6type=$i; v6lib=inet6;
- v6libdir=/usr/local/v6/lib;
- CFLAGS="-DINET6 $CFLAGS"])
- ;;
- kame)
- AC_EGREP_CPP(yes, [dnl
-#include <netinet/in.h>
-#ifdef __KAME__
-yes
-#endif],
- [v6type=$i; v6lib=inet6;
- v6libdir=/usr/local/v6/lib;
- CFLAGS="-DINET6 $CFLAGS"])
- ;;
- inria)
- AC_EGREP_CPP(yes, [dnl
-#include <netinet/in.h>
-#ifdef IPV6_INRIA_VERSION
-yes
-#endif],
- [v6type=$i; CFLAGS="-DINET6 $CFLAGS"])
- ;;
- zeta)
- AC_EGREP_CPP(yes, [dnl
-#include <sys/param.h>
-#ifdef _ZETA_MINAMI_INET6
-yes
-#endif],
- [v6type=$i; v6lib=inet6;
- v6libdir=/usr/local/v6/lib;
- CFLAGS="-DINET6 $CFLAGS"])
- ;;
- linux)
- if test -d /usr/inet6; then
- v6type=$i
- v6lib=inet6
- v6libdir=/usr/inet6
- CFLAGS="-DINET6 $CFLAGS"
- fi
- ;;
- esac
- if test "$v6type" != "unknown"; then
- break
- fi
- done
- AC_MSG_RESULT($v6type)
-
- if test "$v6lib" != "none"; then
- for dir in $v6libdir /usr/local/v6/lib /usr/local/lib; do
- if test -d $dir -a -f $dir/lib$v6lib.a; then
- LIBS="-L$dir -l$v6lib $LIBS"
- break
- fi
- done
-dnl AC_CHECK_LIB($v6lib, getaddrinfo,
-dnl [SERVER_LIBS="-l$v6lib $SERVER_LIBS"],
-dnl [dnl
-dnl echo "Fatal: no $v6lib library found. cannot continue."
-dnl echo "You need to fetch lib$v6lib.a from appropriate v6 kit and"
-dnl echo 'compile beforehand.'
-dnl exit 1])
- fi
fi
])
diff --git a/usr.sbin/afs/src/cf/krb-prog-ln-s.m4 b/usr.sbin/afs/src/cf/krb-prog-ln-s.m4
index b80095b445e..7774faa2c25 100644
--- a/usr.sbin/afs/src/cf/krb-prog-ln-s.m4
+++ b/usr.sbin/afs/src/cf/krb-prog-ln-s.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-prog-ln-s.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-prog-ln-s.m4,v 1.1 1999/05/15 22:45:29 assar Exp $
dnl
dnl
dnl Better test for ln -s, ln or cp
diff --git a/usr.sbin/afs/src/cf/krb-prog-ranlib.m4 b/usr.sbin/afs/src/cf/krb-prog-ranlib.m4
index ea7fcc9703d..eb5c70fdee8 100644
--- a/usr.sbin/afs/src/cf/krb-prog-ranlib.m4
+++ b/usr.sbin/afs/src/cf/krb-prog-ranlib.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-prog-ranlib.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-prog-ranlib.m4,v 1.1 1999/05/15 22:45:30 assar Exp $
dnl
dnl
dnl Also look for EMXOMF for OS/2
diff --git a/usr.sbin/afs/src/cf/krb-prog-yacc.m4 b/usr.sbin/afs/src/cf/krb-prog-yacc.m4
index c9fbee93e31..32f09f63d55 100644
--- a/usr.sbin/afs/src/cf/krb-prog-yacc.m4
+++ b/usr.sbin/afs/src/cf/krb-prog-yacc.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-prog-yacc.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-prog-yacc.m4,v 1.1 1999/05/15 22:45:30 assar Exp $
dnl
dnl
dnl We prefer byacc or yacc because they do not use `alloca'
diff --git a/usr.sbin/afs/src/cf/krb-struct-sockaddr-sa-len.m4 b/usr.sbin/afs/src/cf/krb-struct-sockaddr-sa-len.m4
index c5e5f9a0234..04d2d540935 100644
--- a/usr.sbin/afs/src/cf/krb-struct-sockaddr-sa-len.m4
+++ b/usr.sbin/afs/src/cf/krb-struct-sockaddr-sa-len.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-struct-sockaddr-sa-len.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-struct-sockaddr-sa-len.m4,v 1.1 1999/05/15 22:45:30 assar Exp $
dnl
dnl
dnl Check for sa_len in sys/socket.h
diff --git a/usr.sbin/afs/src/cf/krb-struct-spwd.m4 b/usr.sbin/afs/src/cf/krb-struct-spwd.m4
index e319f36e82f..466251fa9cf 100644
--- a/usr.sbin/afs/src/cf/krb-struct-spwd.m4
+++ b/usr.sbin/afs/src/cf/krb-struct-spwd.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-struct-spwd.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-struct-spwd.m4,v 1.2 2000/03/14 00:04:10 assar Exp $
dnl
dnl Test for `struct spwd'
diff --git a/usr.sbin/afs/src/cf/krb-struct-winsize.m4 b/usr.sbin/afs/src/cf/krb-struct-winsize.m4
index 72d0a4c7418..b353266c509 100644
--- a/usr.sbin/afs/src/cf/krb-struct-winsize.m4
+++ b/usr.sbin/afs/src/cf/krb-struct-winsize.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-struct-winsize.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-struct-winsize.m4,v 1.1 1999/05/15 22:45:31 assar Exp $
dnl
dnl
dnl Search for struct winsize
diff --git a/usr.sbin/afs/src/cf/krb-sys-aix.m4 b/usr.sbin/afs/src/cf/krb-sys-aix.m4
index 8fc3c27ae22..8a80540b5f5 100644
--- a/usr.sbin/afs/src/cf/krb-sys-aix.m4
+++ b/usr.sbin/afs/src/cf/krb-sys-aix.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-sys-aix.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-sys-aix.m4,v 1.1 1999/05/15 22:45:31 assar Exp $
dnl
dnl
dnl AIX have a very different syscall convention
diff --git a/usr.sbin/afs/src/cf/krb-sys-nextstep.m4 b/usr.sbin/afs/src/cf/krb-sys-nextstep.m4
index fb2ac40d866..6b8471d4a04 100644
--- a/usr.sbin/afs/src/cf/krb-sys-nextstep.m4
+++ b/usr.sbin/afs/src/cf/krb-sys-nextstep.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-sys-nextstep.m4,v 1.1 2000/09/11 14:40:49 art Exp $
+dnl $KTH: krb-sys-nextstep.m4,v 1.2 1999/05/16 13:44:46 assar Exp $
dnl
dnl
dnl NEXTSTEP is not posix compliant by default,
diff --git a/usr.sbin/afs/src/cf/krb-version.m4 b/usr.sbin/afs/src/cf/krb-version.m4
index a83327198bd..2bccd2df8e8 100644
--- a/usr.sbin/afs/src/cf/krb-version.m4
+++ b/usr.sbin/afs/src/cf/krb-version.m4
@@ -1,4 +1,4 @@
-dnl $Id: krb-version.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: krb-version.m4,v 1.3 2000/06/03 20:31:44 lha Exp $
dnl
dnl
dnl output a C header-file with some version strings
diff --git a/usr.sbin/afs/src/cf/linux-func-d_alloc_root-two_args.m4 b/usr.sbin/afs/src/cf/linux-func-d_alloc_root-two_args.m4
index f6cfe4323a0..46baafd5446 100644
--- a/usr.sbin/afs/src/cf/linux-func-d_alloc_root-two_args.m4
+++ b/usr.sbin/afs/src/cf/linux-func-d_alloc_root-two_args.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: linux-func-d_alloc_root-two_args.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: linux-func-d_alloc_root-two_args.m4,v 1.2 1999/07/22 04:59:34 assar Exp $
dnl
AC_DEFUN(AC_LINUX_FUNC_D_ALLOC_ROOT_TWO_ARGS, [
diff --git a/usr.sbin/afs/src/cf/linux-func-devfs-register-eleven-args.m4 b/usr.sbin/afs/src/cf/linux-func-devfs-register-eleven-args.m4
index 9f610c30165..3963bbc296d 100644
--- a/usr.sbin/afs/src/cf/linux-func-devfs-register-eleven-args.m4
+++ b/usr.sbin/afs/src/cf/linux-func-devfs-register-eleven-args.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: linux-func-devfs-register-eleven-args.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: linux-func-devfs-register-eleven-args.m4,v 1.1 1999/11/03 01:09:04 mackan Exp $
dnl
AC_DEFUN(AC_LINUX_FUNC_DEVFS_REGISTER_ELEVEN_ARGS, [
diff --git a/usr.sbin/afs/src/cf/linux-func-init-mutex.m4 b/usr.sbin/afs/src/cf/linux-func-init-mutex.m4
index d8973cd85cf..2c055b954d0 100644
--- a/usr.sbin/afs/src/cf/linux-func-init-mutex.m4
+++ b/usr.sbin/afs/src/cf/linux-func-init-mutex.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: linux-func-init-mutex.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: linux-func-init-mutex.m4,v 1.6.12.1 2002/01/31 12:34:45 lha Exp $
dnl
AC_DEFUN(AC_LINUX_FUNC_INIT_MUTEX, [
@@ -8,7 +8,10 @@ ac_cv_func_init_mutex, [
save_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $test_KERNEL_CFLAGS $KERNEL_CPPFLAGS"
AC_EGREP_CPP([init_MUTEX],
-[#include <asm/semaphore.h>],
+[#include <asm/semaphore.h>
+#ifdef init_MUTEX
+init_MUTEX
+#endif],
ac_cv_func_init_mutex=yes,
ac_cv_func_init_mutex=no)]
CPPFLAGS="$save_CPPFLAGS"
diff --git a/usr.sbin/afs/src/cf/linux-func-init-wait-queue-head.m4 b/usr.sbin/afs/src/cf/linux-func-init-wait-queue-head.m4
index a845c1b83e3..5298c16f5ec 100644
--- a/usr.sbin/afs/src/cf/linux-func-init-wait-queue-head.m4
+++ b/usr.sbin/afs/src/cf/linux-func-init-wait-queue-head.m4
@@ -1,11 +1,15 @@
dnl
-dnl $Id: linux-func-init-wait-queue-head.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: linux-func-init-wait-queue-head.m4,v 1.2 2000/09/25 09:13:56 lha Exp $
dnl
AC_DEFUN(AC_LINUX_FUNC_INIT_WAITQUEUE_HEAD, [
AC_CACHE_CHECK([for init_waitqueue_head],
ac_cv_func_init_waitqueue_head,[
-AC_TRY_COMPILE_KERNEL([#include <linux/wait.h>],
+AC_TRY_COMPILE_KERNEL([
+#ifdef HAVE_LINUX_STDDEF_H
+#include <linux/stddef.h>
+#endif
+#include <linux/wait.h>],
[wait_queue_head_t foo;
init_waitqueue_head(&foo)],
ac_cv_func_init_waitqueue_head=yes,
diff --git a/usr.sbin/afs/src/cf/linux-type-wait-queue-head.m4 b/usr.sbin/afs/src/cf/linux-type-wait-queue-head.m4
index 175db4bdfc3..97fa1d84d37 100644
--- a/usr.sbin/afs/src/cf/linux-type-wait-queue-head.m4
+++ b/usr.sbin/afs/src/cf/linux-type-wait-queue-head.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: linux-type-wait-queue-head.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: linux-type-wait-queue-head.m4,v 1.2 1999/05/16 16:38:36 assar Exp $
dnl
AC_DEFUN(AC_LINUX_TYPE_WAIT_QUEUE_HEAD_T, [
diff --git a/usr.sbin/afs/src/cf/mips-abi.m4 b/usr.sbin/afs/src/cf/mips-abi.m4
index 4b00d838b50..e4669645114 100644
--- a/usr.sbin/afs/src/cf/mips-abi.m4
+++ b/usr.sbin/afs/src/cf/mips-abi.m4
@@ -1,4 +1,4 @@
-dnl $Id: mips-abi.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: mips-abi.m4,v 1.1 1999/05/15 22:45:33 assar Exp $
dnl
dnl
dnl Check for MIPS/IRIX ABI flags. Sets $abi and $abilibdirext to some
diff --git a/usr.sbin/afs/src/cf/misc.m4 b/usr.sbin/afs/src/cf/misc.m4
index 82991737922..ac1a716254d 100644
--- a/usr.sbin/afs/src/cf/misc.m4
+++ b/usr.sbin/afs/src/cf/misc.m4
@@ -1,3 +1,3 @@
-dnl $Id: misc.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: misc.m4,v 1.1 1999/05/15 22:45:33 assar Exp $
dnl
define(upcase,`echo $1 | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ`)dnl
diff --git a/usr.sbin/afs/src/cf/need-proto.m4 b/usr.sbin/afs/src/cf/need-proto.m4
index b634b4433b3..76be5bf18fb 100644
--- a/usr.sbin/afs/src/cf/need-proto.m4
+++ b/usr.sbin/afs/src/cf/need-proto.m4
@@ -1,4 +1,4 @@
-dnl $Id: need-proto.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: need-proto.m4,v 1.1 1999/05/15 22:45:33 assar Exp $
dnl
dnl
dnl Check if we need the prototype for a function
diff --git a/usr.sbin/afs/src/cf/osf-func-ubc-lookup.m4 b/usr.sbin/afs/src/cf/osf-func-ubc-lookup.m4
index 2a56dab5a9d..9f1548d6574 100644
--- a/usr.sbin/afs/src/cf/osf-func-ubc-lookup.m4
+++ b/usr.sbin/afs/src/cf/osf-func-ubc-lookup.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: osf-func-ubc-lookup.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: osf-func-ubc-lookup.m4,v 1.2 2000/06/12 06:57:40 assar Exp $
dnl
AC_DEFUN(AC_OSF_FUNC_UBC_LOOKUP, [
diff --git a/usr.sbin/afs/src/cf/osfc2.m4 b/usr.sbin/afs/src/cf/osfc2.m4
index f9eb15398f2..dd9ade5014f 100644
--- a/usr.sbin/afs/src/cf/osfc2.m4
+++ b/usr.sbin/afs/src/cf/osfc2.m4
@@ -1,4 +1,4 @@
-dnl $Id: osfc2.m4,v 1.1 2000/09/11 14:40:50 art Exp $
+dnl $KTH: osfc2.m4,v 1.1 1999/05/15 22:45:33 assar Exp $
dnl
dnl enable OSF C2 stuff
diff --git a/usr.sbin/afs/src/cf/prog-cc-flags.m4 b/usr.sbin/afs/src/cf/prog-cc-flags.m4
index 0ccd68f9fd1..1df320326c6 100644
--- a/usr.sbin/afs/src/cf/prog-cc-flags.m4
+++ b/usr.sbin/afs/src/cf/prog-cc-flags.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: prog-cc-flags.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: prog-cc-flags.m4,v 1.2 2000/01/23 12:34:11 assar Exp $
dnl
AC_DEFUN(AC_PROG_CC_FLAGS, [
diff --git a/usr.sbin/afs/src/cf/proto-compat.m4 b/usr.sbin/afs/src/cf/proto-compat.m4
index 1c67050f4b8..7edc5ae09f5 100644
--- a/usr.sbin/afs/src/cf/proto-compat.m4
+++ b/usr.sbin/afs/src/cf/proto-compat.m4
@@ -1,4 +1,4 @@
-dnl $Id: proto-compat.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: proto-compat.m4,v 1.1 1999/05/15 22:45:34 assar Exp $
dnl
dnl
dnl Check if the prototype of a function is compatible with another one
diff --git a/usr.sbin/afs/src/cf/shared-libs.m4 b/usr.sbin/afs/src/cf/shared-libs.m4
index 69060f1dc8e..4bef01eb13d 100644
--- a/usr.sbin/afs/src/cf/shared-libs.m4
+++ b/usr.sbin/afs/src/cf/shared-libs.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: shared-libs.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: shared-libs.m4,v 1.1 1999/05/15 22:45:34 assar Exp $
dnl
dnl Shared library stuff has to be different everywhere
dnl
diff --git a/usr.sbin/afs/src/cf/test-package.m4 b/usr.sbin/afs/src/cf/test-package.m4
index bc21ee90c7f..7b648723f4f 100644
--- a/usr.sbin/afs/src/cf/test-package.m4
+++ b/usr.sbin/afs/src/cf/test-package.m4
@@ -1,4 +1,4 @@
-dnl $Id: test-package.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: test-package.m4,v 1.1 1999/05/15 22:45:34 assar Exp $
dnl
dnl AC_TEST_PACKAGE_NEW(package,headers,libraries,extra libs,default locations)
diff --git a/usr.sbin/afs/src/cf/try-compile-kernel.m4 b/usr.sbin/afs/src/cf/try-compile-kernel.m4
index 537b258f628..e19f0123085 100644
--- a/usr.sbin/afs/src/cf/try-compile-kernel.m4
+++ b/usr.sbin/afs/src/cf/try-compile-kernel.m4
@@ -1,10 +1,15 @@
dnl
-dnl $Id: try-compile-kernel.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: try-compile-kernel.m4,v 1.2.12.1 2001/05/28 23:22:51 mattiasa Exp $
dnl
AC_DEFUN(AC_TRY_COMPILE_KERNEL,[
save_CFLAGS="$CFLAGS"
+save_CC="$CC"
+if test "X${KERNEL_CC}" != "X"; then
+ CC="$KERNEL_CC"
+fi
CFLAGS="$CFLAGS $test_KERNEL_CFLAGS $KERNEL_CPPFLAGS"
AC_TRY_COMPILE([$1], [$2], [$3], [$4])
CFLAGS="$save_CFLAGS"
+CC="$save_CC"
])
diff --git a/usr.sbin/afs/src/cf/try-cpp-kernel.m4 b/usr.sbin/afs/src/cf/try-cpp-kernel.m4
index 93a7996a14c..ca31fcf6a34 100644
--- a/usr.sbin/afs/src/cf/try-cpp-kernel.m4
+++ b/usr.sbin/afs/src/cf/try-cpp-kernel.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: try-cpp-kernel.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: try-cpp-kernel.m4,v 1.1 2000/03/16 10:20:34 assar Exp $
dnl
AC_DEFUN(AC_TRY_CPP_KERNEL,[
diff --git a/usr.sbin/afs/src/cf/type-iovec.m4 b/usr.sbin/afs/src/cf/type-iovec.m4
index 31fb323826a..7f3f0e1fe5d 100644
--- a/usr.sbin/afs/src/cf/type-iovec.m4
+++ b/usr.sbin/afs/src/cf/type-iovec.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: type-iovec.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: type-iovec.m4,v 1.2 1999/06/24 01:44:58 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/type-krb-principal.m4 b/usr.sbin/afs/src/cf/type-krb-principal.m4
index adfe69d0ccc..2760688e6da 100644
--- a/usr.sbin/afs/src/cf/type-krb-principal.m4
+++ b/usr.sbin/afs/src/cf/type-krb-principal.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: type-krb-principal.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: type-krb-principal.m4,v 1.3 2000/01/23 13:01:42 lha Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/type-msghdr.m4 b/usr.sbin/afs/src/cf/type-msghdr.m4
index b14e096c188..aac659628f8 100644
--- a/usr.sbin/afs/src/cf/type-msghdr.m4
+++ b/usr.sbin/afs/src/cf/type-msghdr.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: type-msghdr.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: type-msghdr.m4,v 1.1 1999/05/15 22:45:35 assar Exp $
dnl
dnl
diff --git a/usr.sbin/afs/src/cf/wflags.m4 b/usr.sbin/afs/src/cf/wflags.m4
index 321023b420d..0b37e2fc324 100644
--- a/usr.sbin/afs/src/cf/wflags.m4
+++ b/usr.sbin/afs/src/cf/wflags.m4
@@ -1,4 +1,4 @@
-dnl $Id: wflags.m4,v 1.1 2000/09/11 14:40:51 art Exp $
+dnl $KTH: wflags.m4,v 1.1 1999/05/15 22:45:35 assar Exp $
dnl
dnl set WFLAGS
diff --git a/usr.sbin/afs/src/conf/CellServDB b/usr.sbin/afs/src/conf/CellServDB
index d43f3da321e..41e8c88452d 100644
--- a/usr.sbin/afs/src/conf/CellServDB
+++ b/usr.sbin/afs/src/conf/CellServDB
@@ -185,6 +185,9 @@
>belwue.uni-tuebingen.de #ZDV Universitaet Tuebingen
134.2.2.15 #belwue1.zdv.uni-tuebingen.de
134.2.2.117 #belwue2.zdv.uni-tuebingen.de
+>biocenter.helsinki.fi # Univ of Helsinki, Institute of Biotechnology, Finland
+128.214.58.174 # afsdb1.biocenter.helsinki.fi
+128.214.88.114 # afsdb2.biocenter.helsinki.fi
>zdvpool.uni-tuebingen.de # Eberhard-Karls-Universitaet Tuebingen, WS-Pools
134.2.4.1 #aixserv1.zdv.uni-tuebingen.de
>cs.arizona.edu # University of Arizona - Computer Science Dept.
@@ -241,10 +244,6 @@
128.84.231.196 #ransom.msc.cornell.edu
128.84.241.33 #ept.msc.cornell.edu
128.84.249.240 #locutus.msc.cornell.edu
->theory.cornell.edu # Cornell University Theory Center
-128.84.29.37 #blynken.tc.cornell.edu
-128.84.29.56 #nod.tc.cornell.edu
-128.84.29.77 #wynken.tc.cornell.edu
>kiewit.dartmouth.edu # Dartmouth College, Kiewit
129.170.16.42 #northservc.dartmouth.edu
>northstar.dartmouth.edu #Dartmouth College, Project Northstar
@@ -276,17 +275,17 @@
>athena.mit.edu #MIT/Athena cell
18.70.0.6 #prill.mit.edu.
18.145.0.25 #agamemnon.mit.edu.
-18.159.0.34 #chimera.mit.edu.
+18.7.1.66 #paris.mit.edu
>dev.mit.edu #MIT/IS Development cell
-18.86.0.28 #wham.mit.edu.
+18.7.1.70 #wham.mit.edu.
18.86.0.50 #hum.mit.edu
-18.86.0.51 #rattle.mit.edu
+18.7.15.89 #rattle.mit.edu
>lees.mit.edu #MIT/Lab for Electromagnetic and Electronic Systems
18.90.1.184 #power.mit.edu
>ops.mit.edu #MIT/Athena Ops Group cell
-18.86.0.79 #bitterness.mit.edu.
-18.86.0.80 #heartbreak.mit.edu.
-18.86.0.81 #despair.mit.edu.
+18.7.14.107 #bitterness.mit.edu.
+18.7.14.108 #heartbreak.mit.edu.
+18.7.14.109 #despair.mit.edu.
>net.mit.edu #MIT/Network Group cell
18.72.1.38 #gracie.mit.edu.
18.72.0.26 #cetus.mit.edu.
@@ -295,9 +294,9 @@
18.181.0.22 #rosebud.mit.edu
18.181.0.23 #ronald-ann.mit.edu
>zone.mit.edu #MIT/Watchmaker Zone cell
-18.177.0.20 #casio.mit.edu
-18.177.0.21 #timex.mit.edu
-18.177.0.22 #seiko.mit.edu
+18.18.0.229 #casio.mit.edu
+18.18.0.231 #timex.mit.edu
+18.18.0.232 #seiko.mit.edu
>msu.edu #Michigan State University home cell
35.9.7.10 #afsdb0.cl.msu.edu
35.9.7.11 #afsdb1.cl.msu.edu
@@ -474,8 +473,6 @@
>eng.utah.edu #University of Utah College of Engineering
155.99.222.40 #afs1.eng.utah.edu
155.99.222.41 #afs2.eng.utah.edu
->mc.vanderbilt.edu #Vanderbilt University Medical Center
-160.129.202.80 #dbmi6000.mc.vanderbilt.edu
>cs.washington.edu # University of Washington Comp Sci Department
128.95.2.238 #silk.cs.washington.edu
128.95.2.239 #satin.cs.washington.edu
@@ -665,14 +662,16 @@
130.237.48.8 #sonen.e.kth.se
130.237.48.244 #fadern.e.kth.se
>arla.e.kth.se # KTH, Elektro, Arla cell
-130.237.48.94 #colossus-of-rhodes.e.kth.se
+>hallf.kth.se # Royal Institute of Technology, Solid Mechanics
+130.237.24.141 #rasmus13.hallf.kth.se
+130.237.24.152 #rasmus3.hallf.kth.se
>isk.kth.se # KTH College of Engineering
130.237.206.13 #afsdb1.isk.kth.se
-130.237.206.29 #afsdb2.isk.kth.se
+130.237.202.12 #afsdb2.isk.kth.se
130.237.209.141 #afsdb3.isk.kth.se
>it.kth.se # Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
-130.237.214.7 #toth.it.kth.se
+130.237.212.16 #toth.it.kth.se
130.237.215.7 #isis.it.kth.se
>mech.kth.se # Royal Institute of Technology, MECH
130.237.233.142 #eiger.mech.kth.se
@@ -696,6 +695,8 @@
130.237.237.230 #fishburger.stacken.kth.se
>telge.kth.se # Royal Institute of Technology, Telge
130.237.77.7 #gandalf.telge.kth.se
+>admin.kth.se # Royal Institute of Technology, Admin
+130.237.32.19 #malvolio.admin.kth.se
>bcc.ac.uk # Bloomsbury Computing Consortium
128.40.101.3 #rs6-svr-3.cls-1.bcc.ac.uk
>athena.ox.ac.uk #Oxford cell
@@ -720,3 +721,9 @@
>ies.auc.dk # Aalborg Univ., Inst. of Electronic Systems, Denmark
130.225.51.73 #afsdb1.kom.auc.dk
130.225.51.74 #afsdb2.kom.auc.dk
+>zepa.net #Kolya/zepa.net cell
+>extundo.com # Simon Josefsson's cell
+>openafs.org #OpenAFS project
+128.2.121.218 #virtue.openafs.org
+>dynarc.se # Dynarc
+62.65.1.17 #adder.dynarc.se
diff --git a/usr.sbin/afs/src/conf/Makefile.in b/usr.sbin/afs/src/conf/Makefile.in
index 484d6da4dfb..7f599fd3cf2 100644
--- a/usr.sbin/afs/src/conf/Makefile.in
+++ b/usr.sbin/afs/src/conf/Makefile.in
@@ -1,6 +1,7 @@
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:52 art Exp $
+# $KTH: Makefile.in,v 1.20 2000/10/08 06:20:42 lha Exp $
srcdir = @srcdir@
+top_builddir = ..
VPATH = @srcdir@
SHELL = /bin/sh
diff --git a/usr.sbin/afs/src/conf/arla.conf b/usr.sbin/afs/src/conf/arla.conf
index e4a202b7ca7..63c2cb84d09 100644
--- a/usr.sbin/afs/src/conf/arla.conf
+++ b/usr.sbin/afs/src/conf/arla.conf
@@ -1,7 +1,7 @@
#
# Arla conffile
#
-# $Id: arla.conf,v 1.2 2000/09/11 14:40:52 art Exp $
+# $KTH: arla.conf,v 1.8 2000/09/12 07:22:42 lha Exp $
#
# The upper limit of (arlad) vnodes (think files and directories)
# (high-water mark)
@@ -36,14 +36,13 @@ numconns 100
#
numvols 100
#
-# File priority, the describes how the cleaner process will
-# Clean out files, when the closer this is to 100, the higher
-# is the risk that you will lose files that you fell is important
-# to you when you are in disconnected mode. But you dont want to'
-# set this too low when you are in connected mode, since then you
-# loose valuable diskspace.
+# File priority, the describes how the cleaner process will clean out
+# files when set to a non-zero value. You might lose files that you
+# fell is important (and isn't marked with priority flag) when you are
+# in disconnected mode. You might not want to set this since then you'll
+# loose valuble diskspace for to `sticky' files.
#
-fpriority 100
+fpriority 0
#
#
# The End.
diff --git a/usr.sbin/afs/src/conf/arla.spec.in b/usr.sbin/afs/src/conf/arla.spec.in
index e51990ee3b5..28bebbd7075 100644
--- a/usr.sbin/afs/src/conf/arla.spec.in
+++ b/usr.sbin/afs/src/conf/arla.spec.in
@@ -1,5 +1,5 @@
#
-# $Id: arla.spec.in,v 1.1 2000/09/11 14:40:52 art Exp $
+# $KTH: arla.spec.in,v 1.4 2000/10/08 06:03:14 lha Exp $
#
# A spec file for build a arla rpm
#
@@ -31,13 +31,15 @@ BuildRoot: /var/tmp/arla-%{version}-%{release}-root
Prefix: %{prefix}
Provides: arla
-Requires: krb4
%description
A free implementation of AFS
%changelog
+* Wed Sep 20 2000 <lha@stacken.kth.se>
+ Cleaned some
+
* Thu Jan 21 2000 <lha@s3.kth.se>
Added to distribution
@@ -91,9 +93,9 @@ mv xfs.smp.o.save xfs.smp.o
%install
mkdir ${RPM_BUILD_ROOT}/etc
-make prefix=$RPM_BUILD_ROOT%{prefix} install
-rm $RPM_BUILD_ROOT%{prefix}/bin/xfs.o
-
+mkdir ${RPM_BUILD_ROOT}/sbin
+make install DESTDIR=$RPM_BUILD_ROOT
+rm $RPM_BUILD_ROOT/%{prefix}/bin/xfs.o
KERNEL_VERSION=$(uname -r | sed 's/smp$//')
@@ -106,10 +108,6 @@ mkdir -p $RPM_BUILD_ROOT/lib/modules/${KERNEL_VERSION}smp/fs
cp xfs/linux/xfs.smp.o \
$RPM_BUILD_ROOT/lib/modules/${KERNEL_VERSION}smp/fs/xfs.o
-mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
-cp xfs/linux/bin/arla $RPM_BUILD_ROOT/etc/rc.d/init.d/arla
-chmod 555 $RPM_BUILD_ROOT/etc/rc.d/init.d/arla
-
cp xfs/linux/libgetcwd.so $RPM_BUILD_ROOT%{prefix}/lib
chmod 555 $RPM_BUILD_ROOT%{prefix}/lib/libgetcwd.so
@@ -119,6 +117,8 @@ depmod -a
%files
+%defattr(-,root,root)
+
%doc README NEWS ChangeLog
%config /etc/arla/CellServDB
@@ -129,5 +129,6 @@ depmod -a
%{prefix}/lib
%{prefix}/include
%{prefix}/cache
-/etc/rc.d/init.d
+/etc
+/sbin
/lib/modules
diff --git a/usr.sbin/afs/src/conf/bos.conf b/usr.sbin/afs/src/conf/bos.conf
index 89ea13a2024..34f3011f97a 100644
--- a/usr.sbin/afs/src/conf/bos.conf
+++ b/usr.sbin/afs/src/conf/bos.conf
@@ -1,21 +1,40 @@
#
-# $Id: bos.conf,v 1.1 2000/09/11 14:40:52 art Exp $
+# $KTH: bos.conf,v 1.3 2000/09/06 16:48:44 tol Exp $
#
# Syntax:
#
-# nodetype [node-specific]
-#
-# Node types and their arguments:
-#
-# program executablefile bos-flags core-dir [one flag to executable]
-# email admin@example.org
-#
-# Where bos-flags are:
-#
-# e - mail
-# c - save coredump from `core-dir' XXX
-# d - try to debug corefile :) XXX
-# - - the nop flag
-#
-email example.adress@example.org
-program /usr/arla/bin/arlad e /usr/arla/cache -nz
+# [section_name]
+# field = value
+# field = value...
+#
+#
+# fields for [bos]
+#
+# serverfile
+# email
+#
+#
+# fields for other sections
+#
+# arguments
+# email
+# program
+# coredir
+# savecore
+# trydebug
+
+
+[bos]
+ email = root
+
+[vldbserver]
+ program = /usr/arla/libexec/vldbserver
+ email = true
+
+[ptserver]
+ program = /usr/arla/libexec/ptserver
+ email = true
+
+[fileserver]
+ program = /usr/arla/libexec/fileserver
+ email = true
diff --git a/usr.sbin/afs/src/conf/services b/usr.sbin/afs/src/conf/services
index d818bc6b9af..db78eaf0f20 100644
--- a/usr.sbin/afs/src/conf/services
+++ b/usr.sbin/afs/src/conf/services
@@ -5,7 +5,7 @@ afs3-fileserver 7000/udp # Fileserver
afs3-callback 7001/udp # Callback server
afs3-prserver 7002/udp # Protection server
afs3-vlserver 7003/udp # Volumelocation server
-afs3-kaserver 7004/udp # Kerberos authentication server
+afs3-kaserver 7004/udp # Kerberos authenication server
afs3-volser 7005/udp # Volume server
afs3-errors 7006/udp # Error server ?
afs3-bos 7007/udp # Basic over-see server ?
diff --git a/usr.sbin/afs/src/doc/Makefile.in b/usr.sbin/afs/src/doc/Makefile.in
index 7c8286f9c98..df37048a608 100644
--- a/usr.sbin/afs/src/doc/Makefile.in
+++ b/usr.sbin/afs/src/doc/Makefile.in
@@ -1,4 +1,4 @@
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:52 art Exp $
+# $KTH: Makefile.in,v 1.18 2000/12/01 08:30:46 lha Exp $
#
SHELL = /bin/sh
@@ -7,6 +7,7 @@ AWK = awk
srcdir = @srcdir@
top_srcdir = @top_srcdir@
+top_builddir = ..
VPATH = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
@@ -34,6 +35,8 @@ arla_TEXINFOS = ack.texi \
authors.texi \
storage.texi \
timeline.texi \
+ real-world.texi \
+ index.texi \
afs-basics.texi
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = ../include/config.h
@@ -64,14 +67,14 @@ Makefile: Makefile.in ../config.status
arla.info: arla.texi $(arla_TEXINFOS)
arla.dvi: arla.texi $(arla_TEXINFOS)
-ack.texi: ack.texi.in Makefile.in
+ack.texi: ack.texi.in Makefile.in ../THANKS
rm -f tempfile
$(AWK) 'BEGIN { FS="|";foo=0;printf("/%%THANKS%%\nd\ni\n"); } \
/@/ { if (foo) { \
printf("@item %s\n\n",$$1);\
} \
} /expect you to/ { foo=1; } \
- END { printf(".\n1,$$s/<.*@/&@/g\n1,$$s/</\\\n@email{/g\n1,$$s/>/}/g\nw %s\nq\n", "$(srcdir)/ack.texi") ;} ' < $(srcdir)/../THANKS > tempfile
+ END { printf(".\n1,$$s/<.*@/&@/g\n1,$$s/</\\\n@tab @email{/g\n1,$$s/>/}/g\nw %s\nq\n", "$(srcdir)/ack.texi") ;} ' < $(srcdir)/../THANKS > tempfile
$(ED) $(srcdir)/ack.texi.in < tempfile
rm -f tempfile
@@ -88,11 +91,11 @@ DVIPS = @DVIPS@
.texi.pdf:
TEXINPUTS=$(srcdir):$$TEXINPUTS \
- MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2PDF) --language=Texinfo $<
+ MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2PDF) $<
.texi.html:
TEXINPUTS=$(srcdir):$$TEXINPUTS \
- MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2HTML) -split_chapter -split_node $< && ln -s $*_toc.html $*.html
+ MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2HTML) -split=chapter $<
.texi:
@cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9]
@@ -181,7 +184,10 @@ dvi: $(DVIS)
clean:
rm -f arla.aux arla.cp arla.cps arla.dvi arla.fn arla.fns arla.ky \
arla.kys arla.ps arla.log arla.pg arla.toc arla.tp arla.tps \
- arla.vr arla.vrs arla.op arla.tr arla.cv arla.cn
+ arla.vr arla.vrs arla.op arla.tr arla.cv arla.cn *.html
+
+distclean:
+ rm -f *.dvi *.info *.ps *.ps *.html *.pdf
# Tell versions [3.59,3.63) of GNU make to not export all variables.
diff --git a/usr.sbin/afs/src/doc/ack.texi b/usr.sbin/afs/src/doc/ack.texi
index 0bbeccb3353..8cc559e7663 100644
--- a/usr.sbin/afs/src/doc/ack.texi
+++ b/usr.sbin/afs/src/doc/ack.texi
@@ -1,6 +1,9 @@
-@c $Id: ack.texi,v 1.1 2000/09/11 14:40:52 art Exp $
+@c Copyright (c) 1997 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+@c $KTH: ack.texi,v 1.17 2001/01/08 18:02:43 lha Exp $
-@node Acknowledgments, , Authors, Top
+@node Acknowledgments, Index, Authors, Top
@comment node-name, next, previous, up
@appendix Acknowledgments
@@ -19,121 +22,146 @@ NetBSD/FreeBSD
The code for gluing these together were written by ourselves.
Bugfixes, documentation, encouragement, and code has been contributed by:
-@table @asis
+
+@multitable @columnfractions .5 .5
@item Aaron M. Ucko
-@email{amu@@MIT.EDU}
+@tab @email{amu@@MIT.EDU}
@item Alec Wolman
-@email{wolman@@cs.washington.edu}
+@tab @email{wolman@@cs.washington.edu}
@item Alexandra Ellwood
-@email{lxs@@MIT.EDU}
+@tab @email{lxs@@MIT.EDU}
@item Brad Keryan
-@email{keryan@@andrew.cmu.edu}
+@tab @email{keryan@@andrew.cmu.edu}
@item Constantine Sapuntzakis
-@email{csapuntz@@openbsd.org}
+@tab @email{csapuntz@@openbsd.org}
@item Dan Winship
-@email{danw@@MIT.EDU}
+@tab @email{danw@@MIT.EDU}
@item Derrick J Brashear
-@email{shadow@@dementia.org}
+@tab @email{shadow@@dementia.org}
@item Harald Barth
-@email{haba@@pdc.kth.se}
+@tab @email{haba@@pdc.kth.se}
@item Jim Doyle
-@email{jrd@@bu.edu}
+@tab @email{jrd@@bu.edu}
@item John Davison
-@email{davisoja@@clarkson.edu}
+@tab @email{davisoja@@clarkson.edu}
@item John Hawkinson
-@email{jhawk@@MIT.EDU}
+@tab @email{jhawk@@MIT.EDU}
@item Karl Ramm
-@email{kcr@@MIT.EDU}
+@tab @email{kcr@@MIT.EDU}
@item Mark Eichin
-@email{eichin@@kitten.gen.ma.us}
+@tab @email{eichin@@kitten.gen.ma.us}
@item Per Boussard T/ED
-@email{Per.Boussard@@era-t.ericsson.se}
+@tab @email{Per.Boussard@@era-t.ericsson.se}
@item Dima Ruban
-@email{dima@@best.net}
+@tab @email{dima@@best.net}
@item Max
-@email{davros@@cyclone.Stanford.EDU}
+@tab @email{davros@@cyclone.Stanford.EDU}
@item Andrzej Filinski
-@email{andrzej@@daimi.aau.dk}
+@tab @email{andrzej@@daimi.aau.dk}
@item Chuck Lever
-@email{chuckl@@netscape.com}
+@tab @email{chuckl@@netscape.com}
@item WUWEI SHEN
-@email{wwshen@@engin.umich.edu}
+@tab @email{wwshen@@engin.umich.edu}
@item Cheng Jin
-@email{chengjin@@eecs.umich.edu}
+@tab @email{chengjin@@eecs.umich.edu}
@item Paul Callaway
-@email{pcallawa@@umich.edu}
+@tab @email{pcallawa@@umich.edu}
@item Brandon S. Allbery
-@email{allbery@@ece.cmu.edu}
+@tab @email{allbery@@ece.cmu.edu}
@item Ken Raeburn
-@email{raeburn@@raeburn.org}
+@tab @email{raeburn@@raeburn.org}
@item Jeffrey Hutzelman
-@email{jhutz+@@cmu.edu}
+@tab @email{jhutz+@@cmu.edu}
@item Hee-Seok Heo
-@email{hsheo@@postech.ac.kr}
+@tab @email{hsheo@@postech.ac.kr}
@item Paul Ewing Jr.
-@email{ewing@@ima.umn.edu}
+@tab @email{ewing@@ima.umn.edu}
@item Niklas Hallqvist
-@email{niklas@@appli.se}
+@tab @email{niklas@@appli.se}
@item Marko Asplund
-@email{aspa@@hip.fi}
+@tab @email{aspa@@hip.fi}
@item Chris Wing
-@email{wingc@@engin.umich.edu}
+@tab @email{wingc@@engin.umich.edu}
@item Simon Josefsson
-@email{jas@@pdc.kth.se}
+@tab @email{jas@@pdc.kth.se}
@item Magnus Lindström
-@email{magnus.lindstrom@@s3.kth.se}
+@tab @email{magnus.lindstrom@@s3.kth.se}
@item Greg Stark
-@email{gsstark@@mit.edu}
+@tab @email{gsstark@@mit.edu}
@item Matt
-@email{deberg@@mit.edu}
+@tab @email{deberg@@mit.edu}
@item Björn Grönvall
-@email{bg@@sics.se}
+@tab @email{bg@@sics.se}
@item Tino Schwarze
-@email{tino.schwarze@@informatik.tu-chemnitz.de}
+@tab @email{tino.schwarze@@informatik.tu-chemnitz.de}
@item David Sanderson
-@email{david@@transarc.ibm.com}
+@tab @email{david@@transarc.ibm.com}
@item Roman Hodek
-@email{Roman.Hodek@@informatik.uni-erlangen.de}
+@tab @email{Roman.Hodek@@informatik.uni-erlangen.de}
+
+@item Michael Sperber
+@tab @email{sperber@@informatik.uni-tuebingen.de}
+
+@item Dr. Lex Wennmacher
+@tab @email{wennmach@@geo.Uni-Koeln.DE}
+
+@item Janne Johansson
+@tab @email{jj@@dynarc.se}
+
+@item Dr A V Le Blanc
+@tab @email{LeBlanc@@mcc.ac.uk}
+
+@item Dave Morrison
+@tab @email{dave@@bnl.gov}
+
+@item Jochen Saile
+@tab @email{saile@@sfs.nphil.uni-tuebingen.de}
+
+@item Chris Kuklewicz
+@tab @email{chrisk@@MIT.EDU}
+
+@item Nickolai Zeldovich
+@tab @email{kolya@@MIT.EDU}
-@end table
+@end multitable
If you have done something and are not mentioned here, please send
mail to @email{arla-drinkers@@stacken.kth.se}.
diff --git a/usr.sbin/afs/src/doc/ack.texi.in b/usr.sbin/afs/src/doc/ack.texi.in
index c83ead9b9ec..c55c897d630 100644
--- a/usr.sbin/afs/src/doc/ack.texi.in
+++ b/usr.sbin/afs/src/doc/ack.texi.in
@@ -1,6 +1,9 @@
-@c $Id: ack.texi.in,v 1.1 2000/09/11 14:40:52 art Exp $
+@c Copyright (c) 1997 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+@c $KTH: ack.texi.in,v 1.5 2000/12/01 08:30:45 lha Exp $
-@node Acknowledgments, , Authors, Top
+@node Acknowledgments, Index, Authors, Top
@comment node-name, next, previous, up
@appendix Acknowledgments
@@ -19,11 +22,12 @@ NetBSD/FreeBSD
The code for gluing these together were written by ourselves.
Bugfixes, documentation, encouragement, and code has been contributed by:
-@table @asis
+
+@multitable @columnfractions .5 .5
%THANKS%
-@end table
+@end multitable
If you have done something and are not mentioned here, please send
mail to @email{arla-drinkers@@stacken.kth.se}.
diff --git a/usr.sbin/afs/src/doc/afs-basics.texi b/usr.sbin/afs/src/doc/afs-basics.texi
index 4fec475b9ca..8445e842d7b 100644
--- a/usr.sbin/afs/src/doc/afs-basics.texi
+++ b/usr.sbin/afs/src/doc/afs-basics.texi
@@ -1,13 +1,21 @@
-@c $Id: afs-basics.texi,v 1.1 2000/09/11 14:40:52 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
-@node Description of AFS infrastructure, Organization of data, Introduction, Top
+@c $KTH: afs-basics.texi,v 1.17 2000/12/01 08:31:07 lha Exp $
+
+@node AFS infrastructure, Organization of data, Introduction, Top
@comment node-name, next, previous, up
-@chapter Description of AFS infrastructure
+@chapter AFS infrastructure
This is an overview of the AFS infrastructure as viewed from a Transarc
perspective, since most people still run Transarc cells.
-@heading Server overview
+@section AFS Filespace
+
+@cindex AFS Filespace
+@cindex Filespace
+@cindex Cell
AFS filespace is split up in smaller parts called cells. These cells are
usually listed under @file{/afs}. A cell is usually a whole organization
@@ -17,20 +25,55 @@ electrical engineering at KTH, which obviously has the @file{e.kth.se}
domain in DNS. Using DNS domains for cell names is the typical and most
convenient way.
+Note that cell names are written in lowercase by convention.
+
+@section CellServDB
+
+@cindex CellServDB
All cells (and their db-servers) in the AFS world are listed in a file
named @file{CellServDB}. There is a central copy that is maintained by
-Transarc at @file{/afs/transarc.com/service/etc/CellServDB}. In
-addition Arla can use DNS to find the db-servers of a cell. The DNS
-resource record that is used is the AFSDB. It tells you what machines
-are db servers for a particular cell. The AFSDB resource record is also
-used for DCE/DFS. An example (the 1 means AFS, 2 is used for DCE):
+Transarc at @file{/afs/transarc.com/service/etc/CellServDB}.
+
+In spite of being organized in IPnumber - name pairs, where the name
+parts resemble comments, both values are used by Transarc software and
+confusion may arise if they are not synchronized with each other.
+
+@example
+
+>e.kth.se # Royal Institute of Technology, Elektro
+130.237.48.8 #sonen.e.kth.se.
+130.237.48.7 #anden.e.kth.se.
+130.237.48.244 #fadern.e.kth.se.
+
+@end example
+
+Again, please note that the text after the # in the cell-name is a
+comment, @strong{but} the hostnames after the # on the rows of an
+IP-address is @strong{not} a comment. The host and the ip-address needs
+to point at the same computer.
+
+@section AFSDB
+
+@cindex AFSDB
+@cindex DNS
+
+In addition Arla can use DNS to find the db-servers of a cell. The DNS
+resource record that is used is the @samp{AFSDB}. The resourcerecord was
+created by Transarc but have never been implemeted in released
+software.
+
+@samp{AFSDB} tells you what machines are db servers for a particular
+cell. The @samp{AFSDB} resourcerecord is also used for DCE/DFS. An example
+(the 1 means AFS, 2 is used for DCE):
@example
-e.kth.se. 1D IN AFSDB 1 sonen.e.kth.se.
-e.kth.se. 1D IN AFSDB 1 anden.e.kth.se.
-e.kth.se. 1D IN AFSDB 1 fadern.e.kth.se.
+e.kth.se. IN AFSDB 1 fadern.e.kth.se.
+e.kth.se. IN AFSDB 1 sonen.e.kth.se.
+e.kth.se. IN AFSDB 1 anden.e.kth.se.
@end example
+@section Shortcut names
+
Some cells use the abbreviated version
@file{/afs/<word-before-first-dot>} (in the example above that would be
@file{/afs/e/}. This might be convenient when typing them, but is a bad
@@ -38,7 +81,7 @@ idea, because it does not create the same name space everywhere. If you
create a symbolic link to @file{/afs/e/foo/bar}, it will not work for
people in other cells.
-Note that cell names are written in lowercase by convention.
+@section Server organization
There are several servers running in an AFS cell. For performance and
redundancy reasons, these servers are often run on different hosts.
@@ -59,8 +102,9 @@ Ubik (see below). The fileserver and the client software (like the
afsd/arlad, pts and, vos) are pulling meta-data out of the dbserver to
find where to find user-privileges and where volumes resides.
-@heading Basic overseer - boserver
+@section Basic overseer - boserver
+@cindex Bos server
The Bos server is making sure the servers are running. If they crash, it
saves the corefile, and starts a new server. It also makes sure that
servers/services that are not supposted to run at the same time do not.
@@ -69,8 +113,9 @@ devastating if salvage tried to correct data that the fileserver is
changing. The salvager is run before the fileserver starts. The
administrator can also force a file server to run through salvage again.
-@heading Ubik
+@section Ubik
+@cindex Ubik
Ubik is a distributed database. It is really a (distributed) flat file
that you can perform read/write/lseek operation on. The important
property of Ubik is that it provides a way to make sure that updates are
@@ -96,8 +141,10 @@ increased.
All servers in AFS use Ubik to store their data.
-@heading Volume Location database server - vlserver
+@section Volume Location database server - vlserver
+@cindex Vlserver
+@cindex Vldbserver
The vldb-server is resposible for the information on what fileserver
every volume resides and of what kind of volumes exists on each
fileserver.
@@ -109,25 +156,36 @@ some important differences.
AFS 3.3 is the classic interface. 3.4 adds the possibility of multihomed
servers for the client to talk to, and that introduces the N interface.
-To deal with multihomed clients AFS 3.5 was introduced. This we call the
-U interface.
+To deal with multihomed clients AFS 3.5 was introduced. This is called
+call the U interface. The name is due to how the functions are named.
The N interface added more replication-sites in the database-entry
structure. The U interface changed the server and clients in two ways.
-Now a server registers all its ip-addresses when it boots. This means
+When a 3.5 server boot it registers all its ip-addresses. This means
that a server can add (or remove) an network interface without
rebooting. When registering at the vldb server, the file server presents
itself with an UUID, an unique identifier. This UUID will be stored in a
file so the UUID keeps constant even when network addresses are changed,
added, or removed.
-@heading Protection server - ptserver
+@section Protection server - ptserver
+@cindex Ptserver
The protection server keeps track of all users and groups. It's used a
-lot by the file servers.
+lot by the file servers. Users can self create, modify and delete
+groups.
-@heading Kerberos server - kaserver
+When a fileserver is access they are durring the authentication giving
+the name of the client. This name if looked up in the
+protection-database via the protection server that returns the id of the
+user and all the groups that the user belongs too.
+
+This information is used when to check if the user have access to a
+particular file or directory. All files created by the user are assigned
+the user id that the protectionserver returned.
+
+@section Kerberos server - kaserver
The kaserver is a Kerberos server, but in other clothes. There is a new
RPC interface to get tickets (tokens) and administer the server. The
@@ -137,37 +195,65 @@ ordinary Kerberos v4 clients.
You can replace this server with an Heimdal kdc, since it provides a
superset of the functionality.
-@heading Backup server - buserver
+@section Backup server - buserver
+@cindex Backup server
+@cindex Buserver
The backup server keeps the backup database that is used when backing up
and restoring volumes. The backup server is not used by other servers,
only operators.
-@heading Update server - upserver
+@section Update server - upserver
+@cindex Upserver
With the update server its possible to automagicly update configuration
files, server binaries. You keep masters that are supposed to contain the
correct copy of all the files and then other servers can fetch them from there.
-@heading Fileserver and Volume Server - fs and volser
+@section Fileserver and Volume Server - fs and volser
+@cindex Fileserver
+@cindex Fsserver
+@cindex Volser
+@cindex Volumeserver
The file server serves data to the clients, keeps track of callbacks,
and breaks callbacks when needed. Volser is the administative interface
where you add, move, change, and delete volumes from the server.
The volume server and file server are ran at the same time and they sync
with each other to make sure that fileserver does not access a volume
-that volser is about to change.
+that volser is about to modify.
+
+Every time a fileserver is started it registers it IP addresses with the
+vldbserserver using the VL_RegisterAddrs rpc-call. As the unique identifier
+for itself it uses its afsUUID.
+
+The afsUUID for a fileserver is stored in /usr/afs/local/sysid. This is
+the reson you must not clone a server w/o removing the sysid
+file. Otherwise the new filserver will register as the old one and all
+volumes on the old fileserver are pointed to the new one (where the
+probably doesn't exist).
+
+The fileserver doesn't bind to a specific interface (read address), gets
+all packets that are destined for port 7000 (afs-fileserver/udp). All
+outgoing packets are send on the same socket, and means that your
+operatingsystem will choose the source-address of the udp datagram.
+
+This have the side-effect that you will have asymmetric routing on
+mulithomed fileserver for 3.4 (and older) compatible clients if they
+don't use the closest address when sorting the vldb entry. Arla avoids
+this problem.
-@heading Salvage
+@section Salvage
+@cindex Salvage
Salvage is not a real server. It is run before the fileserver and volser
are started to make sure the partitions are consistent.
It's imperative that salvager is NOT run at the same time as the
fileserver/volser is running.
-@heading Things that milko does differently.
+@section Things that milko does differently.
Fileserver, volumeserver, and salvage are all in one program.
diff --git a/usr.sbin/afs/src/doc/arla.info b/usr.sbin/afs/src/doc/arla.info
index 681ba046700..2c807c441f5 100644
--- a/usr.sbin/afs/src/doc/arla.info
+++ b/usr.sbin/afs/src/doc/arla.info
@@ -3,7 +3,7 @@ input file arla.texi.
INFO-DIR-SECTION Arla
START-INFO-DIR-ENTRY
-* Arla: (arla). Arla - The Free AFS Clone
+* Arla: (arla). Arla - A Free AFS Implementation
END-INFO-DIR-ENTRY

@@ -14,21 +14,82 @@ Arla
Arla is a free AFS implementation from KTH.
+Please send comments (and fixes) on this manual and the arla programs to
+<arla-drinkers@stacken.kth.se>.
+
* Menu:
+* Introduction:: Introduction to Arla.
+* AFS infrastructure:: A description of the afs infrastructure.
+* Organization of data:: How diffrent data are organized in AFS.
+* AFS and the real world:: Common problems and their solutions.
+* Parts of Arla:: Description of diffrent parts of arla.
+* Debugging:: How to debug arla when its not working.
+* Porting:: That you need to know to port arla.
+* Authors:: The authors of arla.
+* Oddities:: Strange things that have happen to us.
+* Arla timeline:: Short timeline of arla.
+* Acknowledgments:: People that have helped us.
+* Index:: Index.
+
+
+ -- The Detailed Node Listing --
+
* Introduction::
-* Description of AFS infrastructure::
-* Organization of data::
-* Parts of Arla::
-* Debugging::
+* AFS infrastructure::
+
+How data and servers are organized in AFS.
+
+* Requirements::
+* Data organization::
+* Callbacks::
+* Volume management::
+* Relationship between pts uid and unix uid::
+
+How to cope with reality
+
+* NAT::
+* Samba::
+
+The parts of arla
+
+* How arla works::
+* The relation between Arlad and XFS::
+* The life of a file::
+* Tools and libs::
+* The files in arlad/::
+* pioctl and kafs::
+
+Yes, its doesn't work, lets debug.
+
+* Arlad::
+* Debugging LWP with GDB::
+* xfs::
+* xfs on linux::
+* Debugging techniques::
+* Kernel debuggers::
+* Darwin/MacOS X::
+
+Porting arla
+
* Porting::
-* Authors::
+* Porting user-space::
+* Porting XFS::
+
+Odd stuff you find when looking around
+
* Oddities::
+
+Miscellaneous
+
* Arla timeline::
+* Authors::
* Acknowledgments::
+* Index::
+

-File: arla.info, Node: Introduction, Next: Description of AFS infrastructure, Prev: Top, Up: Top
+File: arla.info, Node: Introduction, Next: AFS infrastructure, Prev: Top, Up: Top
Introduction
************
@@ -46,11 +107,11 @@ Arla is a free AFS implementation. Some of the goals are:
and playing with cool stuff, like support for disconnected-mode.
Implement features you can't get from commercial AFS.
- * to provide an alternative to Transarc's AFS-client and server
- implementations.
+ * to provide an alternative to Transarc's and OpenAFS AFS-clients and
+ server implementations.
* to add support for platfroms that don't have AFS support from
- Transarc today.
+ Transarc or OpenAFS today.
This release is known to work on the following platforms: NetBSD,
OpenBSD, FreeBSD, Linux, Solaris, Darwin/MacOS X.
@@ -60,7 +121,7 @@ following platforms: SunOS, AIX, IRIX, Digital UNIX. Some fixes might
be necessary to make Arla work.
There is or has been done work to support the following platforms: HPUX,
-Fujitsu UXP/V, . Some development is necessary to make Arla work.
+Fujitsu UXP/V. Some development is necessary to make Arla work.
There is work going on to support the following platform: Windows
NT/2000. Contributions are very welcome.
@@ -110,21 +171,24 @@ Mailing list
There are two mailing lists with talk about Arla.
<arla-announce@stacken.kth.se> is a low-volume announcement list, while
-<arla-drinkers@stacken.kth.se> is for general discussion. There is
-also commit list <arla-commit@stacken.kth.se>. Send a message to
-<LIST-request@stacken.kth.se> to subscribe.
+<arla-drinkers@stacken.kth.se> is for general discussion.
+
+There is also commit list <arla-commit@stacken.kth.se>. Send a message
+to <LIST-request@stacken.kth.se> to subscribe.
+
+The list are achived on `http://www.stacken.kth.se/lists/'.

-File: arla.info, Node: Description of AFS infrastructure, Next: Organization of data, Prev: Introduction, Up: Top
+File: arla.info, Node: AFS infrastructure, Next: Organization of data, Prev: Introduction, Up: Top
-Description of AFS infrastructure
-*********************************
+AFS infrastructure
+******************
This is an overview of the AFS infrastructure as viewed from a Transarc
perspective, since most people still run Transarc cells.
-Server overview
-===============
+AFS Filespace
+=============
AFS filespace is split up in smaller parts called cells. These cells are
usually listed under `/afs'. A cell is usually a whole organization or
@@ -133,17 +197,47 @@ an adminstative unit within an organization. An example is e.kth.se
engineering at KTH, which obviously has the `e.kth.se' domain in DNS.
Using DNS domains for cell names is the typical and most convenient way.
+Note that cell names are written in lowercase by convention.
+
+CellServDB
+==========
+
All cells (and their db-servers) in the AFS world are listed in a file
named `CellServDB'. There is a central copy that is maintained by
-Transarc at `/afs/transarc.com/service/etc/CellServDB'. In addition
-Arla can use DNS to find the db-servers of a cell. The DNS resource
-record that is used is the AFSDB. It tells you what machines are db
-servers for a particular cell. The AFSDB resource record is also used
-for DCE/DFS. An example (the 1 means AFS, 2 is used for DCE):
+Transarc at `/afs/transarc.com/service/etc/CellServDB'.
+
+In spite of being organized in IPnumber - name pairs, where the name
+parts resemble comments, both values are used by Transarc software and
+confusion may arise if they are not synchronized with each other.
+
+
+ >e.kth.se # Royal Institute of Technology, Elektro
+ 130.237.48.8 #sonen.e.kth.se.
+ 130.237.48.7 #anden.e.kth.se.
+ 130.237.48.244 #fadern.e.kth.se.
+
+Again, please note that the text after the # in the cell-name is a
+comment, *but* the hostnames after the # on the rows of an IP-address
+is *not* a comment. The host and the ip-address needs to point at the
+same computer.
+
+AFSDB
+=====
+
+In addition Arla can use DNS to find the db-servers of a cell. The DNS
+resource record that is used is the `AFSDB'. The resourcerecord was
+created by Transarc but have never been implemeted in released software.
- e.kth.se. 1D IN AFSDB 1 sonen.e.kth.se.
- e.kth.se. 1D IN AFSDB 1 anden.e.kth.se.
- e.kth.se. 1D IN AFSDB 1 fadern.e.kth.se.
+`AFSDB' tells you what machines are db servers for a particular cell.
+The `AFSDB' resourcerecord is also used for DCE/DFS. An example (the 1
+means AFS, 2 is used for DCE):
+
+ e.kth.se. IN AFSDB 1 fadern.e.kth.se.
+ e.kth.se. IN AFSDB 1 sonen.e.kth.se.
+ e.kth.se. IN AFSDB 1 anden.e.kth.se.
+
+Shortcut names
+==============
Some cells use the abbreviated version `/afs/<word-before-first-dot>'
(in the example above that would be `/afs/e/'. This might be
@@ -151,7 +245,8 @@ convenient when typing them, but is a bad idea, because it does not
create the same name space everywhere. If you create a symbolic link
to `/afs/e/foo/bar', it will not work for people in other cells.
-Note that cell names are written in lowercase by convention.
+Server organization
+===================
There are several servers running in an AFS cell. For performance and
redundancy reasons, these servers are often run on different hosts.
@@ -225,13 +320,13 @@ some important differences.
AFS 3.3 is the classic interface. 3.4 adds the possibility of multihomed
servers for the client to talk to, and that introduces the N interface.
-To deal with multihomed clients AFS 3.5 was introduced. This we call the
-U interface.
+To deal with multihomed clients AFS 3.5 was introduced. This is called
+call the U interface. The name is due to how the functions are named.
The N interface added more replication-sites in the database-entry
structure. The U interface changed the server and clients in two ways.
-Now a server registers all its ip-addresses when it boots. This means
+When a 3.5 server boot it registers all its ip-addresses. This means
that a server can add (or remove) an network interface without
rebooting. When registering at the vldb server, the file server presents
itself with an UUID, an unique identifier. This UUID will be stored in a
@@ -242,7 +337,17 @@ Protection server - ptserver
============================
The protection server keeps track of all users and groups. It's used a
-lot by the file servers.
+lot by the file servers. Users can self create, modify and delete
+groups.
+
+When a fileserver is access they are durring the authentication giving
+the name of the client. This name if looked up in the
+protection-database via the protection server that returns the id of the
+user and all the groups that the user belongs too.
+
+This information is used when to check if the user have access to a
+particular file or directory. All files created by the user are assigned
+the user id that the protectionserver returned.
Kerberos server - kaserver
==========================
@@ -279,7 +384,27 @@ where you add, move, change, and delete volumes from the server.
The volume server and file server are ran at the same time and they sync
with each other to make sure that fileserver does not access a volume
-that volser is about to change.
+that volser is about to modify.
+
+Every time a fileserver is started it registers it IP addresses with the
+vldbserserver using the VL_RegisterAddrs rpc-call. As the unique
+identifier for itself it uses its afsUUID.
+
+The afsUUID for a fileserver is stored in /usr/afs/local/sysid. This is
+the reson you must not clone a server w/o removing the sysid file.
+Otherwise the new filserver will register as the old one and all
+volumes on the old fileserver are pointed to the new one (where the
+probably doesn't exist).
+
+The fileserver doesn't bind to a specific interface (read address), gets
+all packets that are destined for port 7000 (afs-fileserver/udp). All
+outgoing packets are send on the same socket, and means that your
+operatingsystem will choose the source-address of the udp datagram.
+
+This have the side-effect that you will have asymmetric routing on
+mulithomed fileserver for 3.4 (and older) compatible clients if they
+don't use the closest address when sorting the vldb entry. Arla avoids
+this problem.
Salvage
=======
@@ -300,7 +425,7 @@ Heimdal. Heimdal's kdc even implements a ka-server readonly interface,
so your users can keep using programs like klog.

-File: arla.info, Node: Organization of data, Next: Parts of Arla, Prev: Description of AFS infrastructure, Up: Top
+File: arla.info, Node: Organization of data, Next: AFS and the real world, Prev: AFS infrastructure, Up: Top
Organization of data
********************
@@ -315,6 +440,7 @@ requirements was and how that inpacted on the design.
* Data organization::
* Callbacks::
* Volume management::
+* Relationship between pts uid and unix uid::

File: arla.info, Node: Requirements, Next: Data organization, Prev: Organization of data, Up: Organization of data
@@ -419,10 +545,13 @@ is what a clone is) that can be replicated to several fileserver to
distribute the load. Each fileserver plus partition where the read-only
is located is called a replication-site.
-The backup volume is a clone that typically is made each night to enable
-the user to retrieve yestoday's data when they happen to remove a file.
-This is a very useful feature, since it lessen the load on the
-system-administrators to restore files from backup.
+The backup volume is a clone that typically is made (with `vos
+backupsys') each night to enable the user to retrieve yestoday's data
+when they happen to remove a file. This is a very useful feature, since
+it lessen the load on the system-administrators to restore files from
+backup. The volume is usually mounted in the root user's home directory
+under the name OldFiles. A special feature of the backup volume is that
+inside it you can't follow mountpoint.
Mountpoints
===========
@@ -449,24 +578,150 @@ callback.
For read-only callbacks there is only callback given its called a volume
callback and it will be broken when the read-only volume is updated.
+The time range of callbacks range from 1 hour to 5 minutes depending of
+how many user of the file exists.
+

-File: arla.info, Node: Volume management, Prev: Callbacks, Up: Organization of data
+File: arla.info, Node: Volume management, Next: Relationship between pts uid and unix uid, Prev: Callbacks, Up: Organization of data
Volume management
=================
+All volume managment is done with the vos-command. To get a list of all
+commands `vos help' can be used. For help on a specific vos subcommand,
+`vos subcommand -h' can be used.
+
* Create
+ vos create mim c HO.staff.lha.fluff -quota 400000
+
+ * Move
+
+ Volumes can be moved from a server to another, even when users are
+ using the volume.
+
* Replicate
+ Read-only volumes can be replicated over several servers, they are
+ first added with `vos addsite', and the replicated with `vos
+ release' out over the servers.
+
* Release
- * Delete
+ When you want to distribute out the changes in the readwrite
+ volume.
+
+ * Remove
+
+ Volumes can be removed
+
+ Note that you shouldn't remove the last readonly volume since this
+ make clients misbehave. If you are moving the volume you should
+ rather add a new RO to the new server and then remove it from the
+ old server.
+
+ * Backup and restoration of volumes.
+
+ `vos backup' and `vos backupsys' creates the backup volume.
+
+ To stream a volume out to a `file' or `stdout' you use `vos dump'.
+ The opposite command is named `vos restore'.
+
+
+File: arla.info, Node: Relationship between pts uid and unix uid, Prev: Volume management, Up: Organization of data
+
+Relationship between pts uid and unix uid
+=========================================
+
+foo
+
+
+File: arla.info, Node: AFS and the real world, Next: Parts of Arla, Prev: Organization of data, Up: Top
+
+AFS and the real world
+**********************
+
+This chapter tries to describe problems that you see in the real (not
+that perfect) world and show possible solutions to these problems.
+
+* Menu:
+
+* NAT:: Really evil stuff.
+* Samba:: Export AFS to Windows computers.
+* Integration with Kerberos:: How to integrate Kerberos with AFS.
+
+
+File: arla.info, Node: NAT, Next: Samba, Prev: AFS and the real world, Up: AFS and the real world
+
+NAT
+===
+
+There's something evil out there that's called NAT. For whatever
+reasons, people are using it and will continue doing so.
+
+First of all, it seemed like AFS should work just fine through NAT, you
+just appear to be coming from the NAT-address and some random port
+instead. Looking closer at different NAT implementations it seems like
+they have a rather short timeout:
- * Backup
+`FreeBSD natd'
+ 60 seconds
+
+`Cisco IOS'
+ 300 seconds
+
+`NetBSD ipf (ipnat)'
+ 600 seconds
+
+`Linux Nat (masq)'
+ 300 seconds
+
+And if the client doesn't transmit any traffic to a particular host for
+that amount of time, it will get mapped into a new address. And then
+the server will just figure out it has a new client, right?
+
+Wrong, the rx-connection is cached on the connection id, not the
+host/port pair. This is right, but the connection is never updated in
+the original rx-code. This have the unfortunate effect that the server
+keep talking to the old client.
+
+
+File: arla.info, Node: Samba, Next: Integration with Kerberos, Prev: NAT, Up: AFS and the real world
+
+Samba
+=====
+
+The major problem with getting AFS to exported read-write to SMB
+(Windows fileshareing) using Samba is how to transfer the user token to
+the smb-server. The simple may is to use clear-text password between the
+samba-server and the client, and then get tokens for the user with this
+password. This solution is clearly not acceptable for AFS administrators
+that are security aware.
+
+Describe here how to make AFS work "securely" with samba.
+
+
+File: arla.info, Node: Integration with Kerberos, Prev: Samba, Up: AFS and the real world
+
+Integration with Kerberos
+=========================
+
+Kerberos 4 and 5 can be integrated quite well with AFS. This is many due
+to that the security model used in AFS is in fact Keberos. The kaserver
+is a Kerberos 4 server with pre-authentication. Kaserver also provides a
+feature that you can only try a password N times, and after that you are
+locked out for half-an-hour. This feature require that
+pre-authentication is used, but since the ka-server provides a Kerberos
+4 interface (that doesn't use pre-authentication) is mostly worthless.
+
+Many sites indeed uses a kerberosserver instead of a kaserver. One of
+the resons are that they want to use Kerberos 5 (with for example
+Windows 2000).
+
+More text here how to create KeyFile, and describe TheseCells.

-File: arla.info, Node: Parts of Arla, Next: Debugging, Prev: Organization of data, Up: Top
+File: arla.info, Node: Parts of Arla, Next: Debugging, Prev: AFS and the real world, Up: Top
Parts of Arla
*************
@@ -658,18 +913,10 @@ LWP is a preepmtive thread package. It does it's context-switching by
creating a private stack for each thread. The heart of the package is
select(2).
-The core of the package is `process.S'. Its currenty built with a
-bourne-shell file. `Process.s' is preprocessed with `cpp' and then
-given to (g)as. The magic how to build this file a portable way is not
-fun.
-
The stack is checked for overruns in context-switches, but that is often
too late. It might be an idea to add a `red zone' at the top of the
stack to be able to detect overruns.
-For architectures not supported by LWP, it can be exchanged with the
-pthreads pakage.
-

File: arla.info, Node: The files in arlad/, Next: pioctl and kafs, Prev: Tools and libs, Up: Parts of Arla
@@ -809,11 +1056,31 @@ An example of using `pioctl()':
}

-File: arla.info, Node: Debugging, Next: Porting, Prev: Parts of Arla, Up: Top
+File: arla.info, Node: Debugging, Next: Arlad, Prev: Parts of Arla, Up: Top
Debugging
*********
+This chapter of the manual includes tips that are useful when debugging
+arla.
+
+Arla and xfs contains logging facilities that is quite useful when
+debugging when something goes wrong. This and some kernel debugging tips
+are described.
+
+* Menu:
+
+* Arlad::
+* Debugging LWP with GDB::
+* xfs::
+* xfs on linux::
+* Debugging techniques::
+* Kernel debuggers::
+* Darwin/MacOS X::
+
+
+File: arla.info, Node: Arlad, Next: Debugging LWP with GDB, Prev: Debugging, Up: Debugging
+
Arlad
=====
@@ -829,7 +1096,7 @@ To enable more debuggning run arla with the switch
The cleaner output is usully not that intresting and can be ignored.
A convenient way to debug arlad is to start it inside gdb.
- datan:~# gdb /usr/arla/bin/arlad
+ datan:~# gdb /usr/arla/libexec/arlad
(gdb) run -z -n
This gives you the opportunity to examine a crashed arlad.
(gdb) bt
@@ -846,6 +1113,60 @@ To set the debugging with a running arlad use `fs arladeb' as root.
By default, arlad logs through syslog if running as a daemon and to
stderr when running in the foreground (with `--no-fork').
+
+File: arla.info, Node: Debugging LWP with GDB, Next: xfs, Prev: Arlad, Up: Debugging
+
+Debugging LWP with GDB
+======================
+
+For easy tracing of threads we have patch
+(`http://www.stacken.kth.se/projekt/arla/gdb-4.18-backfrom.diff') for
+gdb 4.18 (a new command) and a gdb sequence (think script).
+
+The sequence only works for i386, but its just matter of choosing
+different offset in topstack to find $fp and $pc in the lwp_ps_internal
+part of the sequence.
+
+You should copy the `.gdbinit' (that you can find in the arlad
+directory in the source-code) to your home-directory, the directory from
+where you startat the patched gdb or use flag -x to gdb.
+
+Your debugging session might look like this:
+
+ (gdb) lwp_ps
+ Runnable[0]
+ name: IO MANAGER
+ eventlist:
+ fp: 0x806aac4
+ pc: 0x806aac4
+ name: producer
+ eventlist: 8048b00
+ fp: 0x8083b40
+ pc: 0x8083b40
+ Runnable[1]
+ [...]
+ (gdb) help backfrom
+ Print backtrace of FRAMEPOINTER and PROGRAMCOUNTER.
+
+ (gdb) backfrom 0x8083b40 0x8083b40
+ #0 0x8083b40 in ?? ()
+ #1 0x8049e2f in LWP_MwaitProcess (wcount=1, evlist=0x8083b70)
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/lwp.c:567
+ #2 0x8049eaf in LWP_WaitProcess (event=0x8048b00)
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/lwp.c:585
+ #3 0x8048b12 in Producer (foo=0x0)
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/testlwp.c:76
+ #4 0x804a00c in Create_Process_Part2 ()
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/lwp.c:629
+ #5 0xfffefdfc in ?? ()
+ #6 0x8051980 in ?? ()
+
+There also the possibility to run arla with pthreads (run configure with
+-with-pthreads).
+
+
+File: arla.info, Node: xfs, Next: xfs on linux, Prev: Debugging LWP with GDB, Up: Debugging
+
xfs
===
@@ -865,12 +1186,8 @@ will have to edit `xfs/YOUR-OS/xfs_deb.c' and recompile.
The logging of xfs ends up in your syslog. Syslog usully logs to
/var/log or /var/adm (look in /etc/syslog.conf).
-When reporting problems
-=======================
-
-Please do not include a whole log in a email. Most people on the list
-doesn't want to read this. Instead send a pointer to a URL (http or
-ftp).
+
+File: arla.info, Node: xfs on linux, Next: Debugging techniques, Prev: xfs, Up: Debugging
xfs on linux
============
@@ -881,18 +1198,228 @@ from the ring-bufer, and you will only get some of the message in your
cat.

-File: arla.info, Node: Porting, Next: Oddities, Prev: Debugging, Up: Top
+File: arla.info, Node: Debugging techniques, Next: Kernel debuggers, Prev: xfs on linux, Up: Debugging
+
+Debugging techniques
+====================
+
+Kernel debugging can sometimes force you to exercise your imagination.
+We have learned some different techniques that can be useful.
+
+Signals
+-------
+
+On operatingsystems with kernel debugger that you can use probably find
+where in the kernel a user-program live, and thus deadlocks or trigger
+the bad event, that later will result in a bug. This is a problem, how
+do you some a process to find where it did the intresting thing when you
+can't set a kernel breakpoint ?
+
+One way to be notified is to send a signal from the kernel module
+(psignal() on a BSD and force_sig() on linux). SIGABRT() is quite useful
+if you want to force a coredump. If you want to continue debugging, use
+SIGSTOP.
+
+Recreateable testcases
+----------------------
+
+Make sure bugs don't get reintroduced.
+
+
+File: arla.info, Node: Kernel debuggers, Next: Darwin/MacOS X, Prev: Debugging techniques, Up: Debugging
+
+Kernel debuggers
+================
+
+Kernel debuggers are the most useful tool when you are trying to figure
+out what's wrong with xfs. Unfortunately they also seem to have their
+own life and do not always behave as expected.
+
+Using GDB
+---------
+
+Kernel debugging on NetBSD, OpenBSD, FreeBSD and Darwin are almost the
+same. You get the idea from the NetBSD example below:
+
+ (gdb) file netbsd.N
+ (gdb) target kcore netbsd.N.core
+ (gdb) symbol-file /sys/arch/i386/compile/NUTCRACKER/netbsd.gdb
+
+This example loads the kernel symbols into gdb. But this doesn't show
+the xfs symbols, and that makes your life harder.
+
+Getting all symbols loaded at the same time
+-------------------------------------------
+
+If you want to use the symbols of xfs, there is a gdb command called
+`add-symbol-file' that is useful. The symbol file is obtained by
+loading the kernel module xfs with `kmodload -o /tmp/xfs-sym' (Darwin)
+or `modload' (NetBSD and OpenBSD). FreeBSD has a linker in the kernel
+that does the linking instead of relying on `ld'. The symbol address
+where the module is loaded get be gotten from `modstat', `kldstat' or
+`kmodstat' (it's in the `area' field).
+
+If you forgot the to run modstat/kldstat/kmodstat, you can extract the
+information from the kernel. In Darwin you look at the variable kmod
+(you might have to case it to a (kmod_info_t *). We have seen gdb loose
+the debugging info). kmod is the start of a linked list. Other BSDs have
+some variant of this.
+
+You should also source the commands in /sys/gdbscripts (NetBSD), or
+System/xnu/osfmk/.gdbinit (Darwin) to get commands like ps inside gdb.
+
+ datan:~# modstat Type Id Off Loadaddr Size Info Rev Module
+ Name DEV 0 29 ce37f000 002c ce388fc0 1 xfs_mod [...]
+ [...]
+ (gdb) add-symbol-table xfs.sym ce37f000
+
+Debugging processes, examine their stack, etc
+---------------------------------------------
+
+One of diffrencies between the BSD's are the `proc', a command that
+enables you do to a backtrace on all processes. On FreeBSD you give the
+`proc' command a `pid', but on NetBSD and OpenBSD you give a pointer to
+a `struct proc'.
+
+After you have ran `proc' to set the current process, you can examine
+the backtrace with the regular `backtrace' command.
+
+Darwin does't have a `proc' command. Instead you are supposed to use
+gdb sequences (System/xnu/osfmk/.gdbinit) to print process stacks,
+threads, activations, and other information.
+
+Debugging Linux
+---------------
+
+You can't get a crashdump for linux with patching the kernel. There are
+two projects have support for this. Mission Critical Linux
+`http://www.missioncritiallinux.com' and SGI `http://oss.sgi.com/'.
+
+Remember save the context of /proc/ksyms before you crash, since this is
+needed to figure out where the xfs symbols are located in the kernel.
+
+But you can still use the debugger (or objdump) to figure out where in
+the binary that you crashed.
+
+`ksymoops' can be used to create a backtrace.
+
+Using adb
+---------
+
+Adb is not a symbolic debugger, this means that you have to read the
+disassembled object-code to figure out where it made the wrong turn and
+died. You might be able to use GNU objdump to list the assembler and
+source-code intertwined (`objdump -S -d mod_xfs.o'). Remember that GNU
+binutils for sparc-v9 isn't that good yet.
+
+You can find the script that use use for the adb command `$<' in
+`/usr/lib/adb' and `/usr/platform/PLATFORNAME/adb'.
+
+Debugging a live kernel
+-----------------------
+
+An important thing to know is that you can debug a live kernel too, this
+can be useful to find dead-locks. To attach to a kernel you use a
+command like this on a BSD system (that is using gdb):
+
+ (gdb) file /netbsd
+ (gdb) target kcore /dev/mem
+ (gdb) symbol-file /sys/arch/i386/compile/NUTCRACKER/netbsd.gdb
+
+And on Solaris:
+
+ # adb -k /dev/ksyms /dev/mem
+
+Other useful debugging tools
+----------------------------
+
+Most diagnosics tools like ps, dmesg, and pstat on BSD systems used to
+look in kernel memory to extract information (and thus earned the name
+kmem-groovlers). On some systems they have been replaced with other
+method of getting their data, like /proc and sysctl.
+
+But due to their heritage they can still be used in with a kernel and
+coredump to extract information on some system.
+
+
+File: arla.info, Node: Darwin/MacOS X, Next: Porting, Prev: Kernel debuggers, Up: Debugging
+
+Darwin/MacOS X
+==============
+
+You'll need two computers to debug arlad/xfs on darwin since the common
+way to debug is to use a remote kernel-debugger over IP/UDP.
+
+First you need to publish the arp-address of the computer that you are
+going to crash.
+
+We have not found any kernel symbols in MacOSX Public Beta, so you
+should probably build your own kernel. Use Darwin xnu kernel source
+with cvs-tag: Apple-103-0-1 (not xnu-103).
+
+ gdb xfs.out
+ target remote-kdp
+ add-symbol-table ...
+ attach <host>
+
+
+File: arla.info, Node: Porting, Next: Oddities, Prev: Darwin/MacOS X, Up: Top
Porting
*******
The largest part of the work needed to port Arla to a new operating
system is in porting xfs, as kernel programming always is harder, less
-portable and messier than user-space dito. Arlad in test mode (`arlad
---test') should work without any porting on any system that's not very
-far away from Unix and that provides berkeley sockets (including
-cygwin32). Therefore we will concern ourselves mostly with how to port
-the XFS module.
+portable and messier than user-space dito. Arla in test mode
+(`arla-cli') should work without any porting on any system that's not
+very far away from Unix and that provides berkeley sockets (including
+cygwin32). The hard part is porting the XFS kernel module, and we will
+spent most of this text on how to do that.
+
+* Menu:
+
+* Porting user-space::
+* Porting XFS::
+
+
+File: arla.info, Node: Porting user-space, Next: Porting XFS, Prev: Porting, Up: Porting
+
+user-space
+==========
+
+The user-space parts should work on basically any system that is
+reasonably Posix and has berkeley sockets. The build uses autoconf and
+should adapt itself to most forseeable circumstances. If it fails to
+consider something that is missing or not working on the particular OS
+you are porting to, hard-code it to make sure that is what is missing
+and then try to create an autoconf test for it. If you fail to do so,
+or have no autoconf experience, send us the patches anyway and tell us
+where you are having the problem.
+
+LWP
+---
+
+The only thing that might take a little bit more effort in porting is
+the context-switch in the LWP user-level threads package. There are
+assembler versions for most of the common architectures in `lwp'. Part
+of the problem is getting this code assembled properly. There is
+unfortunately no easy and portable way of preprocessing and assembling
+code. There is a script `lwp/make-process.o.sh' that tries to do in
+some different ways, but it may fail for you. Next problem is that
+assembler syntax can vary a lot even on the same CPU. The source files
+are written in such a way that they should be acceptable to almost any
+syntax, but if it fails you have to find out what particular syntax has
+to be used and adapt the source file for that.
+
+The more interesting problem is if there is no support for your CPU.
+The first thing to try then is the `--with-pthreads' option that uses
+the pthreads library. If that fails or you want LWP working you have
+to figure out enough details on your CPU to write two functions in
+assembler, `savecontext' and `returnto' that save and restore the
+processor context.
+
+
+File: arla.info, Node: Porting XFS, Prev: Porting user-space, Up: Porting
XFS
===
@@ -951,11 +1478,13 @@ XFS
the major device number. If you're really lucky there's a new
way to get the kernel to add your `struct cdevsw' to the
global table when loading the module or a function that does
- the addition for you. If not, you'll have to fallback on
- looking for a free slot in the table and putting your struct
- cdevsw there. In some cases, this is not stored in a table but
- then there'll be a way of adding entries to the new data
- structure so you don't need to worry about it.
+ the addition for you. Otherwise there might be functions for
+ adding/removing devices to the global table. If not, you'll
+ have to fallback on looking for a free slot in the table and
+ putting your struct cdevsw there. In some cases, this is not
+ stored in a table but then there'll be a way of adding
+ entries to the new data structure so you don't need to worry
+ about it.
3. Adding a new system call
@@ -1039,7 +1568,7 @@ Operating systems
File: arla.info, Node: Arla timeline, Next: Authors, Prev: Oddities, Up: Top
Arla timeline
-=============
+*************
Arla have existed for quite some years.
@@ -1073,8 +1602,8 @@ members that it would be a nice thing to resume the arla development.
Some people suggested that it would be less trouble having someone with
access to the Transarc AFS source code port the code to the relevent
-platforms. Assar then ported xfs to FreeBSD 2.2.x in notime, just to
-show the high portability.
+platforms. Assar then ported xfs to FreeBSD 2.2.x in notime (over the
+night), just to show the high portability.
People started to understand that arla was a concept that would work,
and first out was Love Hörnqvist-Åstrand <lha@stacken.kth.se> to join.
@@ -1105,7 +1634,10 @@ them.
There was from this point a lot of work being done and quite a lot of
studies was "wasted". We learned a lot, but not the stuff we were
-expected too.
+expected to.
+
+We added support for `dynroot' and `fake-mp' to prepare for Windows and
+Darwin/MacOSX support.
In Mars 2000 preliminary support for MacOS X/Darwin 1.0 was merged in
by Magnus and Assar.
@@ -1116,6 +1648,8 @@ same time.
In June 2000 there was a presentation on MADE2000 in Gothenburg, Sweden.
+In September 2000 MacOS X Beta was working.
+
This just includes some milestones, for more information se Changelog.*
and NEWS files in the distribution.
@@ -1141,7 +1675,7 @@ Johan Danielsson, OSF/1 xfs
Hans Insulander, pts, OpenBSD maintainer
-Mattias Amnefelt, vos, milko
+Mattias Amnefelt, vos, milko, OSF/1
Harald Barth, doc
@@ -1151,7 +1685,7 @@ Mikael Vidstedt (userland, some milko stuff)
Jimmy Engelbercht (bos)
Rhapsody xfs port was contributed by Alexandra Ellwood <lxs@MIT.EDU>
-Previously, Rhapsody named Darwin.
+Later, Rhapsody was renamed Darwin.
Disconnected code is written by:
@@ -1160,11 +1694,10 @@ WUWEI SHEN <wwshen@engin.umich.edu>
Cheng Jin <chengjin@eecs.umich.edu>
Paul Callaway <pcallawa@umich.edu>
-For more contributors look in the THANKS file in the distribution on
-`ftp://ftp.stacken.kth.se/pub/arla/'.
+For contributors, see *Note Acknowledgments::.

-File: arla.info, Node: Acknowledgments, Prev: Authors, Up: Top
+File: arla.info, Node: Acknowledgments, Next: Index, Prev: Authors, Up: Top
Acknowledgments
***************
@@ -1185,116 +1718,52 @@ The code for gluing these together were written by ourselves.
Bugfixes, documentation, encouragement, and code has been contributed
by:
-Aaron M. Ucko
- <amu@MIT.EDU>
-
-Alec Wolman
- <wolman@cs.washington.edu>
-
-Alexandra Ellwood
- <lxs@MIT.EDU>
-
-Brad Keryan
- <keryan@andrew.cmu.edu>
-
-Constantine Sapuntzakis
- <csapuntz@openbsd.org>
-
-Dan Winship
- <danw@MIT.EDU>
-
-Derrick J Brashear
- <shadow@dementia.org>
-
-Harald Barth
- <haba@pdc.kth.se>
-
-Jim Doyle
- <jrd@bu.edu>
-
-John Davison
- <davisoja@clarkson.edu>
-
-John Hawkinson
- <jhawk@MIT.EDU>
-
-Karl Ramm
- <kcr@MIT.EDU>
-
-Mark Eichin
- <eichin@kitten.gen.ma.us>
-
-Per Boussard T/ED
- <Per.Boussard@era-t.ericsson.se>
-Dima Ruban
- <dima@best.net>
-
-Max
- <davros@cyclone.Stanford.EDU>
-
-Andrzej Filinski
- <andrzej@daimi.aau.dk>
-
-Chuck Lever
- <chuckl@netscape.com>
-
-WUWEI SHEN
- <wwshen@engin.umich.edu>
-
-Cheng Jin
- <chengjin@eecs.umich.edu>
-
-Paul Callaway
- <pcallawa@umich.edu>
-
-Brandon S. Allbery
- <allbery@ece.cmu.edu>
-
-Ken Raeburn
- <raeburn@raeburn.org>
-
-Jeffrey Hutzelman
- <jhutz+@cmu.edu>
-
-Hee-Seok Heo
- <hsheo@postech.ac.kr>
-
-Paul Ewing Jr.
- <ewing@ima.umn.edu>
-
-Niklas Hallqvist
- <niklas@appli.se>
-
-Marko Asplund
- <aspa@hip.fi>
-
-Chris Wing
- <wingc@engin.umich.edu>
-
-Simon Josefsson
- <jas@pdc.kth.se>
-
-Magnus Lindström
- <magnus.lindstrom@s3.kth.se>
-
-Greg Stark
- <gsstark@mit.edu>
-
-Matt
- <deberg@mit.edu>
-
-Björn Grönvall
- <bg@sics.se>
-
-Tino Schwarze
- <tino.schwarze@informatik.tu-chemnitz.de>
-
-David Sanderson
- <david@transarc.ibm.com>
-
-Roman Hodek
- <Roman.Hodek@informatik.uni-erlangen.de>
+Aaron M. Ucko <amu@MIT.EDU>
+Alec Wolman <wolman@cs.washington.edu>
+Alexandra Ellwood <lxs@MIT.EDU>
+Brad Keryan <keryan@andrew.cmu.edu>
+Constantine Sapuntzakis <csapuntz@openbsd.org>
+Dan Winship <danw@MIT.EDU>
+Derrick J Brashear <shadow@dementia.org>
+Harald Barth <haba@pdc.kth.se>
+Jim Doyle <jrd@bu.edu>
+John Davison <davisoja@clarkson.edu>
+John Hawkinson <jhawk@MIT.EDU>
+Karl Ramm <kcr@MIT.EDU>
+Mark Eichin <eichin@kitten.gen.ma.us>
+Per Boussard T/ED <Per.Boussard@era-t.ericsson.se>
+Dima Ruban <dima@best.net>
+Max <davros@cyclone.Stanford.EDU>
+Andrzej Filinski <andrzej@daimi.aau.dk>
+Chuck Lever <chuckl@netscape.com>
+WUWEI SHEN <wwshen@engin.umich.edu>
+Cheng Jin <chengjin@eecs.umich.edu>
+Paul Callaway <pcallawa@umich.edu>
+Brandon S. Allbery <allbery@ece.cmu.edu>
+Ken Raeburn <raeburn@raeburn.org>
+Jeffrey Hutzelman <jhutz+@cmu.edu>
+Hee-Seok Heo <hsheo@postech.ac.kr>
+Paul Ewing Jr. <ewing@ima.umn.edu>
+Niklas Hallqvist <niklas@appli.se>
+Marko Asplund <aspa@hip.fi>
+Chris Wing <wingc@engin.umich.edu>
+Simon Josefsson <jas@pdc.kth.se>
+Magnus Lindström <magnus.lindstrom@s3.kth.se>
+Greg Stark <gsstark@mit.edu>
+Matt <deberg@mit.edu>
+Björn Grönvall <bg@sics.se>
+Tino Schwarze <tino.schwarze@informatik.tu-chemnitz.de>
+David Sanderson <david@transarc.ibm.com>
+Roman Hodek <Roman.Hodek@informatik.uni-erlangen.de>
+Michael Sperber <sperber@informatik.uni-tuebingen.de>
+Dr. Lex Wennmacher <wennmach@geo.Uni-Koeln.DE>
+Janne Johansson <jj@dynarc.se>
+Dr A V Le Blanc <LeBlanc@mcc.ac.uk>
+Dave Morrison <dave@bnl.gov>
+Jochen Saile <saile@sfs.nphil.uni-tuebingen.de>
+Chris Kuklewicz <chrisk@MIT.EDU>
+Nickolai Zeldovich <kolya@MIT.EDU>
If you have done something and are not mentioned here, please send mail
to <arla-drinkers@stacken.kth.se>.
@@ -1302,31 +1771,97 @@ to <arla-drinkers@stacken.kth.se>.
If you are mentioned here and have not contributed, that's because we
expect you to.
+
+File: arla.info, Node: Index, Prev: Acknowledgments, Up: Top
+
+Index
+*****
+
+* Menu:
+
+* adb: Kernel debuggers.
+* AFS Filespace: AFS infrastructure.
+* AFSDB: AFS infrastructure.
+* ALG: NAT.
+* Archives: Introduction.
+* Arlad debugging: Arlad.
+* Backup server: AFS infrastructure.
+* Bos server: AFS infrastructure.
+* Bug reports: Introduction.
+* Buserver: AFS infrastructure.
+* Cell: AFS infrastructure.
+* CellServDB: AFS infrastructure.
+* Comments: Introduction.
+* Debugging: Debugging.
+* Debugging arlad: Arlad.
+* Debugging techniques: Debugging techniques.
+* Debugging XFS: xfs.
+* DNS: AFS infrastructure.
+* Fileserver: AFS infrastructure.
+* Filespace: AFS infrastructure.
+* Fsserver: AFS infrastructure.
+* Gdb: Debugging LWP with GDB.
+* Kernel debugging: Kernel debuggers.
+* Kernel debuging on linux: Kernel debuggers.
+* Ksymoops: Kernel debuggers.
+* Linux kernel debugging: Kernel debuggers.
+* Live kernel: Kernel debuggers.
+* Mail archives: Introduction.
+* Mailing list: Introduction.
+* Masquerading: NAT.
+* NAT: NAT.
+* PAT: NAT.
+* Ptserver: AFS infrastructure.
+* Salvage: AFS infrastructure.
+* Samba: Samba.
+* Ubik: AFS infrastructure.
+* Upserver: AFS infrastructure.
+* Vldbserver: AFS infrastructure.
+* Vlserver: AFS infrastructure.
+* Volser: AFS infrastructure.
+* Volumeserver: AFS infrastructure.
+* XFS debugging: xfs.
+

Tag Table:
-Node: Top210
-Node: Introduction520
-Node: Description of AFS infrastructure3701
-Node: Organization of data11783
-Node: Requirements12221
-Node: Data organization14280
-Node: Callbacks16271
-Node: Volume management16832
-Node: Parts of Arla17028
-Node: How arla works17478
-Node: The relation between Arlad and XFS18497
-Node: The life of a file19156
-Node: Tools and libs21677
-Node: Rx protocol22894
-Node: LWP23171
-Node: The files in arlad/23880
-Node: pioctl and kafs26005
-Node: Debugging28104
-Node: Porting30341
-Node: Oddities35036
-Node: Arla timeline35943
-Node: Authors39368
-Node: Acknowledgments40247
+Node: Top217
+Node: Introduction1893
+Node: AFS infrastructure5142
+Node: Organization of data15560
+Node: Requirements16038
+Node: Data organization18097
+Node: Callbacks20286
+Node: Volume management20954
+Node: Relationship between pts uid and unix uid22277
+Node: AFS and the real world22489
+Node: NAT22937
+Node: Samba24001
+Node: Integration with Kerberos24562
+Node: Parts of Arla25417
+Node: How arla works25869
+Node: The relation between Arlad and XFS26888
+Node: The life of a file27547
+Node: Tools and libs30068
+Node: Rx protocol31285
+Node: LWP31562
+Node: The files in arlad/31974
+Node: pioctl and kafs34099
+Node: Debugging36198
+Node: Arlad36674
+Node: Debugging LWP with GDB37917
+Node: xfs39672
+Node: xfs on linux40319
+Node: Debugging techniques40664
+Node: Kernel debuggers41596
+Node: Darwin/MacOS X46009
+Node: Porting46626
+Node: Porting user-space47234
+Node: Porting XFS48997
+Node: Oddities53346
+Node: Arla timeline54253
+Node: Authors57835
+Node: Acknowledgments58662
+Node: Index62898

End Tag Table
diff --git a/usr.sbin/afs/src/doc/arla.texi b/usr.sbin/afs/src/doc/arla.texi
index 05264ed4302..5fea248442b 100644
--- a/usr.sbin/afs/src/doc/arla.texi
+++ b/usr.sbin/afs/src/doc/arla.texi
@@ -1,6 +1,10 @@
\input texinfo @c -*- texinfo -*-
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+
@c %**start of header
-@c $Id: arla.texi,v 1.1 2000/09/11 14:40:52 art Exp $
+@c $KTH: arla.texi,v 1.40.2.7 2001/07/16 15:39:43 lha Exp $
@setfilename arla.info
@settitle ARLA
@iftex
@@ -17,20 +21,29 @@
@ifinfo
@dircategory Arla
@direntry
-* Arla: (arla). Arla - The Free AFS Clone
+* Arla: (arla). Arla - A Free AFS Implementation
@end direntry
@end ifinfo
@c title page
@titlepage
+@iftex
+@image{arla-logo}
+@sp 5
+@end iftex
+
+@ifnottex
@title Arla
-@subtitle A Free AFS Clone from KTH
-@subtitle Edition 0.1, for version 0.34
-@subtitle 1999 - 2000
+@end ifnottex
+
+@subtitle A Free AFS implementation from KTH
+@subtitle Edition 0.3, for Release 0.35.5
+@subtitle 1999 - 2001
+
@author Love Hörnquist-Åstrand
@author Assar Westerlund
@author Harald Barth
-@author last updated $Date: 2000/09/11 14:40:52 $
+@author last updated $KTH: 2001/07/16 15:39:43 $
@comment This text will show up in the output of texi2html
@def@fnotsupported{THIS TEXT MAY CONTAIN GARBLED OUTPUT BECAUSE THIS VIEW FORMAT DOES NOT SUPPORT TEXI FUNCTIONS}
@@ -38,9 +51,12 @@
@def@copynext{@vskip 20pt plus 1fil@penalty-1000}
@def@copyrightstart{}
@def@copyrightend{}
+
@page
@copyrightstart
-Copyright (c) 1998 - 1999 Kungliga Tekniska Högskolan
+@example
+
+Copyright (c) 1995 - 2000 Kungliga Tekniska Högskolan
(Royal Institute of Technology, Stockholm, Sweden).
All rights reserved.
@@ -55,12 +71,7 @@ are met:
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
-3. All advertising materials mentioning features or use of this software
- must display the following acknowledgement:
- This product includes software developed by Kungliga Tekniska
- Högskolan and its contributors.
-
-4. Neither the name of the Institute nor the names of its contributors
+3. Neither the name of the Institute nor the names of its contributors
may be used to endorse or promote products derived from this software
without specific prior written permission.
@@ -76,7 +87,9 @@ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
SUCH DAMAGE.
+@end example
@copynext
+@example
Copyright (c) 1988, 1990, 1993
The Regents of the University of California. All rights reserved.
@@ -113,7 +126,9 @@ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
SUCH DAMAGE.
+@end example
@copynext
+@example
Copyright 1992 Simmule Turner and Rich Salz. All rights reserved.
@@ -137,7 +152,42 @@ to the following restrictions:
4. This notice may not be removed or altered.
+
+@end example
+@copynext
+@example
+
+COPYRIGHT (C) 1998
+THE REGENTS OF THE UNIVERSITY OF MICHIGAN
+ALL RIGHTS RESERVED
+
+PERMISSION IS GRANTED TO USE, COPY, CREATE DERIVATIVE WORKS
+AND REDISTRIBUTE THIS SOFTWARE AND SUCH DERIVATIVE WORKS
+FOR ANY PURPOSE, SO LONG AS THE NAME OF THE UNIVERSITY OF
+MICHIGAN IS NOT USED IN ANY ADVERTISING OR PUBLICITY
+PERTAINING TO THE USE OR DISTRIBUTION OF THIS SOFTWARE
+WITHOUT SPECIFIC, WRITTEN PRIOR AUTHORIZATION. IF THE
+ABOVE COPYRIGHT NOTICE OR ANY OTHER IDENTIFICATION OF THE
+UNIVERSITY OF MICHIGAN IS INCLUDED IN ANY COPY OF ANY
+PORTION OF THIS SOFTWARE, THEN THE DISCLAIMER BELOW MUST
+ALSO BE INCLUDED.
+
+THIS SOFTWARE IS PROVIDED AS IS, WITHOUT REPRESENTATION
+FROM THE UNIVERSITY OF MICHIGAN AS TO ITS FITNESS FOR ANY
+PURPOSE, AND WITHOUT WARRANTY BY THE UNIVERSITY OF
+MICHIGAN OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING
+WITHOUT LIMITATION THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE
+REGENTS OF THE UNIVERSITY OF MICHIGAN SHALL NOT BE LIABLE
+FOR ANY DAMAGES, INCLUDING SPECIAL, INDIRECT, INCIDENTAL, OR
+CONSEQUENTIAL DAMAGES, WITH RESPECT TO ANY CLAIM ARISING
+OUT OF OR IN CONNECTION WITH THE USE OF THE SOFTWARE, EVEN
+IF IT HAS BEEN OR IS HEREAFTER ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+@end example
@copynext
+@example
/*
****************************************************************************
@@ -160,6 +210,7 @@ to the following restrictions:
****************************************************************************
*/
+@end example
@copyrightend
@end titlepage
@@ -182,41 +233,101 @@ to the following restrictions:
Arla is a free AFS implementation from KTH.
+Please send comments (and fixes) on this manual and the arla programs to
+@email{arla-drinkers@@stacken.kth.se}.
+
@end ifinfo
@menu
-* Introduction::
-* Description of AFS infrastructure::
-* Organization of data::
-* Parts of Arla::
-* Debugging::
+* Introduction:: Introduction to Arla.
+* AFS infrastructure:: A description of the afs infrastructure.
+* Organization of data:: How diffrent data are organized in AFS.
+* AFS and the real world:: Common problems and their solutions.
+* Parts of Arla:: Description of diffrent parts of arla.
+* Debugging:: How to debug arla when its not working.
+* Porting:: That you need to know to port arla.
+* Authors:: The authors of arla.
+* Oddities:: Strange things that have happen to us.
+* Arla timeline:: Short timeline of arla.
+* Acknowledgments:: People that have helped us.
+* Index:: Index.
+@c * Building and Installing::
+@c * Unreleased parts of the arla suite::
+
+@detailmenu
+
+ --- The Detailed Node Listing ---
+
+* Introduction::
+* AFS infrastructure::
+
+How data and servers are organized in AFS.
+
+* Requirements::
+* Data organization::
+* Callbacks::
+* Volume management::
+* Relationship between pts uid and unix uid::
+
+How to cope with reality
+
+* NAT::
+* Samba::
+
+The parts of arla
+
+* How arla works::
+* The relation between Arlad and XFS::
+* The life of a file::
+* Tools and libs::
+* The files in arlad/::
+* pioctl and kafs::
+
+Yes, its doesn't work, lets debug.
+
+* Arlad::
+* Debugging LWP with GDB::
+* xfs::
+* xfs on linux::
+* Debugging techniques::
+* Kernel debuggers::
+* Darwin/MacOS X::
+
+Porting arla
+
* Porting::
-* Authors::
+* Porting user-space::
+* Porting XFS::
+
+Odd stuff you find when looking around
+
* Oddities::
+
+Miscellaneous
+
* Arla timeline::
-* Acknowledgments::
+* Authors::
+* Acknowledgments::
+
+* Index::
+
+@end detailmenu
@end menu
-@c * What is AFS::
-@c * Building and Installing::
-@c * Unreleased parts of the arla suite::
-@c * Things that might be done better::
+
+@contents
@include intro.texi
-@c @include whatisafs.texi
@c @include install.texi
@include afs-basics.texi
@include storage.texi
+@include real-world.texi
@include partsofarla.texi
-@c @include milko.texi
@include debugging.texi
@include porting.texi
@include oddities.texi
@include timeline.texi
@include authors.texi
@include ack.texi
-
-@c @shortcontents
-@contents
+@include index.texi
@bye
-
diff --git a/usr.sbin/afs/src/doc/authors.texi b/usr.sbin/afs/src/doc/authors.texi
index 26bbf18b0e8..779a32e89c3 100644
--- a/usr.sbin/afs/src/doc/authors.texi
+++ b/usr.sbin/afs/src/doc/authors.texi
@@ -1,4 +1,8 @@
-@c $Id: authors.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+
+@c $KTH: authors.texi,v 1.13.2.1 2001/06/05 02:08:16 mattiasa Exp $
@node Authors, Acknowledgments, Arla timeline, Top
@chapter Authors
@@ -13,7 +17,7 @@ Currently writing on arla are
@item Robert Burgess, fs, Solaris xfs
@item Johan Danielsson, OSF/1 xfs
@item Hans Insulander, pts, OpenBSD maintainer
-@item Mattias Amnefelt, vos, milko
+@item Mattias Amnefelt, vos, milko, OSF/1
@item Harald Barth, doc
@item Tomas Olsson, milko
@item Mikael Vidstedt (userland, some milko stuff)
@@ -21,7 +25,7 @@ Currently writing on arla are
@end table
Rhapsody xfs port was contributed by Alexandra Ellwood <lxs@@MIT.EDU>
-Previously, Rhapsody named Darwin.
+Later, Rhapsody was renamed Darwin.
Disconnected code is written by:
@@ -31,6 +35,5 @@ Disconnected code is written by:
@item Paul Callaway <pcallawa@@umich.edu>
@end table
-For more contributors look in the THANKS file in the distribution on
-@url{ftp://ftp.stacken.kth.se/pub/arla/}.
+For contributors, see @ref{Acknowledgments}.
diff --git a/usr.sbin/afs/src/doc/debugging.texi b/usr.sbin/afs/src/doc/debugging.texi
index a699a26d624..effa91f61f1 100644
--- a/usr.sbin/afs/src/doc/debugging.texi
+++ b/usr.sbin/afs/src/doc/debugging.texi
@@ -1,10 +1,38 @@
-@c $Id: debugging.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
-@node Debugging, Porting, Parts of Arla, Top
+@c $KTH: debugging.texi,v 1.26 2001/01/08 18:01:07 lha Exp $
+
+@node Debugging, Arlad, Parts of Arla, Top
@chapter Debugging
+@cindex Debugging
+
+This chapter of the manual includes tips that are useful when debugging
+arla.
+
+Arla and xfs contains logging facilities that is quite useful when
+debugging when something goes wrong. This and some kernel debugging tips
+are described.
+
+@menu
+* Arlad::
+* Debugging LWP with GDB::
+* xfs::
+* xfs on linux::
+* Debugging techniques::
+* Kernel debuggers::
+* Darwin/MacOS X::
+@end menu
+
+@node Arlad, Debugging LWP with GDB, Debugging, Debugging
+@comment node-name, next, previous, up
@section Arlad
+@cindex Arlad debugging
+@cindex Debugging arlad
+
If arlad is run without any arguments arlad will fork(2) and log to
syslog(3). To disable forking use the --no-fork (-n) switch. In the
current state of the code, arlad is allways to be started with
@@ -20,7 +48,7 @@ The cleaner output is usully not that intresting and can be ignored.
A convenient way to debug arlad is to start it inside gdb.
@example
-datan:~# gdb /usr/arla/bin/arlad
+datan:~# gdb /usr/arla/libexec/arlad
(gdb) run -z -n
@end example
This gives you the opportunity to examine a crashed arlad.
@@ -42,8 +70,66 @@ datan:~#
By default, arlad logs through syslog if running as a daemon and to
stderr when running in the foreground (with @kbd{--no-fork}).
+@node Debugging LWP with GDB, xfs, Arlad, Debugging
+@comment node-name, next, previous, up
+@section Debugging LWP with GDB
+
+@cindex Gdb
+
+For easy tracing of threads we have patch
+(@url{http://www.stacken.kth.se/projekt/arla/gdb-4.18-backfrom.diff})
+for gdb 4.18 (a new command) and a gdb sequence (think script).
+
+The sequence only works for i386, but its just matter of choosing
+different offset in topstack to find $fp and $pc in the lwp_ps_internal
+part of the sequence.
+
+You should copy the @file{.gdbinit} (that you can find in the arlad
+directory in the source-code) to your home-directory, the directory from
+where you startat the patched gdb or use flag -x to gdb.
+
+Your debugging session might look like this:
+
+@example
+(gdb) lwp_ps
+Runnable[0]
+ name: IO MANAGER
+ eventlist:
+ fp: 0x806aac4
+ pc: 0x806aac4
+ name: producer
+ eventlist: 8048b00
+ fp: 0x8083b40
+ pc: 0x8083b40
+Runnable[1]
+[...]
+(gdb) help backfrom
+Print backtrace of FRAMEPOINTER and PROGRAMCOUNTER.
+
+(gdb) backfrom 0x8083b40 0x8083b40
+#0 0x8083b40 in ?? ()
+#1 0x8049e2f in LWP_MwaitProcess (wcount=1, evlist=0x8083b70)
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/lwp.c:567
+#2 0x8049eaf in LWP_WaitProcess (event=0x8048b00)
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/lwp.c:585
+#3 0x8048b12 in Producer (foo=0x0)
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/testlwp.c:76
+#4 0x804a00c in Create_Process_Part2 ()
+ at /afs/e.kth.se/home/staff/lha/src/cvs/arla-foo/lwp/lwp.c:629
+#5 0xfffefdfc in ?? ()
+#6 0x8051980 in ?? ()
+@end example
+
+There also the possibility to run arla with pthreads (run configure with
+--with-pthreads).
+
+@node xfs, xfs on linux, Debugging LWP with GDB, Debugging
+@comment node-name, next, previous, up
@section xfs
+@cindex Debugging XFS
+@cindex XFS debugging
+
XFS debugging does almost look the same on all platforms. They
all share same debugging flags, but not all are enabled on all
platforms.
@@ -63,12 +149,8 @@ will have to edit @file{xfs/@var{your-os}/xfs_deb.c} and recompile.
The logging of xfs ends up in your syslog. Syslog usully logs to /var/log
or /var/adm (look in /etc/syslog.conf).
-@section When reporting problems
-
-Please do not include a whole log in a email. Most people on the list
-doesn't want to read this. Instead send a pointer to a URL (http or
-ftp).
-
+@node xfs on linux, Debugging techniques, xfs, Debugging
+@comment node-name, next, previous, up
@section xfs on linux
There is a problem with klogd, it's too slow. Cat the @file{/proc/kmsg}
@@ -76,3 +158,180 @@ file instead. Remember to kill klogd, since the reader will delete the
text from the ring-bufer, and you will only get some of the message in
your cat.
+
+@node Debugging techniques, Kernel debuggers, xfs on linux, Debugging
+@comment node-name, next, previous, up
+@section Debugging techniques
+
+@cindex Debugging techniques
+
+Kernel debugging can sometimes force you to exercise your
+imagination. We have learned some different techniques that can be
+useful.
+
+@subsection Signals
+
+On operatingsystems with kernel debugger that you can use probably find
+where in the kernel a user-program live, and thus deadlocks or trigger
+the bad event, that later will result in a bug. This is a problem, how
+do you some a process to find where it did the intresting thing when you
+can't set a kernel breakpoint ?
+
+One way to be notified is to send a signal from the kernel module
+(psignal() on a BSD and force_sig() on linux). SIGABRT() is quite useful
+if you want to force a coredump. If you want to continue debugging,
+use SIGSTOP.
+
+@subsection Recreateable testcases
+
+Make sure bugs don't get reintroduced.
+
+@node Kernel debuggers, Darwin/MacOS X, Debugging techniques, Debugging
+@comment node-name, next, previous, up
+@section Kernel debuggers
+
+@cindex Kernel debugging
+
+Kernel debuggers are the most useful tool when you are trying to figure
+out what's wrong with xfs. Unfortunately they also seem to have their
+own life and do not always behave as expected.
+
+@subsection Using GDB
+
+Kernel debugging on NetBSD, OpenBSD, FreeBSD and Darwin are almost the
+same. You get the idea from the NetBSD example below:
+
+@example
+ (gdb) file netbsd.N
+ (gdb) target kcore netbsd.N.core
+ (gdb) symbol-file /sys/arch/i386/compile/NUTCRACKER/netbsd.gdb
+@end example
+
+This example loads the kernel symbols into gdb. But this doesn't show
+the xfs symbols, and that makes your life harder.
+
+@subsection Getting all symbols loaded at the same time
+
+If you want to use the symbols of xfs, there is a gdb command called
+@samp{add-symbol-file} that is useful. The symbol file is obtained by
+loading the kernel module xfs with @samp{kmodload -o /tmp/xfs-sym}
+(Darwin) or @samp{modload} (NetBSD and OpenBSD). FreeBSD has a linker
+in the kernel that does the linking instead of relying on @samp{ld}. The
+symbol address where the module is loaded get be gotten from
+@samp{modstat}, @samp{kldstat} or @samp{kmodstat} (it's in the
+@code{area} field).
+
+If you forgot the to run modstat/kldstat/kmodstat, you can extract the
+information from the kernel. In Darwin you look at the variable kmod
+(you might have to case it to a (kmod_info_t *). We have seen gdb loose
+the debugging info). kmod is the start of a linked list. Other BSDs have
+some variant of this.
+
+You should also source the commands in /sys/gdbscripts (NetBSD), or
+System/xnu/osfmk/.gdbinit (Darwin) to get commands like ps inside gdb.
+
+@example
+ datan:~# modstat Type Id Off Loadaddr Size Info Rev Module
+ Name DEV 0 29 ce37f000 002c ce388fc0 1 xfs_mod [...]
+ [...]
+ (gdb) add-symbol-table xfs.sym ce37f000
+@end example
+
+@subsection Debugging processes, examine their stack, etc
+
+One of diffrencies between the BSD's are the @code{proc}, a command that
+enables you do to a backtrace on all processes. On FreeBSD you give the
+@code{proc} command a @samp{pid}, but on NetBSD and OpenBSD you give a
+pointer to a @code{struct proc}.
+
+After you have ran @code{proc} to set the current process, you can
+examine the backtrace with the regular @code{backtrace} command.
+
+Darwin does't have a @code{proc} command. Instead you are supposed to
+use gdb sequences (System/xnu/osfmk/.gdbinit) to print process stacks,
+threads, activations, and other information.
+
+@subsection Debugging Linux
+
+@cindex Kernel debuging on linux
+@cindex Linux kernel debugging
+
+You can't get a crashdump for linux with patching the kernel. There are
+two projects have support for this. Mission Critical Linux
+@url{http://www.missioncritiallinux.com} and SGI
+@url{http://oss.sgi.com/}.
+
+Remember save the context of /proc/ksyms before you crash, since this is
+needed to figure out where the xfs symbols are located in the kernel.
+
+But you can still use the debugger (or objdump) to figure out where in
+the binary that you crashed.
+
+@cindex Ksymoops
+
+@code{ksymoops} can be used to create a backtrace.
+
+@subsection Using adb
+
+@cindex adb
+
+Adb is not a symbolic debugger, this means that you have to read the
+disassembled object-code to figure out where it made the wrong turn and
+died. You might be able to use GNU objdump to list the assembler and
+source-code intertwined (@samp{objdump -S -d mod_xfs.o}). Remember that
+GNU binutils for sparc-v9 isn't that good yet.
+
+You can find the script that use use for the adb command @samp{$<} in
+@file{/usr/lib/adb} and @file{/usr/platform/PLATFORNAME/adb}.
+
+@subsection Debugging a live kernel
+
+@cindex Live kernel
+
+An important thing to know is that you can debug a live kernel too, this
+can be useful to find dead-locks. To attach to a kernel you use a
+command like this on a BSD system (that is using gdb):
+
+@example
+ (gdb) file /netbsd
+ (gdb) target kcore /dev/mem
+ (gdb) symbol-file /sys/arch/i386/compile/NUTCRACKER/netbsd.gdb
+@end example
+
+And on Solaris:
+
+@example
+ # adb -k /dev/ksyms /dev/mem
+@end example
+
+
+@subsection Other useful debugging tools
+
+Most diagnosics tools like ps, dmesg, and pstat on BSD systems used to
+look in kernel memory to extract information (and thus earned the name
+kmem-groovlers). On some systems they have been replaced with other
+method of getting their data, like /proc and sysctl.
+
+But due to their heritage they can still be used in with a kernel and
+coredump to extract information on some system.
+
+@node Darwin/MacOS X, Porting, Kernel debuggers, Debugging
+@comment node-name, next, previous, up
+@section Darwin/MacOS X
+
+You'll need two computers to debug arlad/xfs on darwin since the common
+way to debug is to use a remote kernel-debugger over IP/UDP.
+
+First you need to publish the arp-address of the computer that you are
+going to crash.
+
+We have not found any kernel symbols in MacOSX Public Beta, so you
+should probably build your own kernel. Use Darwin xnu kernel source
+with cvs-tag: Apple-103-0-1 (not xnu-103).
+
+@example
+gdb xfs.out
+target remote-kdp
+add-symbol-table ...
+attach <host>
+@end example
diff --git a/usr.sbin/afs/src/doc/intro.texi b/usr.sbin/afs/src/doc/intro.texi
index be3da30c1df..6437b974d0f 100644
--- a/usr.sbin/afs/src/doc/intro.texi
+++ b/usr.sbin/afs/src/doc/intro.texi
@@ -1,6 +1,10 @@
-@c $Id: intro.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
-@node Introduction, Description of AFS infrastructure, Top, Top
+@c $KTH: intro.texi,v 1.15 2000/12/01 08:32:09 lha Exp $
+
+@node Introduction, AFS infrastructure, Top, Top
@comment node-name, next, previous, up
@chapter Introduction
@@ -10,7 +14,7 @@ If something doesn't work, it's probably because it doesn't. If you
don't have backup of your data, take backup.
@end quotation
-@heading What is Arla?
+@section What is Arla?
Arla is a free AFS implementation. Some of the goals are:
@@ -20,9 +24,11 @@ to have an implementation that is free and can be used for adding and
playing with cool stuff, like support for disconnected-mode. Implement
features you can't get from commercial AFS.
@item
-to provide an alternative to Transarc's AFS-client and server implementations.
+to provide an alternative to Transarc's and OpenAFS AFS-clients and
+server implementations.
@item
-to add support for platfroms that don't have AFS support from Transarc today.
+to add support for platfroms that don't have AFS support from Transarc
+or OpenAFS today.
@end itemize
This release is known to work on the following platforms: NetBSD,
@@ -33,12 +39,12 @@ following platforms: SunOS, AIX, IRIX, Digital UNIX. Some fixes might
be necessary to make Arla work.
There is or has been done work to support the following platforms: HPUX,
-Fujitsu UXP/V, . Some development is necessary to make Arla work.
+Fujitsu UXP/V. Some development is necessary to make Arla work.
There is work going on to support the following platform: Windows
NT/2000. Contributions are very welcome.
-@heading Status
+@section Status
Arla has the following features (quality varies between
stable and not implemented):
@@ -64,7 +70,10 @@ API to the storage backend(s). Milko is still unstable and
not fit for production yet.
@end itemize
-@heading Bug reports
+@section Bug reports
+
+@cindex Bug reports
+@cindex Comments
If you find bugs in this software, make sure it is a genuine bug and not
just a part of the code that isn't implemented.
@@ -78,12 +87,20 @@ one. Please make any patches with @code{diff -u} or @code{diff -c}.
Suggestions, comments and other non bug reports are also welcome.
-@heading Mailing list
+@section Mailing list
+
+@cindex Mailing list
+@cindex Mail archives
+@cindex Archives
There are two mailing lists with talk about
Arla. @email{arla-announce@@stacken.kth.se} is a low-volume announcement
list, while @email{arla-drinkers@@stacken.kth.se} is for general
-discussion. There is also commit list
+discussion.
+
+There is also commit list
@email{arla-commit@@stacken.kth.se}. Send a message to
@email{LIST-request@@stacken.kth.se} to subscribe.
+The list are achived on
+@url{http://www.stacken.kth.se/lists/}.
diff --git a/usr.sbin/afs/src/doc/oddities.texi b/usr.sbin/afs/src/doc/oddities.texi
index 4127a748c12..07ba804a28d 100644
--- a/usr.sbin/afs/src/doc/oddities.texi
+++ b/usr.sbin/afs/src/doc/oddities.texi
@@ -1,4 +1,8 @@
-@c $Id: oddities.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+
+@c $KTH: oddities.texi,v 1.7 2000/10/03 01:09:56 lha Exp $
@node Oddities, Arla timeline, Porting, Top
@chapter Oddities
diff --git a/usr.sbin/afs/src/doc/partsofarla.texi b/usr.sbin/afs/src/doc/partsofarla.texi
index c349dd5b4f4..7e215855fef 100644
--- a/usr.sbin/afs/src/doc/partsofarla.texi
+++ b/usr.sbin/afs/src/doc/partsofarla.texi
@@ -1,6 +1,10 @@
-@c $Id: partsofarla.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
-@node Parts of Arla, Debugging, Organization of data, Top
+@c $KTH: partsofarla.texi,v 1.19 2000/11/25 11:24:06 lha Exp $
+
+@node Parts of Arla, Debugging, AFS and the real world, Top
@comment node-name, next, previous, up
@chapter Parts of Arla
diff --git a/usr.sbin/afs/src/doc/porting.texi b/usr.sbin/afs/src/doc/porting.texi
index cd8d956796d..fd332c9f59d 100644
--- a/usr.sbin/afs/src/doc/porting.texi
+++ b/usr.sbin/afs/src/doc/porting.texi
@@ -1,16 +1,59 @@
-@c $Id: porting.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
-@node Porting, Oddities, Debugging, Top
+@c $KTH: porting.texi,v 1.11 2000/11/25 14:18:42 lha Exp $
+
+@node Porting, Oddities, Darwin/MacOS X, Top
@chapter Porting
The largest part of the work needed to port Arla to a new operating
system is in porting xfs, as kernel programming always is harder, less
-portable and messier than user-space dito. Arlad in test mode
-(@kbd{arlad --test}) should work without any porting on any system
-that's not very far away from Unix and that provides berkeley sockets
-(including cygwin32). Therefore we will concern ourselves mostly with
-how to port the XFS module.
-
+portable and messier than user-space dito. Arla in test mode
+(@kbd{arla-cli}) should work without any porting on any system that's
+not very far away from Unix and that provides berkeley sockets
+(including cygwin32). The hard part is porting the XFS kernel module,
+and we will spent most of this text on how to do that.
+
+@menu
+* Porting user-space::
+* Porting XFS::
+@end menu
+
+@node Porting user-space, Porting XFS, Porting, Porting
+@section user-space
+
+The user-space parts should work on basically any system that is
+reasonably Posix and has berkeley sockets. The build uses autoconf and
+should adapt itself to most forseeable circumstances. If it fails to
+consider something that is missing or not working on the particular OS
+you are porting to, hard-code it to make sure that is what is missing
+and then try to create an autoconf test for it. If you fail to do so,
+or have no autoconf experience, send us the patches anyway and tell us
+where you are having the problem.
+
+@subsection LWP
+
+The only thing that might take a little bit more effort in porting is
+the context-switch in the LWP user-level threads package. There are
+assembler versions for most of the common architectures in @file{lwp}.
+Part of the problem is getting this code assembled properly. There is
+unfortunately no easy and portable way of preprocessing and assembling
+code. There is a script @file{lwp/make-process.o.sh} that tries to do
+in some different ways, but it may fail for you. Next problem is that
+assembler syntax can vary a lot even on the same CPU. The source files
+are written in such a way that they should be acceptable to almost any
+syntax, but if it fails you have to find out what particular syntax has
+to be used and adapt the source file for that.
+
+The more interesting problem is if there is no support for your CPU.
+The first thing to try then is the @kbd{--with-pthreads} option that
+uses the pthreads library. If that fails or you want LWP working you
+have to figure out enough details on your CPU to write two functions in
+assembler, @samp{savecontext} and @samp{returnto} that save and
+restore the processor context.
+
+@node Porting XFS, , Porting user-space, Porting
@section XFS
@enumerate
@@ -75,7 +118,9 @@ struct cdevsw cdevsw[];
These are then usually stored in a table `cdevsw' indexed by the major
device number. If you're really lucky there's a new way to get the
kernel to add your `struct cdevsw' to the global table when loading the
-module or a function that does the addition for you. If not, you'll have
+module or a function that does the addition for you. Otherwise there
+might be functions for adding/removing devices to the global table.
+If not, you'll have
to fallback on looking for a free slot in the table and putting your
struct cdevsw there. In some cases, this is not stored in a table but
then there'll be a way of adding entries to the new data structure so
@@ -85,7 +130,7 @@ you don't need to worry about it.
Adding a new system call
This is quite similar to adding a new cdev but the table is usually
-called `sysent' instead.
+called @code{sysent} instead.
@item
Adding a new file system
diff --git a/usr.sbin/afs/src/doc/servers.texi b/usr.sbin/afs/src/doc/servers.texi
index 93f68bc4fb9..f5c4f3f4ab6 100644
--- a/usr.sbin/afs/src/doc/servers.texi
+++ b/usr.sbin/afs/src/doc/servers.texi
@@ -1,4 +1,8 @@
-@c $Id: servers.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+
+@c $KTH: servers.texi,v 1.10 2000/12/01 08:32:34 lha Exp $
@c
@c This file contain random junk that should be ordered some day
@@ -7,6 +11,9 @@
@section YDR
+@cindex Ydr
+@cindex Rxgen
+
@code{Ydr} is a rxgen replacement that is generating a lot more stuff
then rxgen (like headerfiles). It also does the same thing in one run
instead of three (rxgen does one run for ss.c cs.c and .h, and each time
@@ -32,30 +39,6 @@ a file) is called ydra.
@end itemize
-@section CellServDB
-
-Transarc users a flat file called @code{CellServDB} to distribute the
-knowledge of what cells exist in the world. There is a way to represent
-that kind of information in DNS, but Transarc never implemented that in
-their software. Arla uses both ways to build its view of the AFS world.
-In spite of being organized in IPnumber - name pairs, where the name
-parts resemble comments, both values are used by Transarc software and
-confusion may arise if they are not synchronized with each other.
-
-@example
-
->stacken.kth.se # Stacken Computer Club, KTH, Sweden
-130.237.234.3 #milko.stacken.kth.se
-130.237.234.43 #hot.stacken.kth.se
-130.237.237.230 #fishburger.stacken.kth.se
-
-@end example
-
-Again, please note that the text after the # in the cell-name is a
-comment, @strong{but} the hostnames after the # on the rows of an
-IP-address is @strong{not} a comment. The host and the ip-address needs
-to point at the same computer.
-
@c Creations of a volume
@c VOLSER_ListPartions
@c VL_GetEntryByNameN -> VL_NOENT
diff --git a/usr.sbin/afs/src/doc/storage.texi b/usr.sbin/afs/src/doc/storage.texi
index f45f37708ec..47de0a311fc 100644
--- a/usr.sbin/afs/src/doc/storage.texi
+++ b/usr.sbin/afs/src/doc/storage.texi
@@ -1,6 +1,10 @@
-@c $Id: storage.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
-@node Organization of data, Parts of Arla, Description of AFS infrastructure, Top
+@c $KTH: storage.texi,v 1.7 2000/11/25 11:23:56 lha Exp $
+
+@node Organization of data, AFS and the real world, AFS infrastructure, Top
@comment node-name, next, previous, up
@chapter Organization of data
@@ -14,11 +18,12 @@ requirements was and how that inpacted on the design.
* Data organization::
* Callbacks::
* Volume management::
+* Relationship between pts uid and unix uid::
@end menu
@node Requirements, Data organization, Organization of data, Organization of data
@comment node-name, next, previous, up
-@heading Requirements
+@section Requirements
@itemize @bullet
@item Scalability
@@ -60,7 +65,7 @@ critical data
@end itemize
@end itemize
-@heading Anti-requirements
+@section Anti-requirements
@itemize @bullet
@item No databases
@@ -79,7 +84,7 @@ solving a database problem. Don't use AFS.
@node Data organization, Callbacks, Requirements, Organization of data
@comment node-name, next, previous, up
-@heading Volume
+@section Volume
A volume is a unit that is smaller then a partition. Its usually (should
be) a well defined area, like a user's home directory, a project work
@@ -88,7 +93,7 @@ area, or a program distribution.
Quota is controlled on volume-level. All day-to-day management are done
on volumes.
-@heading Partition
+@section Partition
In AFS a partition is what normally is named a partition. All partions
that afs isusing is named a special way, @file{/vicepNN}, where NN is
@@ -99,7 +104,7 @@ Volumes are stored in a partition. Volumes can't overlap
partitions. Partitions are added when the fileserver is created or when
a new disk is added to a filesystem.
-@heading Volume cloning and read-only clones
+@section Volume cloning and read-only clones
A clone of volume is often needed for the volume operations. A clone is
copy-on-write copy of a volume, the clone is the read-only version.
@@ -110,12 +115,15 @@ is what a clone is) that can be replicated to several fileserver to
distribute the load. Each fileserver plus partition where the read-only
is located is called a replication-site.
-The backup volume is a clone that typically is made each night to enable
-the user to retrieve yestoday's data when they happen to remove a
-file. This is a very useful feature, since it lessen the load on the
-system-administrators to restore files from backup.
+The backup volume is a clone that typically is made (with @code{vos
+backupsys}) each night to enable the user to retrieve yestoday's data
+when they happen to remove a file. This is a very useful feature, since
+it lessen the load on the system-administrators to restore files from
+backup. The volume is usually mounted in the root user's home directory
+under the name OldFiles. A special feature of the backup volume is that
+inside it you can't follow mountpoint.
-@heading Mountpoints
+@section Mountpoints
The volumes are independent of each other. To clue the together there is
a @samp{mountpoint}s. Mountpoints are really symlink that is formated a
@@ -125,7 +133,7 @@ be the root directory of the target volume.
@node Callbacks, Volume management, Data organization, Organization of data
@comment node-name, next, previous, up
-@heading Callbacks
+@section Callbacks
Callbacks are what enable the AFS-cache-manager to keep the files
without asking the server if there is newer version of the file.
@@ -137,14 +145,60 @@ callback.
For read-only callbacks there is only callback given its called a volume
callback and it will be broken when the read-only volume is updated.
-@node Volume management, , Callbacks, Organization of data
+The time range of callbacks range from 1 hour to 5 minutes depending of
+how many user of the file exists.
+
+@node Volume management, Relationship between pts uid and unix uid, Callbacks, Organization of data
@comment node-name, next, previous, up
-@heading Volume management
+@section Volume management
+
+All volume managment is done with the vos-command. To get a list of all
+commands `vos help' can be used. For help on a specific vos subcommand,
+`vos subcommand -h' can be used.
@itemize @bullet
@item Create
+
+@example
+vos create mim c HO.staff.lha.fluff -quota 400000
+@end example
+
+@item Move
+
+Volumes can be moved from a server to another, even when users are using
+the volume.
+
@item Replicate
+
+Read-only volumes can be replicated over several servers, they are first
+added with @code{vos addsite}, and the replicated with @code{vos
+release} out over the servers.
+
@item Release
-@item Delete
-@item Backup
+
+When you want to distribute out the changes in the readwrite volume.
+
+@item Remove
+
+Volumes can be removed
+
+Note that you shouldn't remove the last readonly volume since this make
+clients misbehave. If you are moving the volume you should rather add a
+new RO to the new server and then remove it from the old server.
+
+@item Backup and restoration of volumes.
+
+@code{vos backup} and @code{vos backupsys} creates the backup volume.
+
+To stream a volume out to a @file{file} or @file{stdout} you use
+@code{vos dump}. The opposite command is named @code{vos restore}.
+
@end itemize
+
+@node Relationship between pts uid and unix uid, , Volume management, Organization of data
+@comment node-name, next, previous, up
+@section Relationship between pts uid and unix uid
+
+foo
+
+
diff --git a/usr.sbin/afs/src/doc/timeline.texi b/usr.sbin/afs/src/doc/timeline.texi
index 9b6066c6545..b1dd29b7cce 100644
--- a/usr.sbin/afs/src/doc/timeline.texi
+++ b/usr.sbin/afs/src/doc/timeline.texi
@@ -1,4 +1,8 @@
-@c $Id: timeline.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+
+@c $KTH: timeline.texi,v 1.5 2000/12/10 23:06:32 lha Exp $
@node Arla timeline, Authors, Oddities, Top
@comment node-name, next, previous, up
@@ -37,8 +41,8 @@ development.
Some people suggested that it would be less trouble having someone with
access to the Transarc AFS source code port the code to the relevent
-platforms. Assar then ported xfs to FreeBSD 2.2.x in notime, just to
-show the high portability.
+platforms. Assar then ported xfs to FreeBSD 2.2.x in notime (over the
+night), just to show the high portability.
People started to understand that arla was a concept that would work,
and first out was Love Hörnqvist-Åstrand @email{lha@@stacken.kth.se} to
@@ -69,7 +73,10 @@ store them.
There was from this point a lot of work being done and quite a lot of
studies was "wasted". We learned a lot, but not the stuff we were
-expected too.
+expected to.
+
+We added support for `dynroot' and `fake-mp' to prepare for Windows and
+Darwin/MacOSX support.
In Mars 2000 preliminary support for MacOS X/Darwin 1.0 was merged in
by Magnus and Assar.
@@ -80,5 +87,7 @@ same time.
In June 2000 there was a presentation on MADE2000 in Gothenburg, Sweden.
+In September 2000 MacOS X Beta was working.
+
This just includes some milestones, for more information se
Changelog.* and NEWS files in the distribution.
diff --git a/usr.sbin/afs/src/doc/tools.texi b/usr.sbin/afs/src/doc/tools.texi
index a2005c9ae59..43b433b23ae 100644
--- a/usr.sbin/afs/src/doc/tools.texi
+++ b/usr.sbin/afs/src/doc/tools.texi
@@ -1,4 +1,8 @@
-@c $Id: tools.texi,v 1.1 2000/09/11 14:40:53 art Exp $
+@c Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+@c (Royal Institute of Technology, Stockholm, Sweden).
+@c All rights reserved.
+
+@c $KTH: tools.texi,v 1.4 2000/10/03 01:10:33 lha Exp $
@node Rx protocol, LWP, , Tools and libs
@section Rx protocol
@@ -21,14 +25,6 @@ LWP is a preepmtive thread package. It does it's context-switching by
creating a private stack for each thread. The heart of the package is
select(2).
-The core of the package is @file{process.S}. Its currenty built with a
-bourne-shell file. @file{Process.s} is preprocessed with @code{cpp} and
-then given to (g)as. The magic how to build this file a portable way is
-not fun.
-
The stack is checked for overruns in context-switches, but that is often
too late. It might be an idea to add a @cite{red zone} at the top of the
stack to be able to detect overruns.
-
-For architectures not supported by LWP, it can be exchanged with the
-pthreads pakage.
diff --git a/usr.sbin/afs/src/doc/xfs.txt b/usr.sbin/afs/src/doc/xfs.txt
index d48dd073433..90bd248e0cc 100644
--- a/usr.sbin/afs/src/doc/xfs.txt
+++ b/usr.sbin/afs/src/doc/xfs.txt
@@ -2,7 +2,7 @@
XFS DOCUMENTATION
=================
-$Id: xfs.txt,v 1.2 2001/04/10 08:17:54 deraadt Exp $
+$KTH: xfs.txt,v 1.5 2000/06/06 15:21:12 lha Exp $
This is not the truth, but close too.
diff --git a/usr.sbin/afs/src/include/Makefile.in b/usr.sbin/afs/src/include/Makefile.in
index 6ee7114ad68..55ca01db072 100644
--- a/usr.sbin/afs/src/include/Makefile.in
+++ b/usr.sbin/afs/src/include/Makefile.in
@@ -1,6 +1,7 @@
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:53 art Exp $
+# $KTH: Makefile.in,v 1.50 2000/12/21 12:46:09 lha Exp $
srcdir = @srcdir@
+top_builddir = ..
VPATH = @srcdir@
SHELL = /bin/sh
@@ -22,18 +23,22 @@ prefix = @prefix@
exec_prefix = @exec_prefix@
includedir = @includedir@
-LOCL_HEADERS = roken.h ko.h sl.h part.h list.h \
+ROKEN_H = @ROKEN_H@
+
+LOCL_HEADERS = $(ROKEN_H) ko.h sl.h part.h list.h \
bool.h log.h \
hash.h \
lwp.h lock.h getarg.h err.h parse_units.h \
resolve.h rxkad.h service.h mmaptime.h ports.h \
heap.h fbuf.h fdir.h afs_dir.h parse_time.h parse_bytes.h \
- acl.h
+ acl.h agetarg.h
BUILDHEADERS = atypes.h fs_errors.h
HEADERS = $(BUILDHEADERS)
+LIBS = @LIBS@
+
BITS_OBJECTS = bits.o
SOURCES = bits.c
@@ -58,7 +63,7 @@ uninstall:
done
bits: $(BITS_OBJECTS)
- $(CC) -o $@ $(BITS_OBJECTS)
+ $(CC) -o $@ $(BITS_OBJECTS) $(LIBS)
bits.o: bits.c
@@ -84,6 +89,8 @@ part.h:
$(LN_S) $(srcdir)/../lib/ko/part.h .
ports.h:
$(LN_S) $(srcdir)/../lib/ko/ports.h .
+agetarg.h:
+ $(LN_S) $(srcdir)/../lib/ko/agetarg.h .
atom.h:
$(LN_S) $(srcdir)/../util/atom.h .
list.h:
diff --git a/usr.sbin/afs/src/include/bits.c b/usr.sbin/afs/src/include/bits.c
index 82e5ab98e0d..df07fc5eae2 100644
--- a/usr.sbin/afs/src/include/bits.c
+++ b/usr.sbin/afs/src/include/bits.c
@@ -38,7 +38,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
-RCSID("$Id: bits.c,v 1.3 2000/09/11 14:40:54 art Exp $");
+RCSID("$KTH: bits.c,v 1.6 1998/12/20 15:55:29 assar Exp $");
#endif
#include <stdio.h>
#include <string.h>
@@ -141,7 +141,7 @@ int main(int argc, char **argv)
}
fprintf(f, "/* %s -- this file was generated for %s by\n", fn, HOST);
fprintf(f, " %*s %s */\n\n", strlen(fn), "",
- "$Id: bits.c,v 1.3 2000/09/11 14:40:54 art Exp $");
+ "$KTH: bits.c,v 1.6 1998/12/20 15:55:29 assar Exp $");
fprintf(f, "#ifndef %s\n", hb);
fprintf(f, "#define %s\n", hb);
fprintf(f, "\n");
diff --git a/usr.sbin/afs/src/include/stds.h b/usr.sbin/afs/src/include/stds.h
index d1de364fcb0..bb087070fa1 100644
--- a/usr.sbin/afs/src/include/stds.h
+++ b/usr.sbin/afs/src/include/stds.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: stds.h,v 1.2 2000/09/11 14:40:54 art Exp $ */
+/* $KTH: stds.h,v 1.6 2000/10/03 00:34:21 lha Exp $ */
#ifndef __STDS_H
#define __STDS_H 1
diff --git a/usr.sbin/afs/src/lib/Makefile.in b/usr.sbin/afs/src/lib/Makefile.in
index 1b6961836b9..5b625a6bca7 100644
--- a/usr.sbin/afs/src/lib/Makefile.in
+++ b/usr.sbin/afs/src/lib/Makefile.in
@@ -1,11 +1,12 @@
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:54 art Exp $
+# $KTH: Makefile.in,v 1.18 2000/10/25 07:03:04 lha Exp $
srcdir = @srcdir@
+top_builddir = ..
VPATH = @srcdir@
SHELL = /bin/sh
-SUBDIRS = roken sl @editline_dir@ acl cmd
+SUBDIRS = @DIR_roken@ sl @editline_dir@ acl cmd
all:
SUBDIRS='$(SUBDIRS)'; \
@@ -36,6 +37,7 @@ distclean:
SUBDIRS='$(SUBDIRS)'; \
for i in $$SUBDIRS; \
do (cd $$i && $(MAKE) $(MFLAGS) $@) || exit 1; done
+ rm -f Makefile
mostlyclean:
SUBDIRS='$(SUBDIRS)'; \
diff --git a/usr.sbin/afs/src/lib/acl/Makefile.in b/usr.sbin/afs/src/lib/acl/Makefile.in
index bd1a2bb52a6..de30d3db6c7 100644
--- a/usr.sbin/afs/src/lib/acl/Makefile.in
+++ b/usr.sbin/afs/src/lib/acl/Makefile.in
@@ -1,10 +1,11 @@
#
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:54 art Exp $
+# $KTH: Makefile.in,v 1.7 2000/10/10 20:55:55 lha Exp $
#
SHELL = /bin/sh
srcdir = @srcdir@
+top_builddir = ../..
VPATH = @srcdir@
CC = @CC@
@@ -25,6 +26,7 @@ libdir = @libdir@
INCLUDES = -I../../include \
-I$(srcdir)/../../include \
-I$(srcdir) \
+ @INC_roken@ \
-I.
REALCFLAGS = $(INCLUDES) @KRB4_INC_FLAGS@ $(CFLAGS)
diff --git a/usr.sbin/afs/src/lib/acl/acl.h b/usr.sbin/afs/src/lib/acl/acl.h
index 923f8f682b9..cd4fe41f7c6 100644
--- a/usr.sbin/afs/src/lib/acl/acl.h
+++ b/usr.sbin/afs/src/lib/acl/acl.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: acl.h,v 1.3 2002/02/17 19:42:35 millert Exp $ */
+/* $KTH: acl.h,v 1.5 2000/10/03 00:28:33 lha Exp $ */
#ifndef __ACL_H
#define __ACL_H
diff --git a/usr.sbin/afs/src/lib/acl/acl_files.c b/usr.sbin/afs/src/lib/acl/acl_files.c
index 9d35d34bd0d..98a84d2794b 100644
--- a/usr.sbin/afs/src/lib/acl/acl_files.c
+++ b/usr.sbin/afs/src/lib/acl/acl_files.c
@@ -21,7 +21,7 @@ or implied warranty.
#include "config.h"
-RCSID("$Id: acl_files.c,v 1.1 2000/09/11 14:40:55 art Exp $");
+RCSID("$KTH: acl_files.c,v 1.5 1999/09/09 23:46:01 assar Exp $");
#ifdef KERBEROS
diff --git a/usr.sbin/afs/src/lib/bufdir/Makefile.in b/usr.sbin/afs/src/lib/bufdir/Makefile.in
index 89382af0159..6171e8feb01 100644
--- a/usr.sbin/afs/src/lib/bufdir/Makefile.in
+++ b/usr.sbin/afs/src/lib/bufdir/Makefile.in
@@ -1,10 +1,11 @@
#
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:55 art Exp $
+# $KTH: Makefile.in,v 1.5 2000/10/10 20:55:58 lha Exp $
#
SHELL = /bin/sh
srcdir = @srcdir@
+top_builddir = ../..
VPATH = @srcdir@
CC = @CC@
@@ -19,7 +20,7 @@ MKINSTALLDIRS = @top_srcdir@/mkinstalldirs
INCLUDE=-I../../include -I$(srcdir) \
-I../../rxdef \
- -I$(srcdir)/../roken \
+ @INC_roken@ \
@KRB4_INC_FLAGS@ \
-I$(srcdir)/../..
diff --git a/usr.sbin/afs/src/lib/bufdir/afs_dir.h b/usr.sbin/afs/src/lib/bufdir/afs_dir.h
index f10457a8dce..5fd7d1bfb40 100644
--- a/usr.sbin/afs/src/lib/bufdir/afs_dir.h
+++ b/usr.sbin/afs/src/lib/bufdir/afs_dir.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -40,7 +35,7 @@
* The directory structure used by AFS.
*/
-/* $Id: afs_dir.h,v 1.1 2000/09/11 14:40:55 art Exp $ */
+/* $KTH: afs_dir.h,v 1.6 2000/10/02 22:59:28 lha Exp $ */
#ifndef _AFS_DIR_
#define _AFS_DIR_
diff --git a/usr.sbin/afs/src/lib/bufdir/fbuf.c b/usr.sbin/afs/src/lib/bufdir/fbuf.c
index 597df986bfc..a79914db75d 100644
--- a/usr.sbin/afs/src/lib/bufdir/fbuf.c
+++ b/usr.sbin/afs/src/lib/bufdir/fbuf.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -38,7 +33,7 @@
#include <config.h>
-RCSID("$Id: fbuf.c,v 1.1 2000/09/11 14:40:55 art Exp $") ;
+RCSID("$KTH: fbuf.c,v 1.13.2.3 2001/10/24 01:35:22 ahltorp Exp $") ;
#include <stdio.h>
#include <stdlib.h>
@@ -131,12 +126,15 @@ mmap_create (fbuf *f, int fd, size_t len, fbuf_flags flags)
static int
mmap_truncate (fbuf *f, size_t new_len)
{
- int ret;
+ int ret = 0;
if (f->buf != NULL) {
- ret = munmap (f->buf, f->len);
- if (ret < 0)
- return errno;
+ if (msync(f->buf, f->len, MS_ASYNC))
+ ret = errno;
+ if (munmap (f->buf, f->len))
+ ret = errno;
+ if (ret)
+ return ret;
}
ret = ftruncate (f->fd, new_len);
if (ret < 0)
@@ -152,10 +150,11 @@ mmap_truncate (fbuf *f, size_t new_len)
static int
mmap_end (fbuf *f)
{
- int ret;
+ int ret = 0;
- ret = munmap (f->buf, f->len);
- if (ret < 0)
+ if (msync (f->buf, f->len, MS_ASYNC))
+ ret = errno;
+ if (munmap (f->buf, f->len))
ret = errno;
return ret;
}
@@ -181,7 +180,12 @@ mmap_copyrx2fd (struct rx_call *call, int fd, off_t off, size_t len)
r_len = rx_Read (call, buf, len);
if (r_len != len)
ret = conv_to_arla_errno(rx_Error(call));
- munmap (buf, len);
+
+ if (msync (buf, len, MS_ASYNC))
+ ret = errno;
+ if (munmap (buf, len))
+ ret = errno;
+
return ret;
}
@@ -206,7 +210,10 @@ mmap_copyfd2rx (int fd, struct rx_call *call, off_t off, size_t len)
r_write = rx_Write (call, buf, len);
if (r_write != len)
ret = conv_to_arla_errno(rx_Error(call));
- munmap (buf, len);
+
+ if (munmap (buf, len))
+ ret = errno;
+
return ret;
}
diff --git a/usr.sbin/afs/src/lib/bufdir/fbuf.h b/usr.sbin/afs/src/lib/bufdir/fbuf.h
index 88e464f9160..e89caa2955b 100644
--- a/usr.sbin/afs/src/lib/bufdir/fbuf.h
+++ b/usr.sbin/afs/src/lib/bufdir/fbuf.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: fbuf.h,v 1.1 2000/09/11 14:40:55 art Exp $ */
+/* $KTH: fbuf.h,v 1.6 2000/10/02 22:59:38 lha Exp $ */
#ifndef _FBUF_H_
#define _FBUF_H_
diff --git a/usr.sbin/afs/src/lib/bufdir/fdir.c b/usr.sbin/afs/src/lib/bufdir/fdir.c
index 86011d8b215..b64919f13d1 100644
--- a/usr.sbin/afs/src/lib/bufdir/fdir.c
+++ b/usr.sbin/afs/src/lib/bufdir/fdir.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -42,7 +37,7 @@
#include <config.h>
-RCSID("$Id: fdir.c,v 1.1 2000/09/11 14:40:55 art Exp $") ;
+RCSID("$KTH: fdir.c,v 1.9 2000/10/02 22:59:43 lha Exp $") ;
#include <sys/types.h>
#include <sys/errno.h>
diff --git a/usr.sbin/afs/src/lib/bufdir/fdir.h b/usr.sbin/afs/src/lib/bufdir/fdir.h
index 697c156dba1..562f2c9a649 100644
--- a/usr.sbin/afs/src/lib/bufdir/fdir.h
+++ b/usr.sbin/afs/src/lib/bufdir/fdir.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -40,7 +35,7 @@
* Interface to directory handling routines
*/
-/* $Id: fdir.h,v 1.1 2000/09/11 14:40:55 art Exp $ */
+/* $KTH: fdir.h,v 1.5 2000/10/02 22:59:49 lha Exp $ */
#ifndef _FDIR_H_
#define _FDIR_H_
diff --git a/usr.sbin/afs/src/lib/cmd/Makefile.in b/usr.sbin/afs/src/lib/cmd/Makefile.in
index 0ba79f812b8..fc8e89954f0 100644
--- a/usr.sbin/afs/src/lib/cmd/Makefile.in
+++ b/usr.sbin/afs/src/lib/cmd/Makefile.in
@@ -1,10 +1,11 @@
#
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:55 art Exp $
+# $KTH: Makefile.in,v 1.5.2.1 2001/07/14 21:00:15 lha Exp $
#
SHELL = /bin/sh
srcdir = @srcdir@
+top_builddir = ../..
VPATH = @srcdir@
CC = @CC@
@@ -55,7 +56,7 @@ Wall:
make CFLAGS="-g -Wall -Wno-comment -Wmissing-prototypes -Wmissing-declarations -D__USE_FIXED_PROTOTYPES__"
.c.o:
- $(CC) -c $(DEFS) -I../../include -I. -I$(srcdir) $(KRB4_INC_FLAGS) $(CFLAGS) $(CPPFLAGS) $(PICFLAGS) $<
+ $(CC) -c $(DEFS) -I../../include -I. -I$(srcdir) $(KRB4_INC_FLAGS) @INC_roken@ $(CFLAGS) $(CPPFLAGS) $(PICFLAGS) $<
install: all
$(MKINSTALLDIRS) $(DESTDIR)$(includedir)/afs
@@ -109,7 +110,7 @@ $(LIBNAME).a: $(LIB_OBJECTS)
-$(RANLIB) $@
testc: $(testc_OBJECTS) $(cmd_LIB)
- $(CC) $(CFLAGS) -o $@ $(testc_OBJECTS) -L. -lcmd -L../roken -lroken
+ $(CC) $(CFLAGS) -o $@ $(testc_OBJECTS) -L. -lcmd @LIB_roken@ @LIBS@
testc.1: testc
srcdir=$(srcdir) CMD_MANDOC=foo ./testc help > testc.1
diff --git a/usr.sbin/afs/src/lib/cmd/cmd.3 b/usr.sbin/afs/src/lib/cmd/cmd.3
index e38f143032a..b5d455b0f6b 100644
--- a/usr.sbin/afs/src/lib/cmd/cmd.3
+++ b/usr.sbin/afs/src/lib/cmd/cmd.3
@@ -1,4 +1,4 @@
-.\" $Id: cmd.3,v 1.2 2001/06/27 07:43:38 deraadt Exp $
+.\" $KTH: cmd.3,v 1.1 2000/06/01 14:30:58 lha Exp $
.\" Things to fix:
.\" * use better macros for arguments (like .Pa for files)
.\"
diff --git a/usr.sbin/afs/src/lib/cmd/cmd.c b/usr.sbin/afs/src/lib/cmd/cmd.c
index 41da62309d9..deb82eb674c 100644
--- a/usr.sbin/afs/src/lib/cmd/cmd.c
+++ b/usr.sbin/afs/src/lib/cmd/cmd.c
@@ -43,11 +43,12 @@
#include <assert.h>
#include <ctype.h>
#include <err.h>
+#include <roken.h>
#include <cmd.h>
#ifdef RCSID
-RCSID("$Id: cmd.c,v 1.1 2000/09/11 14:40:55 art Exp $");
+RCSID("$KTH: cmd.c,v 1.11 2000/09/29 22:43:02 assar Exp $");
#endif
static struct cmd_syndesc *cmd_cmds = NULL;
@@ -380,7 +381,7 @@ cmd_FreeArgv (char **argv)
*
*/
-#define CMD_IS_CMD(str) (str[0] == '-' && !isdigit(str[1]))
+#define CMD_IS_CMD(str) (str[0] == '-' && !isdigit((unsigned char)str[1]))
/*
*
@@ -815,7 +816,7 @@ cmd_ExtraText (const char *cmd, const char *sectionname,
if (buf[0] == '%') {
break;
}
- while (isspace (*p)) p++;
+ while (isspace ((unsigned char)*p)) p++;
if (*p == '\0')
continue;
printf ("%s%s", p, withcr ? "\n" : "");
diff --git a/usr.sbin/afs/src/lib/cmd/cmd.h b/usr.sbin/afs/src/lib/cmd/cmd.h
index 32d8241104e..340a516465f 100644
--- a/usr.sbin/afs/src/lib/cmd/cmd.h
+++ b/usr.sbin/afs/src/lib/cmd/cmd.h
@@ -32,7 +32,7 @@
*/
/*
- * $Id: cmd.h,v 1.1 2000/09/11 14:40:56 art Exp $
+ * $KTH: cmd.h,v 1.2 2000/06/01 18:37:26 lha Exp $
*/
#ifndef _ARLA_CMD_H
diff --git a/usr.sbin/afs/src/lib/cmd/frame.ctx b/usr.sbin/afs/src/lib/cmd/frame.ctx
index 0e83966123a..8b4c10afce0 100644
--- a/usr.sbin/afs/src/lib/cmd/frame.ctx
+++ b/usr.sbin/afs/src/lib/cmd/frame.ctx
@@ -1,4 +1,4 @@
-# $Id: frame.ctx,v 1.1 2000/09/11 14:40:56 art Exp $
+# $KTH: frame.ctx,v 1.1 2000/06/01 14:31:00 lha Exp $
# This is a comment
%name description
diff --git a/usr.sbin/afs/src/lib/cmd/testc.c b/usr.sbin/afs/src/lib/cmd/testc.c
index bf33fbd51e4..56c345a931d 100644
--- a/usr.sbin/afs/src/lib/cmd/testc.c
+++ b/usr.sbin/afs/src/lib/cmd/testc.c
@@ -1,8 +1,50 @@
+/*
+ * Copyright (c) 2000 Kungliga Tekniska Högskolan
+ * (Royal Institute of Technology, Stockholm, Sweden).
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * 3. Neither the name of the Institute nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <err.h>
#include <cmd.h>
+#include <roken.h>
+
+#ifdef RCSID
+RCSID("$KTH: testc.c,v 1.4 2000/10/16 22:03:35 assar Exp $");
+#endif
static int
MainProc (struct cmd_syndesc *t, void *ptr)
diff --git a/usr.sbin/afs/src/lib/cmd/testc.ctx b/usr.sbin/afs/src/lib/cmd/testc.ctx
index 4dd44f3501b..e9220adeb21 100644
--- a/usr.sbin/afs/src/lib/cmd/testc.ctx
+++ b/usr.sbin/afs/src/lib/cmd/testc.ctx
@@ -1,5 +1,5 @@
#
-# $Id: testc.ctx,v 1.1 2000/09/11 14:40:56 art Exp $
+# $KTH: testc.ctx,v 1.1 2000/06/01 14:30:59 lha Exp $
#
%name description
diff --git a/usr.sbin/afs/src/lib/editline/ChangeLog b/usr.sbin/afs/src/lib/editline/ChangeLog
index 3226f28b630..da507c8616c 100644
--- a/usr.sbin/afs/src/lib/editline/ChangeLog
+++ b/usr.sbin/afs/src/lib/editline/ChangeLog
@@ -1,3 +1,8 @@
+2001-10-23 Magnus Ahltorp <ahltorp@nada.kth.se>
+
+ * editline.c: 1.2->1.3: from heimdal/kth-krb: rename STATUS ->
+ el_STATUS to avoid conflict with STATUS in arpa/nameser.h
+
2000-03-01 Assar Westerlund <assar@sics.se>
* edit_compat.c (readline): be more liberal in what we accept from
diff --git a/usr.sbin/afs/src/lib/editline/Makefile.in b/usr.sbin/afs/src/lib/editline/Makefile.in
index 054469ff6d3..dc4428dd027 100644
--- a/usr.sbin/afs/src/lib/editline/Makefile.in
+++ b/usr.sbin/afs/src/lib/editline/Makefile.in
@@ -1,10 +1,11 @@
#
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:56 art Exp $
+# $KTH: Makefile.in,v 1.8.2.1 2001/05/28 11:35:50 mattiasa Exp $
#
SHELL = /bin/sh
srcdir = @srcdir@
+top_builddir = ../..
VPATH = @srcdir@
CC = @CC@
@@ -42,11 +43,11 @@ Wall:
make CFLAGS="-g -Wall -Wmissing-prototypes -Wmissing-declarations -D__USE_FIXED_PROTOTYPES__"
.c.o:
- $(CC) -c $(CPPFLAGS) $(DEFS) -I../../include -I$(srcdir) -I$(srcdir)/../roken $(CFLAGS) $(PICFLAGS) $<
+ $(CC) -c $(CPPFLAGS) $(DEFS) @INC_roken@ -I../../include -I$(srcdir) $(CFLAGS) $(PICFLAGS) $<
install: all
$(MKINSTALLDIRS) $(DESTDIR)$(libdir); \
- $(INSTALL_DATA) $(LIB) $(DESTDIR)$(libdir)/$(LIB); \
+ $(INSTALL_DATA) $(LIB) $(DESTDIR)$(libdir)/$(LIB);
uninstall:
rm -f $(DESTDIR)$(libdir)/$(LIB)
diff --git a/usr.sbin/afs/src/lib/editline/README b/usr.sbin/afs/src/lib/editline/README
index 829db995b8b..73322ad276c 100644
--- a/usr.sbin/afs/src/lib/editline/README
+++ b/usr.sbin/afs/src/lib/editline/README
@@ -1,4 +1,4 @@
-$Revision: 1.1 $
+$KTH: 1.2 $
This is a line-editing library. It can be linked into almost any
program to provide command-line editing and recall.
diff --git a/usr.sbin/afs/src/lib/editline/complete.c b/usr.sbin/afs/src/lib/editline/complete.c
index 90289198ecc..0226b13c3d5 100644
--- a/usr.sbin/afs/src/lib/editline/complete.c
+++ b/usr.sbin/afs/src/lib/editline/complete.c
@@ -23,7 +23,7 @@
#include <config.h>
#include "editline.h"
-RCSID("$Id: complete.c,v 1.1 2000/09/11 14:40:56 art Exp $");
+RCSID("$KTH: complete.c,v 1.2 2000/03/01 21:40:39 assar Exp $");
/*
** strcmp-like sorting predicate for qsort.
diff --git a/usr.sbin/afs/src/lib/editline/edit_compat.c b/usr.sbin/afs/src/lib/editline/edit_compat.c
index c80c169c15e..2027e5a1652 100644
--- a/usr.sbin/afs/src/lib/editline/edit_compat.c
+++ b/usr.sbin/afs/src/lib/editline/edit_compat.c
@@ -36,7 +36,7 @@
#include <string.h>
#include <histedit.h>
-RCSID("$Id: edit_compat.c,v 1.1 2000/09/11 14:40:56 art Exp $");
+RCSID("$KTH: edit_compat.c,v 1.3 2000/03/01 21:40:39 assar Exp $");
void
rl_reset_terminal(char *p)
diff --git a/usr.sbin/afs/src/lib/editline/editline.3 b/usr.sbin/afs/src/lib/editline/editline.3
index db0da38b933..0ed555cd283 100644
--- a/usr.sbin/afs/src/lib/editline/editline.3
+++ b/usr.sbin/afs/src/lib/editline/editline.3
@@ -1,4 +1,4 @@
-.\" $Revision: 1.1 $
+.\" $KTH: 1.2 $
.TH EDITLINE 3
.SH NAME
editline \- command-line editing library with history
diff --git a/usr.sbin/afs/src/lib/editline/editline.c b/usr.sbin/afs/src/lib/editline/editline.c
index 85d951ae3db..3c0184552e2 100644
--- a/usr.sbin/afs/src/lib/editline/editline.c
+++ b/usr.sbin/afs/src/lib/editline/editline.c
@@ -25,7 +25,7 @@
#include <ctype.h>
#include <errno.h>
-RCSID("$Id: editline.c,v 1.1 2000/09/11 14:40:56 art Exp $");
+RCSID("$KTH: editline.c,v 1.2.10.1 2001/10/23 17:59:45 ahltorp Exp $");
/*
** Manifest constants.
@@ -47,9 +47,9 @@ RCSID("$Id: editline.c,v 1.1 2000/09/11 14:40:56 art Exp $");
/*
** Command status codes.
*/
-typedef enum _STATUS {
+typedef enum _el_STATUS {
CSdone, CSeof, CSmove, CSdispatch, CSstay
-} STATUS;
+} el_STATUS;
/*
** The type of case-changing to perform.
@@ -63,7 +63,7 @@ typedef enum _CASE {
*/
typedef struct _KEYMAP {
unsigned char Key;
- STATUS (*Function)();
+ el_STATUS (*Function)();
} KEYMAP;
/*
@@ -316,7 +316,7 @@ reposition()
}
static void
-left(STATUS Change)
+left(el_STATUS Change)
{
TTYback();
if (Point) {
@@ -332,14 +332,14 @@ left(STATUS Change)
}
static void
-right(STATUS Change)
+right(el_STATUS Change)
{
TTYshow(Line[Point]);
if (Change == CSmove)
Point++;
}
-static STATUS
+static el_STATUS
ring_bell()
{
TTYput('\07');
@@ -347,7 +347,7 @@ ring_bell()
return CSstay;
}
-static STATUS
+static el_STATUS
do_macro(unsigned char c)
{
unsigned char name[4];
@@ -364,8 +364,8 @@ do_macro(unsigned char c)
return CSstay;
}
-static STATUS
-do_forward(STATUS move)
+static el_STATUS
+do_forward(el_STATUS move)
{
int i;
unsigned char *p;
@@ -388,7 +388,7 @@ do_forward(STATUS move)
return CSstay;
}
-static STATUS
+static el_STATUS
do_case(CASE type)
{
int i;
@@ -416,13 +416,13 @@ do_case(CASE type)
return CSstay;
}
-static STATUS
+static el_STATUS
case_down_word()
{
return do_case(TOlower);
}
-static STATUS
+static el_STATUS
case_up_word()
{
return do_case(TOupper);
@@ -463,7 +463,7 @@ clear_line()
Line[0] = '\0';
}
-static STATUS
+static el_STATUS
insert_string(unsigned char *p)
{
size_t len;
@@ -507,7 +507,7 @@ prev_hist()
return H.Pos == 0 ? NULL : H.Lines[--H.Pos];
}
-static STATUS
+static el_STATUS
do_insert_hist(unsigned char *p)
{
if (p == NULL)
@@ -519,7 +519,7 @@ do_insert_hist(unsigned char *p)
return insert_string(p);
}
-static STATUS
+static el_STATUS
do_hist(unsigned char *(*move)())
{
unsigned char *p;
@@ -533,25 +533,25 @@ do_hist(unsigned char *(*move)())
return do_insert_hist(p);
}
-static STATUS
+static el_STATUS
h_next()
{
return do_hist(next_hist);
}
-static STATUS
+static el_STATUS
h_prev()
{
return do_hist(prev_hist);
}
-static STATUS
+static el_STATUS
h_first()
{
return do_insert_hist(H.Lines[H.Pos = 0]);
}
-static STATUS
+static el_STATUS
h_last()
{
return do_insert_hist(H.Lines[H.Pos = H.Size - 1]);
@@ -612,7 +612,7 @@ search_hist(unsigned char *search, unsigned char *(*move)())
return NULL;
}
-static STATUS
+static el_STATUS
h_search()
{
static int Searching;
@@ -638,7 +638,7 @@ h_search()
return do_insert_hist(p);
}
-static STATUS
+static el_STATUS
fd_char()
{
int i;
@@ -669,7 +669,7 @@ save_yank(int begin, int i)
}
}
-static STATUS
+static el_STATUS
delete_string(int count)
{
int i;
@@ -711,7 +711,7 @@ delete_string(int count)
return CSmove;
}
-static STATUS
+static el_STATUS
bk_char()
{
int i;
@@ -726,7 +726,7 @@ bk_char()
return CSstay;
}
-static STATUS
+static el_STATUS
bk_del_char()
{
int i;
@@ -741,7 +741,7 @@ bk_del_char()
return delete_string(i);
}
-static STATUS
+static el_STATUS
redisplay()
{
TTYputs(NEWLINE);
@@ -750,7 +750,7 @@ redisplay()
return CSmove;
}
-static STATUS
+static el_STATUS
kill_line()
{
int i;
@@ -776,10 +776,10 @@ kill_line()
return CSstay;
}
-static STATUS
+static el_STATUS
insert_char(int c)
{
- STATUS s;
+ el_STATUS s;
unsigned char buff[2];
unsigned char *p;
unsigned char *q;
@@ -802,7 +802,7 @@ insert_char(int c)
return s;
}
-static STATUS
+static el_STATUS
meta()
{
unsigned int c;
@@ -838,10 +838,10 @@ meta()
return ring_bell();
}
-static STATUS
+static el_STATUS
emacs(unsigned int c)
{
- STATUS s;
+ el_STATUS s;
KEYMAP *kp;
if (ISMETA(c)) {
@@ -859,7 +859,7 @@ emacs(unsigned int c)
return s;
}
-static STATUS
+static el_STATUS
TTYspecial(unsigned int c)
{
if (ISMETA(c))
@@ -999,7 +999,7 @@ add_history(char *p)
}
-static STATUS
+static el_STATUS
beg_line()
{
if (Point) {
@@ -1009,13 +1009,13 @@ beg_line()
return CSstay;
}
-static STATUS
+static el_STATUS
del_char()
{
return delete_string(Repeat == NO_ARG ? 1 : Repeat);
}
-static STATUS
+static el_STATUS
end_line()
{
if (Point != End) {
@@ -1047,13 +1047,13 @@ find_word()
return new;
}
-static STATUS
+static el_STATUS
c_complete()
{
unsigned char *p;
unsigned char *word;
int unique;
- STATUS s;
+ el_STATUS s;
word = find_word();
p = (unsigned char *)rl_complete((char *)word, &unique);
@@ -1069,7 +1069,7 @@ c_complete()
return ring_bell();
}
-static STATUS
+static el_STATUS
c_possible()
{
unsigned char **av;
@@ -1090,14 +1090,14 @@ c_possible()
return ring_bell();
}
-static STATUS
+static el_STATUS
accept_line()
{
Line[End] = '\0';
return CSdone;
}
-static STATUS
+static el_STATUS
transpose()
{
unsigned char c;
@@ -1115,7 +1115,7 @@ transpose()
return CSstay;
}
-static STATUS
+static el_STATUS
quote()
{
unsigned int c;
@@ -1123,7 +1123,7 @@ quote()
return (c = TTYget()) == EOF ? CSeof : insert_char((int)c);
}
-static STATUS
+static el_STATUS
wipe()
{
int i;
@@ -1141,14 +1141,14 @@ wipe()
return delete_string(Mark - Point);
}
-static STATUS
+static el_STATUS
mk_set()
{
Mark = Point;
return CSstay;
}
-static STATUS
+static el_STATUS
exchange()
{
unsigned int c;
@@ -1164,7 +1164,7 @@ exchange()
return CSstay;
}
-static STATUS
+static el_STATUS
yank()
{
if (Yanked && *Yanked)
@@ -1172,7 +1172,7 @@ yank()
return CSstay;
}
-static STATUS
+static el_STATUS
copy_region()
{
if (Mark > End)
@@ -1186,7 +1186,7 @@ copy_region()
return CSstay;
}
-static STATUS
+static el_STATUS
move_to_char()
{
unsigned int c;
@@ -1203,13 +1203,13 @@ move_to_char()
return CSstay;
}
-static STATUS
+static el_STATUS
fd_word()
{
return do_forward(CSmove);
}
-static STATUS
+static el_STATUS
fd_kill_word()
{
int i;
@@ -1223,7 +1223,7 @@ fd_kill_word()
return CSstay;
}
-static STATUS
+static el_STATUS
bk_word()
{
int i;
@@ -1244,7 +1244,7 @@ bk_word()
return CSstay;
}
-static STATUS
+static el_STATUS
bk_kill_word()
{
bk_word();
@@ -1297,12 +1297,12 @@ argify(unsigned char *line, unsigned char ***avp)
return ac;
}
-static STATUS
+static el_STATUS
last_argument()
{
unsigned char **av;
unsigned char *p;
- STATUS s;
+ el_STATUS s;
int ac;
if (H.Size == 1 || (p = H.Lines[H.Size - 2]) == NULL)
diff --git a/usr.sbin/afs/src/lib/editline/editline.h b/usr.sbin/afs/src/lib/editline/editline.h
index 942c91673c3..cd6c24e30e6 100644
--- a/usr.sbin/afs/src/lib/editline/editline.h
+++ b/usr.sbin/afs/src/lib/editline/editline.h
@@ -1,4 +1,4 @@
-/* $Revision: 1.1 $
+/* $KTH: 1.2 $
**
** Internal header file for editline library.
*/
diff --git a/usr.sbin/afs/src/lib/editline/sysunix.c b/usr.sbin/afs/src/lib/editline/sysunix.c
index c3d4481dc0f..3dd64f09c68 100644
--- a/usr.sbin/afs/src/lib/editline/sysunix.c
+++ b/usr.sbin/afs/src/lib/editline/sysunix.c
@@ -29,7 +29,7 @@
#include <sgtty.h>
#endif
-RCSID("$Id: sysunix.c,v 1.1 2000/09/11 14:40:56 art Exp $");
+RCSID("$KTH: sysunix.c,v 1.2 2000/03/01 21:40:41 assar Exp $");
#ifdef HAVE_TERMIOS_H
diff --git a/usr.sbin/afs/src/lib/editline/testit.c b/usr.sbin/afs/src/lib/editline/testit.c
index 02a93fcc724..a122ff02597 100644
--- a/usr.sbin/afs/src/lib/editline/testit.c
+++ b/usr.sbin/afs/src/lib/editline/testit.c
@@ -1,4 +1,4 @@
-/* $Revision: 1.1 $
+/* $KTH: 1.2 $
**
** A "micro-shell" to test editline library.
** If given any arguments, commands aren't executed.
diff --git a/usr.sbin/afs/src/lib/editline/unix.h b/usr.sbin/afs/src/lib/editline/unix.h
index fe6beedcec2..c2027aa6121 100644
--- a/usr.sbin/afs/src/lib/editline/unix.h
+++ b/usr.sbin/afs/src/lib/editline/unix.h
@@ -1,4 +1,4 @@
-/* $Revision: 1.1 $
+/* $KTH: 1.2 $
**
** Editline system header file for Unix.
*/
diff --git a/usr.sbin/afs/src/lib/ko/Makefile.in b/usr.sbin/afs/src/lib/ko/Makefile.in
index bcfa00d4b2c..8e1d39cfcd4 100644
--- a/usr.sbin/afs/src/lib/ko/Makefile.in
+++ b/usr.sbin/afs/src/lib/ko/Makefile.in
@@ -1,10 +1,11 @@
#
-# $Id: Makefile.in,v 1.1 2000/09/11 14:40:57 art Exp $
+# $KTH: Makefile.in,v 1.30.2.3 2001/10/23 23:54:09 ahltorp Exp $
#
SHELL = /bin/sh
srcdir = @srcdir@
+top_builddir = ../..
VPATH = @srcdir@
CC = @CC@
@@ -16,20 +17,20 @@ INCLUDES = -I. \
-I$(srcdir)/../../include \
-I../.. -I$(srcdir)/../.. \
-I../../rxdef \
+ @INC_roken@ \
@KRB4_INC_FLAGS@
CFLAGS = @CFLAGS@
+LDFLAGS = @LDFLAGS@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
MKINSTALLDIRS = @top_srcdir@/mkinstalldirs
KRB4_LIB_FLAGS = @KRB4_LIB_FLAGS@
-LIBS = -L. -lko \
- -L../../util -lutil \
- -L../roken -lroken \
- $(KRB4_LIB_FLAGS) \
- @LIBS@
+LIBS = -L../../util -lutil \
+ @LIB_roken@ \
+ $(KRB4_LIB_FLAGS) @LIBS@
prefix = @prefix@
exec_prefix = @exec_prefix@
@@ -44,7 +45,7 @@ target_vendor = @target_vendor@
target_cpu = @target_cpu@
#PICFLAGS = @PICFLAGS@
-
+
LIBNAME = $(LIBPREFIX)ko
#LIBEXT = @LIBEXT@
LIBEXT = a
@@ -63,6 +64,7 @@ DEFS = @DEFS@ -DSYSCONFDIR=\"$(sysconfdir)\" \
LIB_SOURCES = koerror.c \
kocell.c \
ports.c \
+ agetarg.c \
part.c \
sysname.c \
vlmisc.c \
@@ -74,6 +76,7 @@ SOURCES = $(LIB_SOURCES) $(gensysname_SRCS)
LIB_OBJECTS = koerror.o \
kocell.o \
ports.o \
+ agetarg.o \
part.o \
sysname.o \
vlmisc.o \
@@ -88,7 +91,7 @@ GENSYSNAMEDEFS= @DEFS@ -DARLAOS=\"$(target_os)\" \
gensysname_SRCS = gensysname.c
-gensysname_OBJS = gensysname.o
+gensysname_OBJS = gensysname.o agetarg.o
kotest_SRCS = kotest.c
@@ -125,10 +128,10 @@ TAGS: $(SOURCES)
gensysname: $(gensysname_OBJS)
- $(CC) -o $@ $(gensysname_OBJS) -L../../util -lutil -L../roken -lroken
+ $(CC) $(LDFLAGS) -o $@ $(gensysname_OBJS) $(LIBS)
kotest: $(kotest_OBJS) $(LIBNAME).a
- $(CC) -o $@ $(kotest_OBJS) $(LIBS)
+ $(CC) $(LDFLAGS) -o $@ $(kotest_OBJS) -L. -lko $(LIBS)
check:
diff --git a/usr.sbin/afs/src/lib/ko/afsconf.c b/usr.sbin/afs/src/lib/ko/afsconf.c
index 779ee8e965e..e233a375f4c 100644
--- a/usr.sbin/afs/src/lib/ko/afsconf.c
+++ b/usr.sbin/afs/src/lib/ko/afsconf.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -39,8 +34,9 @@
#include "ko_locl.h"
#include "cellconfig.h"
#include "ports.h"
+#include <log.h>
-RCSID("$Id: afsconf.c,v 1.1 2000/09/11 14:40:57 art Exp $");
+RCSID("$KTH: afsconf.c,v 1.5 2000/10/03 00:28:53 lha Exp $");
/*
* Currently only handles dir_path == NULL
@@ -50,13 +46,19 @@ struct afsconf_dir *
afsconf_Open(const char *dir_path)
{
struct afsconf_dir *ret;
+ Log_method *method;
assert (dir_path == NULL);
ret = malloc (sizeof (*ret));
if (ret == NULL)
return NULL;
- cell_init (0);
+
+ method = log_open ("afsconf", "/dev/stderr");
+ if (method == NULL)
+ errx (1, "log_open failed");
+ cell_init(0, method);
ports_init ();
+
return ret;
}
diff --git a/usr.sbin/afs/src/lib/ko/auth.c b/usr.sbin/afs/src/lib/ko/auth.c
index 6d1b9454e4a..30b73fd71f8 100644
--- a/usr.sbin/afs/src/lib/ko/auth.c
+++ b/usr.sbin/afs/src/lib/ko/auth.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -39,7 +34,7 @@
#include "ko_locl.h"
#include "auth.h"
-RCSID("$Id: auth.c,v 1.1 2000/09/11 14:40:57 art Exp $");
+RCSID("$KTH: auth.c,v 1.5 2000/10/02 22:42:36 lha Exp $");
#ifdef KERBEROS
diff --git a/usr.sbin/afs/src/lib/ko/auth.h b/usr.sbin/afs/src/lib/ko/auth.h
index 2eeb79cf8c8..2fb443813d3 100644
--- a/usr.sbin/afs/src/lib/ko/auth.h
+++ b/usr.sbin/afs/src/lib/ko/auth.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: auth.h,v 1.1 2000/09/11 14:40:57 art Exp $ */
+/* $KTH: auth.h,v 1.3 2000/10/02 22:42:41 lha Exp $ */
#ifndef __AUTH_H
#define __AUTH_H 1
diff --git a/usr.sbin/afs/src/lib/ko/cellconfig.h b/usr.sbin/afs/src/lib/ko/cellconfig.h
index 52c5089c011..0a50a65f873 100644
--- a/usr.sbin/afs/src/lib/ko/cellconfig.h
+++ b/usr.sbin/afs/src/lib/ko/cellconfig.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: cellconfig.h,v 1.1 2000/09/11 14:40:57 art Exp $ */
+/* $KTH: cellconfig.h,v 1.2 2000/10/02 22:42:46 lha Exp $ */
#ifndef __CELLCONFIG_H
#define __CELLCONFIG_H 1
diff --git a/usr.sbin/afs/src/lib/ko/gensysname.c b/usr.sbin/afs/src/lib/ko/gensysname.c
index 431c4d3129f..0a7bbe1c300 100644
--- a/usr.sbin/afs/src/lib/ko/gensysname.c
+++ b/usr.sbin/afs/src/lib/ko/gensysname.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -37,8 +32,9 @@
*/
#include "ko_locl.h"
+#include <fnmatch.h>
-RCSID("$Id: gensysname.c,v 1.3 2000/09/11 14:40:57 art Exp $");
+RCSID("$KTH: gensysname.c,v 1.35.2.1 2001/09/15 13:33:04 mattiasa Exp $");
typedef int (*test_sysname)(void);
typedef void (*gen_sysname)(char*, size_t, const char*,
@@ -72,6 +68,28 @@ linux_glibc_test(void)
return ret == 0;
}
+static void
+osf_gen_sysname(char *buf,
+ size_t len,
+ const char *cpu,
+ const char *vendor,
+ const char *os)
+{
+
+ int minor, major, nargs;
+ char patch;
+ nargs = sscanf(os, "osf%d.%d%c", &major, &minor, &patch);
+ if(nargs == 3) {
+ snprintf(buf, len, "alpha_osf%d%d%c", major, minor, patch);
+ } else if(nargs == 2) {
+ snprintf(buf, len, "alpha_osf%d%d", major, minor);
+ } else {
+ snprintf(buf, len, "alpha_osf");
+ }
+
+}
+
+
/*
* generic function for generating sysnames for *BSD systems. the
* sysname is written into `buf' (of length `len') based on `cpu,
@@ -123,27 +141,29 @@ bsd_gen_sysname(char *buf,
*/
struct sysname sysnames[] = {
- { "sparc_linux6", "sparc", "*", "linux-gnu*", &linux_glibc_test },
- { "sparc_linux5", "sparc", "*", "linux-gnu*", NULL },
+ { "sparc_linux6", "sparc*", "*", "linux-gnu*", &linux_glibc_test },
+ { "sparc_linux5", "sparc*", "*", "linux-gnu*", NULL },
{ "i386_linux6", "i*86*", "*pc*", "linux-gnu*", &linux_glibc_test },
{ "i386_linux5", "i*86*", "*pc*", "linux-gnu*", NULL },
{ "alpha_linux6", "alpha", "*", "linux-gnu*", &linux_glibc_test },
{ "alpha_linux5", "alpha", "*", "linux-gnu*", NULL },
+ { "alpha_dux40", "alpha*", "*", "osf4.0*", NULL},
{ "ppc_linux22", "powerpc", "*", "linux-gnu*", NULL },
- { "alpha_dux40", "alpha", "*", "osf4.0*", NULL },
- { "sun4x_54", "sparc", "*", "solaris2.4*", NULL },
- { "sun4x_551", "sparc", "*", "solaris2.5.1*", NULL },
- { "sun4x_55", "sparc", "*", "solaris2.5*", NULL },
- { "sun4x_56", "sparc", "*", "solaris2.6*", NULL },
- { "sun4x_57", "sparc", "*", "solaris2.7*", NULL },
+ { "sun4x_54", "sparc*", "*", "solaris2.4*", NULL },
+ { "sun4x_551", "sparc*", "*", "solaris2.5.1*", NULL },
+ { "sun4x_55", "sparc*", "*", "solaris2.5*", NULL },
+ { "sun4x_56", "sparc*", "*", "solaris2.6*", NULL },
+ { "sun4x_57", "sparc*", "*", "solaris2.7*", NULL },
{ "sunx86_54", "i386", "*", "solaris2.4*", NULL },
{ "sunx86_551", "i386", "*", "solaris2.5.1*", NULL },
{ "sunx86_55", "i386", "*", "solaris2.5*", NULL },
{ "sunx86_56", "i386", "*", "solaris2.6*", NULL },
{ "sunx86_57", "i386", "*", "solaris2.7*", NULL },
{ "i386_nt35", "i*86*", "*", "cygwin*", NULL },
-#ifdef HAVE_SYS_UTSNAME_H
+ { "ppc_macosx", "powerpc", "*", "darwin*", NULL },
+ { "", "alpha*", "*", "*osf*", NULL, &osf_gen_sysname },
/* catch-all bsd entry */
+#ifdef HAVE_SYS_UTSNAME_H
{ "", "*", "*", "*bsd*", NULL, &bsd_gen_sysname },
#endif
{NULL}
@@ -160,7 +180,8 @@ printsysname(const char *sysname)
printf("%s\n", sysname);
break;
case OUTPUT_C:
- printf("/* Generated from $Id: gensysname.c,v 1.3 2000/09/11 14:40:57 art Exp $ */\n\n");
+ printf("/* Generated from $KTH: gensysname.c,v 1.35.2.1 2001/09/15 13:33:04 mattiasa Exp $ */\n\n");
+ printf("#ifdef HAVE_CONFIG_H\n#include <config.h>\n#endif\n");
printf("#include <ko.h>\n\n");
printf("const char *arla_getsysname(void) { return \"%s\" ; }\n",
sysname);
@@ -179,21 +200,21 @@ static int allflag = 0;
static int sysnameflag = 0;
static int versionflag = 0;
-struct getargs args[] = {
- {"machine", 'm', arg_flag, &machineflag, "machine output", NULL},
- {"human", 'h', arg_flag, &humanflag, "human", NULL},
- {"ccode", 'c', arg_flag, &ccodeflag, "", NULL},
- {"sysname", 's', arg_flag, &sysnameflag, NULL, NULL},
- {"version", 'v', arg_flag, &versionflag, NULL, NULL},
- {"all", 'a', arg_flag, &allflag, NULL, NULL},
- {"help", 0, arg_flag, &helpflag, NULL, NULL},
- {NULL, 0, arg_end, NULL}
+struct agetargs args[] = {
+ {"machine", 'm', aarg_flag, &machineflag, "machine output", NULL},
+ {"human", 'h', aarg_flag, &humanflag, "human", NULL},
+ {"ccode", 'c', aarg_flag, &ccodeflag, "", NULL},
+ {"sysname", 's', aarg_flag, &sysnameflag, NULL, NULL},
+ {"version", 'v', aarg_flag, &versionflag, NULL, NULL},
+ {"all", 'a', aarg_flag, &allflag, NULL, NULL},
+ {"help", 0, aarg_flag, &helpflag, NULL, NULL},
+ {NULL, 0, aarg_end, NULL}
};
static void
usage(void)
{
- arg_printusage(args, NULL, "[sysname]", 0);
+ aarg_printusage(args, NULL, "[sysname]", 0);
exit(1);
}
@@ -230,7 +251,7 @@ main(int argc, char **argv)
set_progname (argv[0]);
- if (getarg (args, argc, argv, &optind, ARG_GNUSTYLE))
+ if (agetarg (args, argc, argv, &optind, AARG_GNUSTYLE))
usage();
argc -= optind;
@@ -240,7 +261,7 @@ main(int argc, char **argv)
usage();
if (versionflag)
- errx(0, "Version: $Id: gensysname.c,v 1.3 2000/09/11 14:40:57 art Exp $");
+ errx(0, "Version: $KTH: gensysname.c,v 1.35.2.1 2001/09/15 13:33:04 mattiasa Exp $");
if (ccodeflag)
output = OUTPUT_C;
@@ -272,9 +293,9 @@ main(int argc, char **argv)
while (sysname->sysname && !found) {
char sn[64];
- if (!strmatch(sysname->cpu, cpu) &&
- !strmatch(sysname->vendor, vendor) &&
- !strmatch(sysname->os, os) &&
+ if (!fnmatch(sysname->cpu, cpu, 0) &&
+ !fnmatch(sysname->vendor, vendor, 0) &&
+ !fnmatch(sysname->os, os, 0) &&
(sysname->atest == NULL || ((*(sysname->atest))()))) {
found = 1;
diff --git a/usr.sbin/afs/src/lib/ko/ko.h b/usr.sbin/afs/src/lib/ko/ko.h
index 456318a5d20..27bc80bcbd1 100644
--- a/usr.sbin/afs/src/lib/ko/ko.h
+++ b/usr.sbin/afs/src/lib/ko/ko.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
+ * Copyright (c) 1998 - 2001 Kungliga Tekniska Högskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: ko.h,v 1.3 2000/09/11 14:40:57 art Exp $ */
+/* $KTH: ko.h,v 1.27.2.2 2001/05/06 22:40:49 ahltorp Exp $ */
#ifndef __KO_H
#define __KO_H 1
@@ -45,6 +40,7 @@
#include <netinet/in.h>
#include <atypes.h>
#include <bool.h>
+#include <log.h>
typedef int32_t koerr_t;
@@ -66,20 +62,28 @@ const char *arla_getsysname(void);
*/
typedef struct {
- const char *name;
- struct in_addr addr;
+ const char *name;
+ struct in_addr addr;
+ time_t timeout; /* timeout of address */
} cell_db_entry;
+enum { SUID_CELL = 0x1, /* if this is a suid cell */
+ DYNROOT_CELL = 0x2 /* cell should show up in dynroot */
+};
+
+
typedef struct {
int32_t id; /* Cell-ID */
const char *name; /* Domain-style name */
const char *expl; /* Longer name */
unsigned ndbservers; /* # of database servers */
+ unsigned active_hosts; /* # of active db servers */
cell_db_entry *dbservers; /* Database servers */
- enum { NOSUID_CELL, SUID_CELL } suid_cell ; /* if this is a suid cell */
+ unsigned flags; /* Various flags, like SUID_CELL */
+ time_t timeout; /* when this entry expire */
} cell_entry;
-void cell_init (int cellcachesize);
+void cell_init (int cellcachesize, Log_method *log);
const cell_db_entry *cell_dbservers_by_id (int32_t cell, int *);
@@ -92,7 +96,8 @@ cell_entry *cell_get_by_name (const char *cellname);
cell_entry *cell_get_by_id (int32_t cell);
cell_entry *cell_new (const char *name);
cell_entry *cell_new_dynamic (const char *name);
-Bool cell_issuid (cell_entry *c);
+Bool cell_dynroot (const cell_entry *c);
+Bool cell_issuid (const cell_entry *c);
Bool cell_issuid_by_num (int32_t cell);
Bool cell_issuid_by_name (const char *cell);
Bool cell_setsuid_by_num (int32_t cell);
@@ -103,6 +108,8 @@ const char *cell_expand_cell (const char *cell);
unsigned long cell_get_version(void);
Bool cell_is_sanep (int cell);
const char ** cell_thesecells (void);
+void cell_print_cell (cell_entry *c, FILE *out);
+
/*
* misc vl
@@ -114,4 +121,9 @@ const char ** cell_thesecells (void);
void vldb2vldbN (const vldbentry *old, nvldbentry *new);
void volintInfo2xvolintInfo (const volintInfo *old, xvolintInfo *new);
+int volname_canonicalize (char *volname);
+size_t volname_specific (const char *volname, int type,
+ char *buf, size_t buf_sz);
+const char *volname_suffix (int type);
+
#endif /* __KO_H */
diff --git a/usr.sbin/afs/src/lib/ko/ko_locl.h b/usr.sbin/afs/src/lib/ko/ko_locl.h
index a9b098b9018..d6362f56bfa 100644
--- a/usr.sbin/afs/src/lib/ko/ko_locl.h
+++ b/usr.sbin/afs/src/lib/ko/ko_locl.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -38,7 +33,7 @@
/*
* Include file for whole arlad
- * $Id: ko_locl.h,v 1.3 2000/09/11 14:40:57 art Exp $
+ * $KTH: ko_locl.h,v 1.12 2000/10/02 22:43:03 lha Exp $
*/
#ifdef HAVE_CONFIG_H
@@ -75,10 +70,12 @@
#include <err.h>
#include <strings.h>
#include <roken.h>
-#include <getarg.h>
+#include <parse_units.h>
+#include <agetarg.h>
#include <hash.h>
#include <bool.h>
+#include <log.h>
#include "ko.h"
diff --git a/usr.sbin/afs/src/lib/ko/kocell.c b/usr.sbin/afs/src/lib/ko/kocell.c
index 9aafe9d8c4b..c329180a2a5 100644
--- a/usr.sbin/afs/src/lib/ko/kocell.c
+++ b/usr.sbin/afs/src/lib/ko/kocell.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -55,13 +50,14 @@
#include "resolve.h"
-RCSID("$Id: kocell.c,v 1.3 2000/09/11 14:40:57 art Exp $");
+RCSID("$KTH: kocell.c,v 1.47.2.3 2001/07/09 03:27:48 lha Exp $");
#define TRANSARCSYSCONFDIR "/usr/vice/etc"
#define CELLFILENAME "CellServDB"
#define THISCELLFILENAME "ThisCell"
#define SUIDCELLSFILENAME "SuidCells"
#define THESECELLFILENAME "TheseCells"
+#define DYNROOTDBFILENAME "DynRootDB"
#define DEFCELLCACHESIZE 499
/*
@@ -77,7 +73,33 @@ static Hashtab *cellnamehtab, *cellnumhtab;
static char *thiscell = NULL;
static char **thesecells = NULL;
static int numthesecells = 1;
+static int dynrootdb_in_use;
+
+enum { CELL_INVALID_HOST = 1 };
+
+/*
+ * Logging
+ */
+
+#define CDEBERR 0x800
+#define CDEBWARN 0x400
+#define CDEBDNS 0x200
+
+#define CDEBDEFAULT (CDEBWARN|CDEBERR)
+#define cdeball (CDEBWARN|CDEBERR)
+
+static struct units celldebug_units[] = {
+ { "all", cdeball },
+ { "almost-all", cdeball },
+ { "warn", CDEBWARN },
+ { "error", CDEBERR },
+ { "dns", CDEBDNS },
+ { NULL, 0 },
+};
+
+#undef cdeball
+static Log_unit *cell_log = NULL;
/*
*
@@ -85,8 +107,6 @@ static int numthesecells = 1;
static unsigned long celldb_version = 0;
-static int suid_read = 0;
-
static int add_special_dynroot_cell (void);
/*
@@ -155,17 +175,91 @@ newcell (char *line)
}
/*
- * Record this cell in the hashtable
+ *
+ */
+
+static void
+fetch_host (cell_entry *c, cell_db_entry *host)
+{
+ struct dns_reply *r;
+ struct resource_record *rr;
+ struct timeval tv;
+
+ gettimeofday (&tv, NULL);
+
+ r = dns_lookup(host->name, "A");
+ if (r == NULL) {
+ log_log (cell_log, CDEBDNS,
+ "fetch_host: failed to resolve host %s in cell %s",
+ host->name, c->name);
+ host->timeout = CELL_INVALID_HOST;
+ return;
+ }
+ for(rr = r->head; rr;rr=rr->next){
+ if (rr->type == T_A) {
+ if (strcmp(host->name,rr->domain) == 0) {
+ host->addr = *(rr->u.a);
+ host->timeout = tv.tv_sec + rr->ttl;
+ break;
+ }
+ }
+ }
+ dns_free_data(r);
+}
+
+
+/*
+ * Help function for updatehosts
+ */
+
+static int
+host_sort (const void *p1, const void *p2)
+{
+ const cell_db_entry *a = (const cell_db_entry *)p1;
+ const cell_db_entry *b = (const cell_db_entry *)p2;
+ if (a->timeout == CELL_INVALID_HOST)
+ return -1;
+ if (b->timeout == CELL_INVALID_HOST)
+ return 1;
+ return a->addr.s_addr - b->addr.s_addr;
+}
+
+/*
+ * Update the hosts for this cell
*/
static void
-recordcell (cell_entry *c, int dbnum, cell_db_entry *dbservers)
+updatehosts (cell_entry *c, int dbnum, cell_db_entry *dbservers)
{
- c->ndbservers = dbnum;
- c->dbservers = malloc (dbnum * sizeof(cell_db_entry));
- if (c->dbservers == NULL)
- err (1, "malloc %lu", (unsigned long)dbnum * sizeof(cell_db_entry));
- memcpy (c->dbservers, dbservers, dbnum * sizeof (cell_db_entry));
+ cell_db_entry *old_servers = c->dbservers;
+ struct timeval tv;
+ int i;
+
+ gettimeofday(&tv, NULL);
+
+ for (i = 0; i < dbnum; i++) {
+ if (dbservers[i].timeout == CELL_INVALID_HOST
+ || (dbservers[i].timeout && dbservers[i].timeout < tv.tv_sec)) {
+ fetch_host (c, &dbservers[i]);
+ }
+ }
+
+ c->ndbservers = dbnum;
+ c->dbservers = malloc (dbnum * sizeof(cell_db_entry));
+ if (c->dbservers == NULL && dbnum != 0)
+ err (1, "malloc %lu", (unsigned long)dbnum * sizeof(cell_db_entry));
+ memcpy (c->dbservers, dbservers, dbnum * sizeof (cell_db_entry));
+ free (old_servers);
+
+ if (c->ndbservers)
+ qsort (c->dbservers, c->ndbservers, sizeof(c->dbservers[0]),
+ host_sort);
+
+ c->active_hosts = 0;
+ for (i = 0; i < c->ndbservers; i++) {
+ if (c->dbservers[i].timeout != CELL_INVALID_HOST)
+ c->active_hosts++;
+ }
}
/*
@@ -173,17 +267,29 @@ recordcell (cell_entry *c, int dbnum, cell_db_entry *dbservers)
* if c == NULL, a new cell will be allocated
*/
-static void
-try_to_find_cell(const char *cell, cell_entry *c)
+static int
+dns_lookup_cell (const char *cell, cell_entry *c)
{
struct dns_reply *r;
struct resource_record *rr;
int dbnum = 0;
cell_db_entry dbservers[256];
+ int lowest_ttl;
+ int i;
+ struct timeval tv;
+
+ memset (dbservers, 0, sizeof(dbservers));
+ gettimeofday(&tv, NULL);
r = dns_lookup(cell, "AFSDB");
- if (r == NULL)
- return;
+ if (r == NULL) {
+ log_log (cell_log, CDEBDNS,
+ "dns_lookup_cell: failed to resolve cell %s", cell);
+ return 1;
+ }
+ if (c == NULL)
+ c = cell_new_dynamic (cell);
+
for(rr = r->head; rr;rr=rr->next){
if(rr->type == T_AFSDB) {
struct mx_record *mx = (struct mx_record*)rr->u.data;
@@ -191,34 +297,54 @@ try_to_find_cell(const char *cell, cell_entry *c)
if (mx->preference != 1) {
break;
}
- if (c == NULL)
- c = cell_new_dynamic (cell);
if (dbnum >= sizeof (dbservers) / sizeof(*dbservers)) {
break;
}
+ if (lowest_ttl > rr->ttl || lowest_ttl == 0)
+ lowest_ttl = rr->ttl;
dbservers[dbnum].name = strdup (mx->domain);
if (dbservers[dbnum].name == NULL)
err (1, "strdup");
- dbservers[dbnum].addr.s_addr = inet_addr ("0.0.0.0");
- ++dbnum;
- break;
+ dbservers[dbnum].timeout = CELL_INVALID_HOST;
+ dbnum++;
}
}
for(rr = r->head; rr;rr=rr->next){
if (rr->type == T_A) {
- int i;
-
for (i = 0; i < dbnum; i++) {
if (strcmp(dbservers[i].name,rr->domain) == 0) {
dbservers[i].addr = *(rr->u.a);
+ dbservers[i].timeout = tv.tv_sec + rr->ttl;
break;
}
}
}
}
- if (c)
- recordcell (c, dbnum, dbservers);
dns_free_data(r);
+
+ /* catch the hosts that didn't fit in additional rr */
+ c->timeout = lowest_ttl + tv.tv_sec;
+ updatehosts (c, dbnum, dbservers);
+ return 0;
+}
+
+/*
+ * If the cell-information comes from a source that have a time-limit,
+ * make sure the data is uptodate.
+ */
+
+static void
+update_cell (cell_entry *c)
+{
+ struct timeval tv;
+
+ gettimeofday(&tv, NULL);
+
+ if ((c->timeout && c->timeout < tv.tv_sec)
+ || c->ndbservers == 0) {
+ dns_lookup_cell (c->name, c);
+ }
+ updatehosts (c, c->ndbservers, c->dbservers);
}
/*
@@ -233,9 +359,11 @@ cell_get_by_name (const char *cellname)
key.name = cellname;
data = (cell_entry *)hashtabsearch (cellnamehtab, &key);
if (data == NULL) {
- try_to_find_cell (cellname, NULL);
+ dns_lookup_cell (cellname, NULL);
data = (cell_entry *)hashtabsearch (cellnamehtab, &key);
}
+ if (data)
+ update_cell (data);
return data;
}
@@ -246,10 +374,13 @@ cell_get_by_name (const char *cellname)
cell_entry *
cell_get_by_id (int32_t cell)
{
- cell_entry key;
+ cell_entry key, *data;
key.id = cell;
- return (cell_entry *)hashtabsearch (cellnumhtab, &key);
+ data = (cell_entry *)hashtabsearch (cellnumhtab, &key);
+ if (data)
+ update_cell (data);
+ return data;
}
/*
@@ -277,13 +408,15 @@ cell_new (const char *name)
return NULL;
}
assert (cellno != 0);
- c->id = cellno++;
- c->expl = NULL;
- c->ndbservers = 0;
- c->dbservers = NULL;
- c->suid_cell = NOSUID_CELL;
+ c->id = cellno++;
+ c->expl = NULL;
+ c->ndbservers = 0;
+ c->active_hosts = 0;
+ c->dbservers = NULL;
+ c->flags = 0;
hashtabadd (cellnamehtab, c);
hashtabadd (cellnumhtab, c);
+ c->timeout = 0;
celldb_version++;
return c;
}
@@ -301,11 +434,12 @@ cell_new_dynamic (const char *name)
c = cell_new (name);
if (c == NULL)
return NULL;
+ c->expl = "dynamically added cell";
f = fopen (SYSCONFDIR "/" CELLFILENAME, "a");
if (f == NULL)
f = fopen (TRANSARCSYSCONFDIR "/" CELLFILENAME, "a");
if (f == NULL) {
- fprintf (stderr, "Cannot open CellServDB for writing\n");
+ log_log (cell_log, CDEBWARN,"Cannot open CellServDB for writing");
return c;
}
fprintf (f, ">%s #dynamically added cell\n", name);
@@ -327,21 +461,25 @@ readdb (char *line, cell_entry* c, int *dbnum, int maxdbs,
if (*dbnum >= maxdbs) {
return -1;
}
+
+ while (*line && isspace((unsigned char)*line))
+ ++line;
+
if (inet_aton (line, &numaddr) == 0) {
return -1;
}
- while (*line && !isspace(*line) && *line != '#')
+ while (*line && !isspace((unsigned char)*line) && *line != '#')
++line;
hostname = line;
- while (isspace (*hostname) || *hostname == '#')
+ while (isspace ((unsigned char)*hostname) || *hostname == '#')
++hostname;
eh = hostname;
- while (*eh && !isspace(*eh) && *eh != '#')
+ while (*eh && !isspace((unsigned char)*eh) && *eh != '#')
++eh;
*eh = '\0';
@@ -353,6 +491,7 @@ readdb (char *line, cell_entry* c, int *dbnum, int maxdbs,
if (dbservs[*dbnum].name == NULL)
err (1, "strdup");
dbservs[*dbnum].addr = numaddr;
+ dbservs[*dbnum].timeout = 0;
++(*dbnum);
return 0;
}
@@ -370,6 +509,7 @@ readcellservdb (const char *filename)
int lineno = 0;
int dbnum;
cell_db_entry dbservs[256];
+ int i;
f = fopen (filename, "r");
if (f == NULL) {
@@ -378,28 +518,55 @@ readcellservdb (const char *filename)
while (fgets (line, sizeof (line), f)) {
++lineno;
+ i = 0;
line[strlen(line) - 1] = '\0';
- if (*line == '#' || *line == '\0')
+ while (line[0] && isspace((unsigned char)line[i]))
+ i++;
+ if (line[i] == '#' || line[i] == '\0')
continue;
- if (*line == '>') {
+ if (line[i] == '>') {
if (c != NULL)
- recordcell (c, dbnum, dbservs);
- c = newcell (line + 1);
+ updatehosts (c, dbnum, dbservs);
+ c = newcell (&line[i] + 1);
+ memset (dbservs, 0, sizeof(dbservs));
dbnum = 0;
} else {
- if (readdb(line, c, &dbnum, sizeof (dbservs) /
- sizeof(*dbservs),
- dbservs, lineno))
- continue;
+ if (readdb(&line[i], c, &dbnum, sizeof (dbservs) /
+ sizeof(*dbservs),
+ dbservs, lineno))
+ continue;
}
}
if (c != NULL)
- recordcell (c, dbnum, dbservs);
+ updatehosts (c, dbnum, dbservs);
fclose (f);
return 0;
}
/*
+ * Read single line confilefiles in `filename' and send the
+ * to `func'.
+ */
+
+static int
+parse_simple_file (const char *filename, void (*func)(const char *))
+{
+ FILE *f;
+ char line[256];
+
+ f = fopen (filename, "r");
+ if (f == NULL)
+ return 1;
+
+ while ((fgets (line, sizeof(line), f) != NULL)) {
+ line[strlen(line) - 1] = '\0';
+ (*func) (line);
+ }
+ fclose (f);
+ return 0;
+}
+
+/*
* Add expanded `cellname' to Thesecells list, filter out duplicates
*/
@@ -419,24 +586,13 @@ addthesecell (const char *cellname)
}
/*
- * Read cells in these cell's
+ * Read cells in TheseCells
*/
static int
readthesecells (const char *filename)
{
- FILE *f;
- char cell[256];
-
- f = fopen (filename, "r");
- if (f == NULL)
- return 1;
-
- while ((fgets (cell, sizeof cell, f) != NULL)) {
- cell[strlen(cell) - 1] = '\0';
- addthesecell (cell);
- }
- fclose (f);
+ parse_simple_file (filename, addthesecell);
if (numthesecells == 1)
return 1;
return 0;
@@ -457,9 +613,9 @@ readthiscell (const char *filename)
return 1;
if (fgets (cell, sizeof cell, f) == NULL) {
- fprintf(stderr, "Cannot read cellname from %s\n",
+ log_log (cell_log, CDEBERR, "Cannot read cellname from %s\n",
filename);
- return 1;
+ return 1;
}
if (cell[strlen(cell) - 1] == '\n')
cell[strlen(cell) - 1] = '\0';
@@ -474,48 +630,49 @@ readthiscell (const char *filename)
* Read suidcells file and set suidcell flag
*/
+static void
+addsuidcell (const char *cellname)
+{
+ cell_entry *e;
+
+ e = cell_get_by_name (cellname);
+ if (e == NULL) {
+ log_log (cell_log, CDEBWARN,
+ "suidcell: cell %s doesn't exist in the db\n", cellname);
+ } else {
+ e->flags |= SUID_CELL;
+ }
+}
+
static int
readsuidcell (const char *filename)
{
- FILE *f;
- char cell[256];
-
- f = fopen (filename, "r");
- if (f == NULL)
- return 1;
-
- while (fgets (cell, sizeof(cell), f) != NULL) {
- int i;
- cell_entry *e;
-
- i = strlen (cell);
- if (cell[i - 1] == '\n')
- cell[i - 1] = '\0';
-
- e = cell_get_by_name (cell);
- if (e == NULL) {
- fprintf (stderr, "cell %s doesn't exist in the db\n", cell);
- } else {
- e->suid_cell = SUID_CELL;
- }
- }
- fclose (f);
- return 0;
+ return parse_simple_file (filename, addsuidcell);
}
/*
- * initialize suid information, if hasn't already been done
+ *
*/
static void
-cond_readsuidcell (void)
+add_dynroot(const char *cellname)
{
- if (suid_read)
- return;
+ cell_entry *e;
+
+ e = cell_get_by_name (cellname);
+ if (e == NULL) {
+ log_log (cell_log, CDEBWARN,
+ "dynroot: cell %s doesn't exist in the db\n", cellname);
+ } else {
+ e->flags |= DYNROOT_CELL;
+ dynrootdb_in_use = 1;
+ }
+}
- if (readsuidcell (SYSCONFDIR "/" SUIDCELLSFILENAME))
- readsuidcell (TRANSARCSYSCONFDIR "/" SUIDCELLSFILENAME);
- suid_read = 1;
+static int
+readdynrootdb (const char *filename)
+{
+ return parse_simple_file (filename, add_dynroot);
}
/*
@@ -525,17 +682,27 @@ cond_readsuidcell (void)
static int cell_inited = 0;
void
-cell_init (int cellcachesize)
+cell_init (int cellcachesize, Log_method *log)
{
char *env;
int ret;
+ assert (log);
+
if (cell_inited) {
- fprintf(stderr, "cell_init: Already initlized\n");
+ log_log (cell_log, CDEBWARN, "cell_init: Already initlized");
return;
}
cell_inited = 1;
+#ifdef HAVE_RES_INIT
+ res_init();
+#endif
+
+ cell_log = log_unit_init (log, "cell", celldebug_units, CDEBDEFAULT);
+ if (cell_log == NULL)
+ errx (1, "cell_init: log_unit_init failed");
+
if (cellcachesize == 0)
cellcachesize = DEFCELLCACHESIZE;
@@ -559,14 +726,15 @@ cell_init (int cellcachesize)
if (readcellservdb (SYSCONFDIR "/" CELLFILENAME)) {
if (readcellservdb(TRANSARCSYSCONFDIR "/" CELLFILENAME)) {
- fprintf(stderr, "Can't read the CellServDB file," \
- "will use DNS AFSDB entries\n");
+ log_log (cell_log, CDEBWARN,
+ "Can't read the CellServDB file, "
+ "will use DNS AFSDB entries");
}
}
ret = add_special_dynroot_cell();
if (ret)
- fprintf (stderr, "adding dynroot cell failed with %d", ret);
-
+ log_log (cell_log, CDEBWARN, "adding dynroot cell failed with %d", ret);
+
if (readthesecells (SYSCONFDIR "/" THESECELLFILENAME))
readthesecells (TRANSARCSYSCONFDIR "/" THESECELLFILENAME);
if (getenv("HOME") != NULL) {
@@ -577,6 +745,11 @@ cell_init (int cellcachesize)
readthesecells (homedir);
}
addthesecell (thiscell);
+ if (readsuidcell (SYSCONFDIR "/" SUIDCELLSFILENAME))
+ readsuidcell (TRANSARCSYSCONFDIR "/" SUIDCELLSFILENAME);
+ if (readdynrootdb (SYSCONFDIR "/" DYNROOTDBFILENAME))
+ readdynrootdb (TRANSARCSYSCONFDIR "/" DYNROOTDBFILENAME);
+
}
/*
@@ -603,9 +776,11 @@ cell_dbservers_by_id (int32_t id, int *num)
return NULL;
if (data->ndbservers == 0)
- try_to_find_cell (data->name, data);
+ dns_lookup_cell (data->name, data);
+ if (data->ndbservers == 0 || data->active_hosts == 0)
+ return NULL;
- *num = data->ndbservers;
+ *num = data->active_hosts;
return data->dbservers;
}
@@ -622,8 +797,8 @@ cell_findnamedbbyname (const char *cell)
if (data == NULL)
return NULL;
if (data->ndbservers == 0)
- try_to_find_cell (cell, data);
- if (data->ndbservers == 0)
+ dns_lookup_cell (cell, data);
+ if (data->ndbservers == 0 || data->active_hosts == 0)
return NULL;
return data->dbservers[0].name ;
@@ -648,7 +823,7 @@ cell_getcellbyhost(const char *host)
ptr = strchr (host, '.');
if (ptr == NULL)
return NULL;
- return strdup (ptr + 1);
+ return ptr + 1;
}
/*
@@ -703,12 +878,9 @@ cell_setthiscell (const char *cell)
{
cell_entry *data;
- if (!cell_inited)
- cell_init (0);
-
data = cell_get_by_name(cell);
if (data == NULL) {
- fprintf (stderr, "this cell doesn't exist: %s", cell);
+ log_log (cell_log, CDEBWARN, "this cell doesn't exist: %s", cell);
return 1;
}
@@ -721,16 +893,27 @@ cell_setthiscell (const char *cell)
}
/*
- * Return if this is a suid cell
+ * Return if this should be in dynroot
*/
Bool
-cell_issuid (cell_entry *c)
+cell_dynroot (const cell_entry *c)
{
assert (c);
+ if (!dynrootdb_in_use)
+ return TRUE;
+ return (c->flags & DYNROOT_CELL) != 0;
+}
+
+/*
+ * Return if this is a suid cell
+ */
- cond_readsuidcell ();
- return c->suid_cell == SUID_CELL;
+Bool
+cell_issuid (const cell_entry *c)
+{
+ assert (c);
+ return (c->flags & SUID_CELL) != 0;
}
Bool
@@ -738,7 +921,6 @@ cell_issuid_by_num (int32_t cell)
{
cell_entry *c;
- cond_readsuidcell ();
c = cell_get_by_id (cell);
if (c == NULL)
return FALSE;
@@ -751,7 +933,6 @@ cell_issuid_by_name (const char *cell)
{
cell_entry *c;
- cond_readsuidcell ();
c = cell_get_by_name (cell);
if (c == NULL)
return FALSE;
@@ -764,17 +945,56 @@ cell_setsuid_by_num (int32_t cell)
{
cell_entry *c;
- cond_readsuidcell ();
c = cell_get_by_id (cell);
if (c == NULL)
return FALSE;
- c->suid_cell = SUID_CELL;
+ c->flags |= SUID_CELL;
return 0;
}
/*
+ *
+ */
+
+void
+cell_print_cell (cell_entry *c, FILE *out)
+{
+ int i;
+ char timestr[30];
+ struct tm tm;
+ time_t t;
+
+ fprintf (out, "name: %s id: %d type: %s\n",
+ c->name, c->id, c->timeout ? "dynamic" : "static");
+ fprintf (out, "comment: %s\n", c->expl);
+ if (c->timeout) {
+ t = c->timeout;
+ strftime(timestr, sizeof(timestr),
+ "%Y-%m-%d %H:%M:%S", localtime_r(&t, &tm));
+ fprintf (out, "timeout: %s\n", timestr);
+ }
+ fprintf (out, "num hosts: %d active hosts: %d\n",
+ c->ndbservers, c->active_hosts);
+ for (i = 0; i < c->ndbservers; i++) {
+ char *buf;
+ if (c->dbservers[i].timeout == CELL_INVALID_HOST)
+ buf = "invalid";
+ else if (c->dbservers[i].timeout == 0)
+ buf = "no timeout";
+ else {
+ t = c->timeout;
+ strftime(timestr, sizeof(timestr),
+ "%Y-%m-%d %H:%M:%S", localtime_r(&t, &tm));
+ buf = timestr;
+ }
+ fprintf (out, " host: %s %s - %s\n", c->dbservers[i].name,
+ inet_ntoa (c->dbservers[i].addr), buf);
+ }
+}
+
+/*
* Iterate over all entries in the cell-db with `func'
* (that takes the cellname and `arg' as arguments)
*/
@@ -886,7 +1106,7 @@ add_special_dynroot_cell (void)
c->expl = "The special dynroot cell";
c->ndbservers = 0;
c->dbservers = NULL;
- c->suid_cell = NOSUID_CELL;
+ c->flags = 0;
hashtabadd (cellnamehtab, c);
hashtabadd (cellnumhtab, c);
return 0;
diff --git a/usr.sbin/afs/src/lib/ko/koerror.c b/usr.sbin/afs/src/lib/ko/koerror.c
index d8bb3eb9e69..da7eb2e7194 100644
--- a/usr.sbin/afs/src/lib/ko/koerror.c
+++ b/usr.sbin/afs/src/lib/ko/koerror.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -38,7 +33,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
-RCSID("$Id: koerror.c,v 1.3 2000/09/11 14:40:58 art Exp $");
+RCSID("$KTH: koerror.c,v 1.20 2001/01/08 16:48:03 lha Exp $");
#endif
#include <stdio.h>
@@ -51,6 +46,7 @@ RCSID("$Id: koerror.c,v 1.3 2000/09/11 14:40:58 art Exp $");
#include <pts.h>
#include <bos.h>
#include <ubik.h>
+#include <ka.h>
#include <rx/rx.h>
#include <rx/rxgencon.h>
#ifdef KERBEROS
@@ -231,6 +227,52 @@ static struct koerr koerrmsg[] = {
{UBADF, "UBADF"},
{UREINITIALIZE, "UREINITIALIZE"},
+ /* ka errors */
+
+ {KADATABASEINCONSISTENT, "ka - database inconsistent"},
+ {KAEXIST, "ka - already exists"},
+ {KAIO, "ka - io error"},
+ {KACREATEFAIL, "ka - creation failed"},
+ {KANOENT, "ka - no such entry"},
+ {KAEMPTY, "ka - empty"},
+ {KABADNAME, "ka - bad name"},
+ {KABADINDEX, "ka - bad index"},
+ {KANOAUTH, "ka - no authorization"},
+ {KAANSWERTOOLONG, "ka - answer too long"},
+ {KABADREQUEST, "ka - bad request"},
+ {KAOLDINTERFACE, "ka - old interface"},
+ {KABADARGUMENT, "ka - bad argument"},
+ {KABADCMD, "ka - bad command"},
+ {KANOKEYS, "ka - no keys"},
+ {KAREADPW, "ka - error reading password"},
+ {KABADKEY, "ka - bad key"},
+ {KAUBIKINIT, "ka - error initialing ubik"},
+ {KAUBIKCALL, "ka - error in ubik call"},
+ {KABADPROTOCOL, "ka - bad protocol"},
+ {KANOCELLS, "ka - no cells"},
+ {KANOCELL, "ka - no cell"},
+ {KATOOMANYUBIKS, "ka - too many ubiks"},
+ {KATOOMANYKEYS, "ka - too many keys"},
+ {KABADTICKET, "ka - bad ticket"},
+ {KAUNKNOWNKEY, "ka - unknown key"},
+ {KAKEYCACHEINVALID, "ka - key cache invalid"},
+ {KABADSERVER, "ka - bad server"},
+ {KABADUSER, "ka - bad user"},
+ {KABADCPW, "ka - bad change password"},
+ {KABADCREATE, "ka - bad creation"},
+ {KANOTICKET, "ka - no ticket"},
+ {KAASSOCUSER, "ka - associated user"},
+ {KANOTSPECIAL, "ka - not special"},
+ {KACLOCKSKEW, "ka - clock skew"},
+ {KANORECURSE, "ka - no recurse"},
+ {KARXFAIL, "ka - rx failed"},
+ {KANULLPASSWORD, "ka - null password"},
+ {KAINTERNALERROR, "ka - internal error"},
+ {KAPWEXPIRED, "ka - password expired"},
+ {KAREUSED, "ka - password reused"},
+ {KATOOSOON, "ka - password changed too soon"},
+ {KALOCKED, "ka - account locked"},
+
/* Not a known error */
{ 0L, "Unknown error"}
diff --git a/usr.sbin/afs/src/lib/ko/kotest.c b/usr.sbin/afs/src/lib/ko/kotest.c
index db89bb1fec5..b163ea467b8 100644
--- a/usr.sbin/afs/src/lib/ko/kotest.c
+++ b/usr.sbin/afs/src/lib/ko/kotest.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -52,15 +47,21 @@
#include <roken.h>
#include <ko.h>
-RCSID("$Id: kotest.c,v 1.1 2000/09/11 14:40:58 art Exp $");
+RCSID("$KTH: kotest.c,v 1.5 2000/10/02 22:43:19 lha Exp $");
int
main (int argc, char **argv)
{
const char *name;
int ret = 0;
+ Log_method *method;
+
+ set_progname(argv[0]);
- cell_init(0);
+ method = log_open(get_progname(), "/dev/stderr");
+ if (method == NULL)
+ errx (1, "log_open failed");
+ cell_init(0, method);
name = cell_expand_cell ("stacken");
if (strcmp (name, "stacken.kth.se") != 0) {
diff --git a/usr.sbin/afs/src/lib/ko/part.c b/usr.sbin/afs/src/lib/ko/part.c
index b09af1a16d1..c537334174d 100644
--- a/usr.sbin/afs/src/lib/ko/part.c
+++ b/usr.sbin/afs/src/lib/ko/part.c
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -40,7 +35,7 @@
#include "part.h"
-RCSID("$Id: part.c,v 1.1 2000/09/11 14:40:58 art Exp $");
+RCSID("$KTH: part.c,v 1.3 2000/10/02 22:43:24 lha Exp $");
/*
* partition_num2name
diff --git a/usr.sbin/afs/src/lib/ko/part.h b/usr.sbin/afs/src/lib/ko/part.h
index fdee064d939..f472704b3d7 100644
--- a/usr.sbin/afs/src/lib/ko/part.h
+++ b/usr.sbin/afs/src/lib/ko/part.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: part.h,v 1.1 2000/09/11 14:40:58 art Exp $ */
+/* $KTH: part.h,v 1.2 2000/10/02 22:43:29 lha Exp $ */
int partition_num2name(int id, char *str, size_t sz);
int partition_name2num(const char *name);
diff --git a/usr.sbin/afs/src/lib/ko/ports.c b/usr.sbin/afs/src/lib/ko/ports.c
index aeaf2e0441e..3ae37e1c2ee 100644
--- a/usr.sbin/afs/src/lib/ko/ports.c
+++ b/usr.sbin/afs/src/lib/ko/ports.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 1996, 1997, 1998, 1999 Kungliga Tekniska Högskolan
+ * Copyright (c) 1995 - 2001 Kungliga Tekniska Högskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -54,7 +49,7 @@
#include "ports.h"
-RCSID("$Id: ports.c,v 1.3 2000/09/11 14:40:58 art Exp $") ;
+RCSID("$KTH: ports.c,v 1.10.2.1 2001/04/22 01:21:37 lha Exp $") ;
typedef struct {
const char *name; /* Name of the service */
@@ -63,9 +58,16 @@ typedef struct {
int defport; /* Default port */
} Port;
-int afsport, afscallbackport, afsprport, afsvldbport,
- afskaport, afsvolport, afserrorsport, afsbosport,
- afsupdateport, afsrmtsys ;
+int afsport = 0,
+ afscallbackport = 0,
+ afsprport = 0,
+ afsvldbport = 0,
+ afskaport = 0,
+ afsvolport = 0,
+ afserrorsport = 0,
+ afsbosport = 0,
+ afsupdateport = 0,
+ afsrmtsys = 0;
Port ports[] = {
{"afs3-fileserver", "udp", &afsport, 7000},
@@ -97,13 +99,9 @@ ports_init (void)
struct servent *service;
service = getservbyname (ports[i].name, ports[i].proto);
- if (service == NULL) {
-
- fprintf (stderr,
- "Unable to find service %s/%s, using port %d\n",
- ports[i].name, ports[i].proto, ports[i].defport);
+ if (service == NULL)
*(ports[i].port) = ports[i].defport;
- } else
+ else
*(ports[i].port) = ntohs (service->s_port);
}
inited = 1;
diff --git a/usr.sbin/afs/src/lib/ko/ports.h b/usr.sbin/afs/src/lib/ko/ports.h
index b6d36485f12..3b5168c4e68 100644
--- a/usr.sbin/afs/src/lib/ko/ports.h
+++ b/usr.sbin/afs/src/lib/ko/ports.h
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -36,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: ports.h,v 1.3 2000/09/11 14:40:58 art Exp $ */
+/* $KTH: ports.h,v 1.3 2000/10/02 22:43:39 lha Exp $ */
/*
* Port numbers.
diff --git a/usr.sbin/afs/src/lib/ko/vlmisc.c b/usr.sbin/afs/src/lib/ko/vlmisc.c
index 9dab1f6559e..9a35eada45a 100644
--- a/usr.sbin/afs/src/lib/ko/vlmisc.c
+++ b/usr.sbin/afs/src/lib/ko/vlmisc.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999 Kungliga Tekniska Högskolan
+ * Copyright (c) 1999 - 2001 Kungliga Tekniska Högskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -38,7 +33,7 @@
#include "ko_locl.h"
-RCSID("$Id: vlmisc.c,v 1.2 2000/09/11 14:40:58 art Exp $");
+RCSID("$KTH: vlmisc.c,v 1.3.2.1 2001/03/04 04:07:15 lha Exp $");
/*
* Convert old style vldbentry `old` to newer vldbNentry style `new'
@@ -88,3 +83,59 @@ volintInfo2xvolintInfo (const volintInfo *old, xvolintInfo *new)
new->maxquota = old->maxquota;
new->size = old->size;
}
+
+/*
+ * Suffixes for volume names.
+ */
+
+static char *volsuffixes[] = {
+"", /* RWVOL */
+".readonly", /* ROVOL */
+".backup" /* BACKVOL */
+};
+
+/*
+ * canonicalize `volname' and return type of volume
+ */
+
+int
+volname_canonicalize (char *volname)
+{
+ int i;
+ int type = RWVOL;
+
+ for (i = 0; i < MAXTYPES; ++i) {
+ char *p = strrchr (volname, '.');
+ if (p != NULL && strcmp(p, volsuffixes[i]) == 0) {
+ *p = '\0';
+ type = i;
+ break;
+ }
+ }
+ return type;
+}
+
+/*
+ * make specific volume name
+ */
+
+size_t
+volname_specific (const char *volname, int type, char *buf, size_t buf_sz)
+{
+ assert (type >= 0 && type < MAXTYPES);
+
+ return snprintf (buf, buf_sz, "%s%s", volname, volsuffixes[type]);
+}
+
+
+/*
+ * get volume suffix
+ */
+
+const char *
+volname_suffix (int type)
+{
+ assert (type >= 0 && type < MAXTYPES);
+
+ return volsuffixes[type];
+}
diff --git a/usr.sbin/afs/src/lib/sl/ChangeLog b/usr.sbin/afs/src/lib/sl/ChangeLog
index fcef9876408..f26599ddc32 100644
--- a/usr.sbin/afs/src/lib/sl/ChangeLog
+++ b/usr.sbin/afs/src/lib/sl/ChangeLog
@@ -1,3 +1,11 @@
+2000-12-21 Love <lha@stacken.kth.se>
+
+ * Makefile.in: added @LIBS@ to program built localy
+
+2000-09-19 Love <lha@stacken.kth.se>
+
+ * Makefile.in (clean): remove symlinks
+
2000-06-17 Assar Westerlund <assar@sics.se>
* ss.c: look for com_err.h in more places
diff --git a/usr.sbin/afs/src/lib/sl/Makefile.in b/usr.sbin/afs/src/lib/sl/Makefile.in
index 1951d845547..35d4a55b7f6 100644
--- a/usr.sbin/afs/src/lib/sl/Makefile.in
+++ b/usr.sbin/afs/src/lib/sl/Makefile.in
@@ -1,10 +1,11 @@
#
-# $Id: Makefile.in,v 1.1 2000/09/11 14:41:06 art Exp $
+# $KTH: Makefile.in,v 1.14 2000/12/21 12:35:49 lha Exp $
#
SHELL = /bin/sh
srcdir = @srcdir@
+top_builddir = ../..
VPATH = @srcdir@
CC = @CC@
@@ -15,6 +16,8 @@ CFLAGS = @CFLAGS@
YACC = @YACC@
LEX = @LEX@
LN_S = @LN_S@
+LIBS = @LIBS@
+LIB_roken = @LIB_roken@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
@@ -55,7 +58,7 @@ Wall:
make CFLAGS="-g -Wall -Wno-comment -Wmissing-prototypes -Wmissing-declarations -D__USE_FIXED_PROTOTYPES__"
.c.o:
- $(CC) -c $(DEFS) -I../../include -I. -I$(srcdir) $(KRB4_INC_FLAGS) $(CFLAGS) $(CPPFLAGS) $(PICFLAGS) $<
+ $(CC) -c $(DEFS) -I../../include -I. -I$(srcdir) $(KRB4_INC_FLAGS) @INC_roken@ $(CFLAGS) $(CPPFLAGS) $(PICFLAGS) $<
install: all
$(MKINSTALLDIRS) $(DESTDIR)$(includedir)/ss
@@ -77,7 +80,8 @@ TAGS: $(SOURCES)
check:
clean:
- rm -f $(sl_LIB) $(PROGS) lex.c parse.c parse.h *.o *.a
+ rm -f $(sl_LIB) $(PROGS) lex.c parse.c parse.h *.o *.a \
+ strtok_r.c snprintf.c
mostlyclean: clean
@@ -97,7 +101,7 @@ $(OBJECTS): ../../include/config.h
$(mk_cmds_OBJECTS): parse.h
mk_cmds: $(mk_cmds_OBJECTS)
- $(CC) $(CFLAGS) -o $@ $(mk_cmds_OBJECTS) -L../roken -lroken
+ $(CC) $(CFLAGS) -o $@ $(mk_cmds_OBJECTS) $(LIB_roken) $(LIBS)
parse.c: parse.h
parse.h: $(srcdir)/parse.y
@@ -114,4 +118,8 @@ strtok_r.c:
snprintf.c:
test -f snprintf.c || $(LN_S) $(srcdir)/../roken/snprintf.c .
+Makefile: ../../config.status Makefile.in
+ cd ../.. ; CONFIG_FILES=lib/sl/Makefile CONFIG_HEADERS= $(SHELL) config.status
+
+
.PHONY: all Wall install uninstall check clean mostlyclean distclean realclean
diff --git a/usr.sbin/afs/src/lib/sl/lex.l b/usr.sbin/afs/src/lib/sl/lex.l
index 8163d9d718d..540b04eefb5 100644
--- a/usr.sbin/afs/src/lib/sl/lex.l
+++ b/usr.sbin/afs/src/lib/sl/lex.l
@@ -35,14 +35,16 @@
#include "make_cmds.h"
#include "parse.h"
-RCSID("$Id: lex.l,v 1.1 2000/09/11 14:41:07 art Exp $");
+RCSID("$KTH: lex.l,v 1.2.4.1 2001/05/28 23:22:54 mattiasa Exp $");
static unsigned lineno = 1;
static int getstring(void);
#define YY_NO_UNPUT
+#ifndef __osf__
#undef ECHO
+#endif
%}
diff --git a/usr.sbin/afs/src/lib/sl/make_cmds.c b/usr.sbin/afs/src/lib/sl/make_cmds.c
index 3d126ab4df9..57575c6348d 100644
--- a/usr.sbin/afs/src/lib/sl/make_cmds.c
+++ b/usr.sbin/afs/src/lib/sl/make_cmds.c
@@ -34,7 +34,7 @@
#include "make_cmds.h"
#include <getarg.h>
-RCSID("$Id: make_cmds.c,v 1.1 2000/09/11 14:41:07 art Exp $");
+RCSID("$KTH: make_cmds.c,v 1.3 2000/09/01 21:29:38 lha Exp $");
#include <roken.h>
#include <err.h>
@@ -204,7 +204,7 @@ struct getargs args[] = {
static void
usage(int code)
{
- arg_printusage(args, NULL, "command-table", ARG_DEFAULT);
+ arg_printusage(args, sizeof(args)/sizeof(*args), NULL, "command-table");
exit(code);
}
@@ -214,12 +214,12 @@ main(int argc, char **argv)
int optind = 0;
set_progname(argv[0]);
- if(getarg(args, argc, argv, &optind, ARG_DEFAULT))
+ if(getarg(args, sizeof(args)/sizeof(*args), argc, argv, &optind))
usage(1);
if(help_flag)
usage(0);
if(version_flag) {
- printf ("$Id: make_cmds.c,v 1.1 2000/09/11 14:41:07 art Exp $\n");
+ printf ("$KTH: make_cmds.c,v 1.3 2000/09/01 21:29:38 lha Exp $\n");
exit(0);
}
diff --git a/usr.sbin/afs/src/lib/sl/make_cmds.h b/usr.sbin/afs/src/lib/sl/make_cmds.h
index 6b66ddc1370..2537daba4e0 100644
--- a/usr.sbin/afs/src/lib/sl/make_cmds.h
+++ b/usr.sbin/afs/src/lib/sl/make_cmds.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: make_cmds.h,v 1.1 2000/09/11 14:41:07 art Exp $ */
+/* $KTH: make_cmds.h,v 1.2 2000/06/27 02:41:11 assar Exp $ */
#ifndef __MAKE_CMDS_H__
#define __MAKE_CMDS_H__
diff --git a/usr.sbin/afs/src/lib/sl/parse.y b/usr.sbin/afs/src/lib/sl/parse.y
index e41e1a72c37..f8ab2dd2f9c 100644
--- a/usr.sbin/afs/src/lib/sl/parse.y
+++ b/usr.sbin/afs/src/lib/sl/parse.y
@@ -33,7 +33,7 @@
*/
#include "make_cmds.h"
-RCSID("$Id: parse.y,v 1.1 2000/09/11 14:41:07 art Exp $");
+RCSID("$KTH: parse.y,v 1.2 2000/06/27 02:41:12 assar Exp $");
static void yyerror (char *s);
diff --git a/usr.sbin/afs/src/lib/sl/sl.c b/usr.sbin/afs/src/lib/sl/sl.c
index 3612671c936..374d86185be 100644
--- a/usr.sbin/afs/src/lib/sl/sl.c
+++ b/usr.sbin/afs/src/lib/sl/sl.c
@@ -33,7 +33,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
-RCSID("$Id: sl.c,v 1.3 2000/09/11 14:41:07 art Exp $");
+RCSID("$KTH: sl.c,v 1.8 2000/03/07 22:08:48 assar Exp $");
#endif
#include "sl_locl.h"
diff --git a/usr.sbin/afs/src/lib/sl/sl.h b/usr.sbin/afs/src/lib/sl/sl.h
index ca5e56988f8..3132c6c155b 100644
--- a/usr.sbin/afs/src/lib/sl/sl.h
+++ b/usr.sbin/afs/src/lib/sl/sl.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: sl.h,v 1.3 2000/09/11 14:41:07 art Exp $ */
+/* $KTH: sl.h,v 1.4 2000/03/07 22:08:48 assar Exp $ */
#ifndef _SL_H
#define _SL_H
diff --git a/usr.sbin/afs/src/lib/sl/sl_locl.h b/usr.sbin/afs/src/lib/sl/sl_locl.h
index a64c18e1bce..e977b093a14 100644
--- a/usr.sbin/afs/src/lib/sl/sl_locl.h
+++ b/usr.sbin/afs/src/lib/sl/sl_locl.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*/
-/* $Id: sl_locl.h,v 1.2 2000/09/11 14:41:07 art Exp $ */
+/* $KTH: sl_locl.h,v 1.2 2000/03/07 22:08:48 assar Exp $ */
#ifdef HAVE_CONFIG_H
#include <config.h>
diff --git a/usr.sbin/afs/src/lib/sl/ss.c b/usr.sbin/afs/src/lib/sl/ss.c
index 44765c340b5..a4d9e8b8af5 100644
--- a/usr.sbin/afs/src/lib/sl/ss.c
+++ b/usr.sbin/afs/src/lib/sl/ss.c
@@ -39,7 +39,7 @@
#endif
#include "ss.h"
-RCSID("$Id: ss.c,v 1.1 2000/09/11 14:41:07 art Exp $");
+RCSID("$KTH: ss.c,v 1.2 2000/06/17 03:14:59 assar Exp $");
struct ss_subst {
char *name;
diff --git a/usr.sbin/afs/src/lib/sl/ss.h b/usr.sbin/afs/src/lib/sl/ss.h
index fad7317b4e7..ca40190fd16 100644
--- a/usr.sbin/afs/src/lib/sl/ss.h
+++ b/usr.sbin/afs/src/lib/sl/ss.h
@@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*/
-/* $Id: ss.h,v 1.1 2000/09/11 14:41:07 art Exp $ */
+/* $KTH: ss.h,v 1.1 2000/03/07 22:08:49 assar Exp $ */
/* SS compatibility for SL */
diff --git a/usr.sbin/afs/src/lwp/Makefile.in b/usr.sbin/afs/src/lwp/Makefile.in
index e19bb3279e4..a22d9b13ead 100644
--- a/usr.sbin/afs/src/lwp/Makefile.in
+++ b/usr.sbin/afs/src/lwp/Makefile.in
@@ -1,6 +1,7 @@
-# $Id: Makefile.in,v 1.1 2000/09/11 14:41:07 art Exp $
+# $KTH: Makefile.in,v 1.58.2.1 2002/02/01 14:22:21 ahltorp Exp $
srcdir = @srcdir@
+top_builddir = ..
VPATH = @srcdir@
CC = @CC@
@@ -26,7 +27,7 @@ includedir = @includedir@
HOST_CPU = @host_cpu@
HOST_OS = @host_os@
-INCLUDES = -I../include
+INCLUDES = -I../include @INC_roken@
PROCESS_S = process.aix22.S \
process.alpha.S \
@@ -84,11 +85,10 @@ process.o: $(PROCESS_S) make-process.o.sh testprocess.o preempt.o @LWP_O@
$(SHELL) make-process.o.sh
testlwp: testlwp.o liblwp.a
- $(CC) -o testlwp testlwp.o -L. -llwp -L../lib/roken \
- -lroken @PLWP_LIB_FLAGS@
+ $(CC) -o testlwp testlwp.o -L. -llwp @LIB_roken@ @PLWP_LIB_FLAGS@
rw: rw.o liblwp.a
- $(CC) -o rw rw.o -L. -llwp -L../lib/roken \
- -lroken @PLWP_LIB_FLAGS@
+ $(CC) -o rw rw.o -L. -llwp @LIB_roken@ @PLWP_LIB_FLAGS@
+
.c.o:
$(CC) -c $(CPPFLAGS) $(DEFS) $(REALCFLAGS) -I$(srcdir) -I. $<
@@ -106,7 +106,7 @@ testprocess.o: testprocess.c
testlwp.o: testlwp.c
clean:
- rm -f *.o *.a core process.ss process.i $(LIB) make-process.o.sh testprocess $(TEST_PROGRAMS)
+ rm -f *.o *.a core process.ss process.i $(LIB) make-process.o.sh testprocess $(TEST_PROGRAMS) process.S
distclean: clean
rm -f Makefile
diff --git a/usr.sbin/afs/src/lwp/fasttime.c b/usr.sbin/afs/src/lwp/fasttime.c
index 1a1b9ad9c37..128efc69a1b 100644
--- a/usr.sbin/afs/src/lwp/fasttime.c
+++ b/usr.sbin/afs/src/lwp/fasttime.c
@@ -38,7 +38,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
-RCSID("$Id: fasttime.c,v 1.2 2000/09/11 14:41:08 art Exp $");
+RCSID("$KTH: fasttime.c,v 1.8 1999/12/31 05:38:58 assar Exp $");
#endif
#include <stdio.h>
diff --git a/usr.sbin/afs/src/lwp/iomgr.c b/usr.sbin/afs/src/lwp/iomgr.c
index 4d6214248bd..93e55dd2968 100644
--- a/usr.sbin/afs/src/lwp/iomgr.c
+++ b/usr.sbin/afs/src/lwp/iomgr.c
@@ -35,7 +35,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
-RCSID("$Id: iomgr.c,v 1.3 2000/09/11 14:41:08 art Exp $");
+RCSID("$KTH: iomgr.c,v 1.24 2000/02/15 23:53:40 assar Exp $");
#endif
#include <stdio.h>
diff --git a/usr.sbin/afs/src/lwp/lock.c b/usr.sbin/afs/src/lwp/lock.c
index a111d9736e0..9aad0fc53d8 100644
--- a/usr.sbin/afs/src/lwp/lock.c
+++ b/usr.sbin/afs/src/lwp/lock.c
@@ -34,7 +34,7 @@
#ifdef HAVE_CONFIG_H
#include "config.h"
-RCSID("$Id: lock.c,v 1.2 2000/09/11 14:41:08 art Exp $");
+RCSID("$KTH: lock.c,v 1.10 2000/10/20 11:04:47 lha Exp $");
#endif
#include "lwp.h"
#include "lock.h"
@@ -53,6 +53,7 @@ Lock_Init(register struct Lock *lock)
lock -> excl_locked = 0;
lock -> wait_states = 0;
lock -> num_waiting = 0;
+ lock -> thread_index = LWP_INVALIDTHREADID;
}
void
diff --git a/usr.sbin/afs/src/lwp/lock.h b/usr.sbin/afs/src/lwp/lock.h
index d385ce58a6a..3b2e0924638 100644
--- a/usr.sbin/afs/src/lwp/lock.h
+++ b/usr.sbin/afs/src/lwp/lock.h
@@ -22,7 +22,7 @@
****************************************************************************
*/
-/* $Id: lock.h,v 1.2 2000/09/11 14:41:08 art Exp $ */
+/* $KTH: lock.h,v 1.11 2000/10/20 16:18:35 assar Exp $ */
/*******************************************************************\
* *
@@ -51,12 +51,17 @@
#define BEGINMAC do {
#define ENDMAC } while (0)
-/* all locks wait on excl_locked except for READ_LOCK, which waits on readers_reading */
+/*
+ * all locks wait on excl_locked except for READ_LOCK, which waits on
+ * readers_reading
+ */
+
struct Lock {
unsigned char wait_states; /* type of lockers waiting */
- unsigned char excl_locked; /* anyone have boosted, shared or write lock? */
- unsigned char readers_reading; /* # readers actually with read locks */
+ unsigned char excl_locked; /* anyone have boosted, shared or write lock? */
+ unsigned char readers_reading;/* # readers actually with read locks */
unsigned char num_waiting; /* probably need this soon */
+ int thread_index; /* thread that have a exclusive lock */
#ifdef LOCK_TRACE
char *file;
int line;
@@ -93,66 +98,129 @@ void Lock_Init(register struct Lock *);
#define StoreFileLine(lock, f, l) \
(lock)->file = f; \
(lock)->line = l;
+#define GetTraceFile(lock) (lock)->file
+#define GetTraceLine(lock) (lock)->line
#else
#define StoreFileLine(lock, f, l)
+#define GetTraceFile(lock) "no_lock_trace"
+#define GetTraceLine(lock) 0
#endif
+#define LOCK_CHECK_OWNER 1
+
+#ifdef LOCK_CHECK_OWNER
+#define AssertNotLockOwner(lock,owner) do { \
+ if ((lock)->thread_index == (owner)) { \
+ fprintf(stderr, \
+ "AssertNotLockOwner failed on %s:%d with lock %p, " \
+ "owned by %d, locked at (%s:%d)\n", \
+ __FILE__, __LINE__, \
+ (lock), (owner), \
+ GetTraceFile(lock), GetTraceLine(lock)); \
+ abort(); \
+ } \
+} while (0)
+
+#define AssertLockOwner(lock,owner) do { \
+ if ((lock)->thread_index != (owner)) { \
+ fprintf(stderr, \
+ "AssertLockOwner failed on %s:%d with lock %p, " \
+ "should be owned by %d, " \
+ "was owned by %d, locked at (%s:%d)\n", \
+ __FILE__, __LINE__, \
+ (lock), (owner), (lock)->thread_index, \
+ GetTraceFile(lock), GetTraceLine(lock)); \
+ abort(); \
+ } \
+} while (0)
+
+#else /* !LOCK_CHECK_OWNER */
+
+#define AssertNotLockOwner(lock,owner) do { ; } while (0)
+#define AssertLockOwner(lock,owner) do { ; } while (0)
+
+#endif /* LOCK_CHECK_OWNER */
+
+#define AssertExclLocked(lock) \
+ BEGINMAC \
+ AssertLockOwner(lock,LWP_Index()); \
+ ENDMAC \
+
+#define AssertNotExclLocked(lock) \
+ BEGINMAC \
+ AssertLockOwner(lock,LWP_INVALIDTHREADID); \
+ ENDMAC \
+
#define ObtainReadLock(lock) \
BEGINMAC \
DEBUGWRITE("ObtainReadLock: %p at %s:%d starting\n",lock); \
- StoreFileLine(lock, __FILE__, __LINE__) \
+ AssertNotLockOwner(lock,LWP_Index()); \
RealObtainReadLock(lock) \
+ AssertLockOwner(lock,LWP_INVALIDTHREADID); \
+ StoreFileLine(lock, __FILE__, __LINE__) \
DEBUGWRITE("ObtainReadLock: %p at %s:%d got it\n",lock);\
ENDMAC
#define ObtainWriteLock(lock) \
BEGINMAC \
DEBUGWRITE("ObtainWriteLock: %p at %s:%d starting\n",lock); \
- StoreFileLine(lock, __FILE__, __LINE__) \
+ AssertNotLockOwner(lock,LWP_Index()); \
RealObtainWriteLock(lock) \
+ AssertLockOwner(lock,LWP_Index()); \
+ StoreFileLine(lock, __FILE__, __LINE__) \
DEBUGWRITE("ObtainWriteLock: %p at %s:%d got it\n",lock);\
ENDMAC
#define ObtainSharedLock(lock) \
BEGINMAC \
DEBUGWRITE("ObtainSharedLock: %p at %s:%d starting\n",lock); \
- StoreFileLine(lock, __FILE__, __LINE__) \
+ AssertNotLockOwner(lock,LWP_Index()); \
RealObtainSharedLock(lock) \
+ StoreFileLine(lock, __FILE__, __LINE__) \
DEBUGWRITE("ObtainSharedLock: %p at %s:%d got it\n",lock);\
ENDMAC
#define BoostSharedLock(lock) \
BEGINMAC \
DEBUGWRITE("BoostSharedLock: %p at %s:%d starting\n",lock); \
- StoreFileLine(lock, __FILE__, __LINE__) \
+ AssertNotLockOwner(lock,LWP_Index()); \
RealBoostSharedLock(lock) \
+ AssertLockOwner(lock,LWP_Index()); \
+ StoreFileLine(lock, __FILE__, __LINE__) \
DEBUGWRITE("BoostSharedLock: %p at %s:%d got it\n",lock);\
ENDMAC
#define UnBoostSharedLock(lock) \
BEGINMAC \
DEBUGWRITE("UnBoostSharedLock: %p at %s:%d starting\n",lock); \
- StoreFileLine(lock, __FILE__, __LINE__) \
+ AssertNotLockOwner(lock,LWP_Index()); \
RealUnboostSharedLock(lock) \
+ AssertLockOwner(lock,LWP_INVALIDTHREADID); \
+ StoreFileLine(lock, __FILE__, __LINE__) \
DEBUGWRITE("UnBoostSharedLock: %p at %s:%d got it\n",lock);\
ENDMAC
#define ReleaseReadLock(lock) \
BEGINMAC \
DEBUGWRITE("ReleaseReadLock: %p at %s:%d\n",lock);\
+ AssertNotLockOwner(lock,LWP_Index()); \
RealReleaseReadLock(lock) \
+ AssertLockOwner(lock,LWP_INVALIDTHREADID); \
ENDMAC
#define ReleaseWriteLock(lock) \
BEGINMAC \
DEBUGWRITE("ReleaseWriteLock: %p at %s:%d\n",lock);\
+ AssertLockOwner(lock,LWP_Index()); \
RealReleaseWriteLock(lock) \
+ AssertLockOwner(lock,LWP_INVALIDTHREADID); \
ENDMAC
#define ReleaseSharedLock(lock) \
BEGINMAC \
DEBUGWRITE("ReleaseSharedLock: %p at %s:%d\n",lock);\
RealReleaseSharedLock(lock) \
+ AssertLockOwner(lock,LWP_INVALIDTHREADID); \
ENDMAC
#define RealObtainReadLock(lock) \
@@ -162,10 +230,12 @@ void Lock_Init(register struct Lock *);
Lock_Obtain(lock, READ_LOCK);
#define RealObtainWriteLock(lock)\
- if (!(lock)->excl_locked && !(lock)->readers_reading)\
+ if (!(lock)->excl_locked && !(lock)->readers_reading) \
(lock) -> excl_locked = WRITE_LOCK;\
else\
- Lock_Obtain(lock, WRITE_LOCK);
+ Lock_Obtain(lock, WRITE_LOCK); \
+ (lock) -> thread_index = LWP_Index();
+
#define RealObtainSharedLock(lock)\
if (!(lock)->excl_locked && !(lock)->wait_states)\
@@ -177,11 +247,13 @@ void Lock_Init(register struct Lock *);
if (!(lock)->readers_reading)\
(lock)->excl_locked = WRITE_LOCK;\
else\
- Lock_Obtain(lock, BOOSTED_LOCK);
+ Lock_Obtain(lock, BOOSTED_LOCK); \
+ (lock) -> thread_index = LWP_Index();
/* this must only be called with a WRITE or boosted SHARED lock! */
#define RealUnboostSharedLock(lock)\
- (lock)->excl_locked = SHARED_LOCK; \
+ (lock) -> excl_locked = SHARED_LOCK; \
+ (lock) -> thread_index = LWP_INVALIDTHREADID; \
if((lock)->wait_states) \
Lock_ReleaseR(lock);
@@ -191,11 +263,13 @@ void Lock_Init(register struct Lock *);
#define RealReleaseWriteLock(lock)\
+ (lock) -> thread_index = LWP_INVALIDTHREADID; \
(lock)->excl_locked &= ~WRITE_LOCK;\
if ((lock)->wait_states) Lock_ReleaseR(lock);
/* can be used on shared or boosted (write) locks */
#define RealReleaseSharedLock(lock)\
+ (lock) -> thread_index = LWP_INVALIDTHREADID; \
(lock)->excl_locked &= ~(SHARED_LOCK | WRITE_LOCK);\
if ((lock)->wait_states) Lock_ReleaseR(lock);
diff --git a/usr.sbin/afs/src/lwp/lwp_asm.c b/usr.sbin/afs/src/lwp/lwp_asm.c
index b3c27cb6682..5e6f354c90c 100644
--- a/usr.sbin/afs/src/lwp/lwp_asm.c
+++ b/usr.sbin/afs/src/lwp/lwp_asm.c
@@ -37,7 +37,7 @@
#include "lwp.h"
-RCSID("$Id: lwp_asm.c,v 1.1 2000/09/11 14:41:08 art Exp $");
+RCSID("$KTH: lwp_asm.c,v 1.16.2.1 2001/02/21 17:53:17 lha Exp $");
#ifdef AFS_AIX32_ENV
#include <ulimit.h>
@@ -59,12 +59,10 @@ extern char PRE_Block; /* from preempt.c */
#define DESTROYED 4
#define QWAITING 5
#define MAXINT (~(1<<((sizeof(int)*8)-1)))
-#define MINSTACK 44
/*
- * I don't really know if this is the right thing to do, but
- * now I don't get any unalinged memory access on my alpha /lha
+ * Make sure that alignment and saving of data is right
*/
#if defined(__alpha) || defined(__uxpv__) || defined(__sparcv9)
@@ -73,9 +71,18 @@ extern char PRE_Block; /* from preempt.c */
#define REGSIZE 4
#endif
+/*
+ * Space before first stack frame expressed in registers.
+ *
+ * This should maybe be a ABI specific value defined somewhere else.
+ */
#ifdef __hp9000s800
-#define MINFRAME 64
+#define STACK_HEADROOM 16
+#elif defined(__s390__)
+#define STACK_HEADROOM 24
+#else
+#define STACK_HEADROOM 5
#endif
/* Debugging macro */
@@ -266,15 +273,13 @@ LWP_CreateProcess(void (*ep)(), int stacksize, int priority,
char *stackptr;
#endif
-#if defined(AFS_LWP_MINSTACKSIZE)
/*
* on some systems (e.g. hpux), a minimum usable stack size has
* been discovered
*/
- if (stacksize < AFS_LWP_MINSTACKSIZE) {
- stacksize = AFS_LWP_MINSTACKSIZE;
- }
-#endif /* defined(AFS_LWP_MINSTACKSIZE) */
+ if (stacksize < AFS_LWP_MINSTACKSIZE)
+ stacksize = AFS_LWP_MINSTACKSIZE;
+
/* more stack size computations; keep track of for IOMGR */
if (lwp_MaxStackSeen < stacksize)
lwp_MaxStackSeen = stacksize;
@@ -283,19 +288,15 @@ LWP_CreateProcess(void (*ep)(), int stacksize, int priority,
/* Throw away all dead process control blocks */
purge_dead_pcbs();
if (lwp_init) {
- temp = (PROCESS) malloc (sizeof (struct lwp_pcb));
+ temp = (PROCESS) malloc(sizeof(struct lwp_pcb));
if (temp == NULL) {
Set_LWP_RC();
return LWP_ENOMEM;
}
- if (stacksize < MINSTACK)
- stacksize = 1000;
- else
-#ifdef __hp9000s800
- stacksize = 8 * ((stacksize+7) / 8);
-#else
- stacksize = REGSIZE * ((stacksize+REGSIZE-1) / REGSIZE);
-#endif
+
+ /* align stacksize */
+ stacksize = REGSIZE * ((stacksize+REGSIZE-1) / REGSIZE);
+
#ifdef AFS_AIX32_ENV
if (!stackptr) {
/*
@@ -353,10 +354,11 @@ LWP_CreateProcess(void (*ep)(), int stacksize, int priority,
PRE_Block = 1;
lwp_cpptr = temp;
#ifdef __hp9000s800
- savecontext(Create_Process_Part2, &temp2->context, stackptr+MINFRAME);
+ savecontext(Create_Process_Part2, &temp2->context,
+ stackptr + (REGSIZE * STACK_HEADROOM));
#else
savecontext(Create_Process_Part2, &temp2->context,
- stackptr+stacksize-REGSIZE);
+ stackptr + stacksize - (REGSIZE * STACK_HEADROOM));
#endif
/* End of gross hack */
@@ -398,10 +400,11 @@ LWP_DestroyProcess(PROCESS pid)
temp = lwp_cpptr;
#ifdef __hp9000s800
savecontext(Dispatcher, &(temp -> context),
- &(LWPANCHOR.dsptchstack[MINFRAME]));
+ &(LWPANCHOR.dsptchstack[(REGSIZE * STACK_HEADROOM)]));
#else
savecontext(Dispatcher, &(temp -> context),
- &(LWPANCHOR.dsptchstack[(sizeof LWPANCHOR.dsptchstack)-REGSIZE]));
+ &(LWPANCHOR.dsptchstack[(sizeof LWPANCHOR.dsptchstack)
+ - (REGSIZE * STACK_HEADROOM)]));
#endif
}
return LWP_SUCCESS;
@@ -847,7 +850,7 @@ Initialize_PCB(PROCESS temp, int priority, char *stack, int stacksize,
temp -> stacksize = stacksize;
#ifdef __hp9000s800
if (temp -> stack != NULL)
- temp -> stackcheck = *(long *) ((temp -> stack) + stacksize - 4);
+ temp -> stackcheck = *(long *) ((temp -> stack) + stacksize - REGSIZE);
#else
if (temp -> stack != NULL)
temp -> stackcheck = *(long *) (temp -> stack);
diff --git a/usr.sbin/afs/src/lwp/lwp_asm.h b/usr.sbin/afs/src/lwp/lwp_asm.h
index 650505de541..c5c32bfe9cc 100644
--- a/usr.sbin/afs/src/lwp/lwp_asm.h
+++ b/usr.sbin/afs/src/lwp/lwp_asm.h
@@ -28,7 +28,7 @@
* *
\*******************************************************************/
-/* $Id: lwp_asm.h,v 1.1 2000/09/11 14:41:08 art Exp $ */
+/* $KTH: lwp_asm.h,v 1.17 2000/10/20 11:01:49 lha Exp $ */
#ifndef __LWP_INCLUDE_
#define __LWP_INCLUDE_ 1
@@ -141,6 +141,7 @@ extern int lwp_nextindex; /* Next lwp index to assign */
#ifndef LWP_KERNEL
+#define LWP_INVALIDTHREADID (-1)
#define LWP_ActiveProcess (lwp_cpptr+0)
#define LWP_Index() (LWP_ActiveProcess->index)
#define LWP_HighestIndex() (lwp_nextindex - 1)
@@ -174,14 +175,11 @@ extern
#endif
/*
- * Under hpux, any stack size smaller than 16K seems prone to
- * overflow problems.
+ * Under some unices any stack size smaller than 16K seems prone to
+ * overflow problems. Set it to a somewhat larger value.
*/
-#if defined(AFS_HPUX_ENV) || defined(AFS_NEXT_ENV) /*|| defined(AFS_SUN5_ENV)*/
-#define AFS_LWP_MINSTACKSIZE (100 * 1024)
-#else
+
#define AFS_LWP_MINSTACKSIZE (100 * 1024)
-#endif /* defined(AFS_HPUX_ENV) */
/* Action to take on stack overflow. */
#define LWP_SOQUIET 1 /* do nothing */
diff --git a/usr.sbin/afs/src/lwp/lwp_elf.h b/usr.sbin/afs/src/lwp/lwp_elf.h
index 98c40c87225..3dd4e311355 100644
--- a/usr.sbin/afs/src/lwp/lwp_elf.h
+++ b/usr.sbin/afs/src/lwp/lwp_elf.h
@@ -1,12 +1,16 @@
/*
* For common usage of elf platforms
*
- * $Id: lwp_elf.h,v 1.2 2002/02/19 19:39:39 millert Exp $
+ * $KTH: lwp_elf.h,v 1.2 2000/03/03 08:53:43 assar Exp $
*/
#ifndef _C_LABEL
#if !defined(SYSV) && !defined(__ELF__) && !defined(AFS_SUN5_ENV)
+#ifdef __STDC__
#define _C_LABEL(name) _##name
+#else
+#define _C_LABEL(name) _/**/name
+#endif
#else /* SYSV || __ELF__ || AFS_SUN5_ENV */
#define _C_LABEL(name) name
#endif
@@ -14,7 +18,11 @@
#ifndef ENTRY
#if !defined(SYSV) && !defined(__ELF__) && !defined(AFS_SUN5_ENV)
+#ifdef __STDC__
#define ENTRY(name) _##name##:
+#else
+#define ENTRY(name) _/**/name/**/:
+#endif
#else /* SYSV || __ELF__ || AFS_SUN5_ENV */
#define ENTRY(name) name:
#endif
diff --git a/usr.sbin/afs/src/lwp/make-process.o.sh.in b/usr.sbin/afs/src/lwp/make-process.o.sh.in
index 91505b9ab12..d22c95c369e 100644
--- a/usr.sbin/afs/src/lwp/make-process.o.sh.in
+++ b/usr.sbin/afs/src/lwp/make-process.o.sh.in
@@ -3,7 +3,7 @@
# make-process.o.sh
# Try to make process.o various ways.
#
-# $Id: make-process.o.sh.in,v 1.3 2000/09/11 14:41:08 art Exp $
+# $KTH: make-process.o.sh.in,v 1.24.2.1 2001/02/21 17:53:19 lha Exp $
#
srcdir=@srcdir@
@@ -53,6 +53,8 @@ case "$HOST_CPU" in
hppa*) PROCESS_S="process.hpux.S" ;;
powerpc) PROCESS_S="process.ppc.S" ;;
rs6000) PROCESS_S="process.rios.S" ;;
+ vax) PROCESS_S="process.vax.S" ;;
+ s390*) PROCESS_S="process.s390.S" ;;
f301) ;;
*) echo "Unknown host_cpu, good luck" ;;
esac
@@ -68,7 +70,6 @@ case "$HOST_OS" in
*solaris*) OSDEF="-DAFS_SUN5_ENV -D_ASM" USE_AS="yes" ;;
*irix*) OSDEF="-Dsgi -n32 -DHAVE_PIC"; ASDEF="-n32" ;;
*hpux*) OSDEF="-DAFS_HPUX_ENV" ;;
- rhapsody*) OSDEF="-DAFS_BSD_ENV" ;;
aix*) CPUDEF=""; OSDEF="" ;;
uxpv*)
$CPP -P ${srcdir}/process-vpp.s > foo.s
diff --git a/usr.sbin/afs/src/lwp/plwp.c b/usr.sbin/afs/src/lwp/plwp.c
index 5fb06624f89..9ef99f15e08 100644
--- a/usr.sbin/afs/src/lwp/plwp.c
+++ b/usr.sbin/afs/src/lwp/plwp.c
@@ -40,7 +40,7 @@
#include <lwp.h>
-RCSID("$Id: plwp.c,v 1.2 2000/09/11 14:41:08 art Exp $");
+RCSID("$KTH: plwp.c,v 1.9 2000/05/12 08:41:32 lha Exp $");
#ifdef AFS_AIX32_ENV
#include <ulimit.h>
diff --git a/usr.sbin/afs/src/lwp/plwp.h b/usr.sbin/afs/src/lwp/plwp.h
index 27577348dae..ad40a93e72e 100644
--- a/usr.sbin/afs/src/lwp/plwp.h
+++ b/usr.sbin/afs/src/lwp/plwp.h
@@ -1,5 +1,5 @@
/*
- * $Id: plwp.h,v 1.2 2000/09/11 14:41:09 art Exp $
+ * $KTH: plwp.h,v 1.5 2000/10/20 11:01:46 lha Exp $
*/
#ifndef LWP_INCLUDED
@@ -85,6 +85,9 @@ typedef struct lwp_pcb *PROCESS;
#define LWP_SOMESSAGE 3 /* print a message and be quiet */
extern int lwp_overflowAction;
+/* Invalid LWP Index */
+#define LWP_INVALIDTHREADID (-1)
+
/* Tells if stack size counting is enabled. */
extern int lwp_stackUseEnabled;
diff --git a/usr.sbin/afs/src/lwp/preempt.c b/usr.sbin/afs/src/lwp/preempt.c
index 06de28e340a..e712aa154b6 100644
--- a/usr.sbin/afs/src/lwp/preempt.c
+++ b/usr.sbin/afs/src/lwp/preempt.c
@@ -32,7 +32,7 @@
#include <lwp.h>
#include "preempt.h"
-RCSID("$Id: preempt.c,v 1.3 2000/09/11 14:41:09 art Exp $");
+RCSID("$KTH: preempt.c,v 1.7 2000/02/20 04:15:37 assar Exp $");
char PRE_Block = 0; /* used in lwp.c and process.s */
diff --git a/usr.sbin/afs/src/lwp/preempt.h b/usr.sbin/afs/src/lwp/preempt.h
index 1b4f40f9ce8..606130cb50f 100644
--- a/usr.sbin/afs/src/lwp/preempt.h
+++ b/usr.sbin/afs/src/lwp/preempt.h
@@ -1,8 +1,8 @@
-/* $Header: /cvs/OpenBSD/src/usr.sbin/afs/src/lwp/Attic/preempt.h,v 1.3 2000/09/11 14:41:09 art Exp $ */
-/* $Source: /cvs/OpenBSD/src/usr.sbin/afs/src/lwp/Attic/preempt.h,v $ */
+/* $KTH: /afs/stacken.kth.se/src/SourceRepository/arla/lwp/preempt.h,v 1.2 1999/02/01 04:56:31 assar Exp $ */
+/* $KTH: /afs/stacken.kth.se/src/SourceRepository/arla/lwp/preempt.h,v $ */
#if !defined(lint) && !defined(LOCORE) && defined(RCS_HDRS)
-static char *rcsidpreempt = "$Header: /cvs/OpenBSD/src/usr.sbin/afs/src/lwp/Attic/preempt.h,v 1.3 2000/09/11 14:41:09 art Exp $";
+static char *rcsidpreempt = "$KTH: /afs/stacken.kth.se/src/SourceRepository/arla/lwp/preempt.h,v 1.2 1999/02/01 04:56:31 assar Exp $";
#endif
/*
diff --git a/usr.sbin/afs/src/lwp/process-vpp.s b/usr.sbin/afs/src/lwp/process-vpp.s
index 3d8a976bf8a..0227b426cbe 100644
--- a/usr.sbin/afs/src/lwp/process-vpp.s
+++ b/usr.sbin/afs/src/lwp/process-vpp.s
@@ -37,7 +37,7 @@
* SUCH DAMAGE.
*/
-/* $Id: process-vpp.s,v 1.2 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process-vpp.s,v 1.1 1998/10/25 19:41:15 joda Exp $ */
/* LWP context switch for Fujitsu UXP/V */
diff --git a/usr.sbin/afs/src/lwp/process.aix22.S b/usr.sbin/afs/src/lwp/process.aix22.S
index 86923c6c124..fb28724f3b7 100644
--- a/usr.sbin/afs/src/lwp/process.aix22.S
+++ b/usr.sbin/afs/src/lwp/process.aix22.S
@@ -1,4 +1,4 @@
-/* $Id: process.aix22.S,v 1.1 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process.aix22.S,v 1.1 2000/01/02 02:11:15 lha Exp $ */
/*
****************************************************************************
diff --git a/usr.sbin/afs/src/lwp/process.alpha.S b/usr.sbin/afs/src/lwp/process.alpha.S
index 0712a9e30db..34eb4a4cec3 100644
--- a/usr.sbin/afs/src/lwp/process.alpha.S
+++ b/usr.sbin/afs/src/lwp/process.alpha.S
@@ -1,4 +1,4 @@
-/* $Id: process.alpha.S,v 1.1 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process.alpha.S,v 1.1 2000/01/02 02:11:15 lha Exp $ */
/*
****************************************************************************
diff --git a/usr.sbin/afs/src/lwp/process.i386.S b/usr.sbin/afs/src/lwp/process.i386.S
index 15697b7f0a3..4705911688b 100644
--- a/usr.sbin/afs/src/lwp/process.i386.S
+++ b/usr.sbin/afs/src/lwp/process.i386.S
@@ -1,4 +1,4 @@
-/* $Id: process.i386.S,v 1.1 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process.i386.S,v 1.1 2000/01/02 02:11:16 lha Exp $ */
/*
****************************************************************************
diff --git a/usr.sbin/afs/src/lwp/process.ibm032.S b/usr.sbin/afs/src/lwp/process.ibm032.S
index 858bdba0566..2b776e6cf8d 100644
--- a/usr.sbin/afs/src/lwp/process.ibm032.S
+++ b/usr.sbin/afs/src/lwp/process.ibm032.S
@@ -1,4 +1,4 @@
-/* $Id: process.ibm032.S,v 1.1 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process.ibm032.S,v 1.1 2000/01/02 02:11:16 lha Exp $ */
/*
****************************************************************************
diff --git a/usr.sbin/afs/src/lwp/process.m68k.S b/usr.sbin/afs/src/lwp/process.m68k.S
index d5db8e7fc00..23ed94ac56c 100644
--- a/usr.sbin/afs/src/lwp/process.m68k.S
+++ b/usr.sbin/afs/src/lwp/process.m68k.S
@@ -1,4 +1,4 @@
-/* $Id: process.m68k.S,v 1.2 2002/02/19 19:39:39 millert Exp $ */
+/* $KTH: process.m68k.S,v 1.7 2000/08/25 14:49:04 lha Exp $ */
/*
****************************************************************************
@@ -30,7 +30,11 @@
#if !defined(__ELF__) && !defined(sun3)
#define reg(x) x
#else /* __ELF__ || sun3 */
+#ifdef __STDC__
#define reg(x) %##x
+#else
+#define reg(x) %/**/x
+#endif /* __STDC__ */
#endif /* __ELF__ || sun3 */
/*
diff --git a/usr.sbin/afs/src/lwp/process.mips.S b/usr.sbin/afs/src/lwp/process.mips.S
index bb8dd989899..dfaecd67462 100644
--- a/usr.sbin/afs/src/lwp/process.mips.S
+++ b/usr.sbin/afs/src/lwp/process.mips.S
@@ -1,4 +1,4 @@
-/* $Id: process.mips.S,v 1.1 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process.mips.S,v 1.1 2000/01/02 02:11:17 lha Exp $ */
/*
****************************************************************************
diff --git a/usr.sbin/afs/src/lwp/process.ppc.S b/usr.sbin/afs/src/lwp/process.ppc.S
index 20be513e86b..d4ee95d0d01 100644
--- a/usr.sbin/afs/src/lwp/process.ppc.S
+++ b/usr.sbin/afs/src/lwp/process.ppc.S
@@ -1,4 +1,4 @@
-/* $Id: process.ppc.S,v 1.1 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process.ppc.S,v 1.3 2000/10/14 11:12:37 lha Exp $ */
/*
****************************************************************************
@@ -35,6 +35,31 @@
* PowerPC [AIX] ABI needs this extra space.
*/
+/*
+ * PowerPC Stack structure (according to apple)
+ *
+ * -----------------------------------------
+ * | Parameter area
+ * | [...]
+ * -----------------------------------------
+ * | Linkage area: (each row is 4 bytes)
+ * | Saved GPR 2 [saved by calling if imported routine,or pointer-based call]
+ * | Reserved
+ * | Reserved
+ * | Saved LR [ may be set by called ]
+ * | Saved CR [ may be set by called ]
+ * | Saved SP [ saved by calling ]
+ * ----------------------------------------- <-- SP
+ * | Local variables
+ * | [...]
+ * -----------------------------------------
+ * | Parameter area
+ * | [...]
+ * -----------------------------------------
+ * | Linkage area:
+ * | [...]
+ * ----------------------------------------- <-- SP
+ */
/* Mach-O assemblers */
#if !defined(NeXT) && !defined(__APPLE__)
diff --git a/usr.sbin/afs/src/lwp/process.rios.S b/usr.sbin/afs/src/lwp/process.rios.S
index b676f16cd6d..8fc961b1d1f 100644
--- a/usr.sbin/afs/src/lwp/process.rios.S
+++ b/usr.sbin/afs/src/lwp/process.rios.S
@@ -1,4 +1,4 @@
-/* $Id: process.rios.S,v 1.1 2000/09/11 14:41:09 art Exp $ */
+/* $KTH: process.rios.S,v 1.1 2000/01/02 02:11:19 lha Exp $ */
/*
****************************************************************************
diff --git a/usr.sbin/afs/src/lwp/process.sparc.S b/usr.sbin/afs/src/lwp/process.sparc.S
index 95214662eae..fc72b00cb96 100644
--- a/usr.sbin/afs/src/lwp/process.sparc.S
+++ b/usr.sbin/afs/src/lwp/process.sparc.S
@@ -1,4 +1,4 @@
-/* $Id: process.sparc.S,v 1.2 2001/09/11 14:10:09 jason Exp $ */
+/* $KTH: process.sparc.S,v 1.2 2000/06/12 13:38:13 assar Exp $ */
/*
****************************************************************************
@@ -72,7 +72,7 @@ ENTRY(savecontext)
/* The following 3 lines do the equivalent of: _PRE_Block = 1 */
#ifdef AFS_SUN5_ENV
-#if defined(__sparcv9) || defined(__sparcv9__)
+#ifdef __sparcv9
sethi %hh(PRE_Block),%l0
or %l0,%hm(PRE_Block),%l0
sethi %lm(PRE_Block),%g1
@@ -89,7 +89,7 @@ ENTRY(savecontext)
mov 1,%l1
stb %l1, [%l0]
-#if defined(__sparcv9) || defined(__sparcv9__)
+#ifdef __sparcv9
topstack = 0
globals = 8
@@ -323,7 +323,7 @@ L1: call %i0 ! call f()
ENTRY(returnto)
ta ST_FLUSH_WINDOWS ! FLush all other active windows
-#if defined(__sparcv9) || defined(__sparcv9__)
+#ifdef __sparcv9
#ifdef save_allregs
ldx [%i1 + globals + 64 + 0], %f0
@@ -509,7 +509,7 @@ ENTRY(returnto)
/* The following 3 lines are equivalent to: _PRE_Block = 0 */
#ifdef AFS_SUN5_ENV
-#if defined(__sparcv9) || defined(__sparcv9__)
+#ifdef __sparcv9
sethi %hh(_C_LABEL(PRE_Block)),%l0
or %l0,%hm(_C_LABEL(PRE_Block)),%l0
sethi %lm(_C_LABEL(PRE_Block)),%g1
diff --git a/usr.sbin/afs/src/lwp/process.vax.S b/usr.sbin/afs/src/lwp/process.vax.S
index 00fd59d2d16..e3745704141 100644
--- a/usr.sbin/afs/src/lwp/process.vax.S
+++ b/usr.sbin/afs/src/lwp/process.vax.S
@@ -1,4 +1,4 @@
-/* $Id: process.vax.S,v 1.1 2000/09/11 14:41:10 art Exp $ */
+/* $KTH: process.vax.S,v 1.1 2000/01/02 02:11:20 lha Exp $ */
/*
****************************************************************************
diff --git a/usr.sbin/afs/src/lwp/q.c b/usr.sbin/afs/src/lwp/q.c
index 76de25fa08c..8336eac02fa 100644
--- a/usr.sbin/afs/src/lwp/q.c
+++ b/usr.sbin/afs/src/lwp/q.c
@@ -11,7 +11,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
-RCSID("$Id: q.c,v 1.2 2000/09/11 14:41:10 art Exp $") ;
+RCSID("$KTH: q.c,v 1.8 1999/12/31 05:39:49 assar Exp $") ;
#endif
#include <stdio.h>
diff --git a/usr.sbin/afs/src/lwp/q.h b/usr.sbin/afs/src/lwp/q.h
index 748da0786ee..ad89f49c4ed 100644
--- a/usr.sbin/afs/src/lwp/q.h
+++ b/usr.sbin/afs/src/lwp/q.h
@@ -1,4 +1,4 @@
-/* $Id: q.h,v 1.2 2000/09/11 14:41:10 art Exp $ */
+/* $KTH: q.h,v 1.2 1998/02/12 01:03:32 assar Exp $ */
void lwp_insque(void *, void *);
void lwp_remque(void *);
diff --git a/usr.sbin/afs/src/lwp/testlwp.c b/usr.sbin/afs/src/lwp/testlwp.c
index 14cf825165b..81e4c400414 100644
--- a/usr.sbin/afs/src/lwp/testlwp.c
+++ b/usr.sbin/afs/src/lwp/testlwp.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998 Kungliga Tekniska Högskolan
+ * Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -14,12 +14,7 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the Kungliga Tekniska
- * Högskolan and its contributors.
- *
- * 4. Neither the name of the Institute nor the names of its contributors
+ * 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
@@ -43,7 +38,7 @@
* multiple commands on the command line to run several tests at the
* same time.
*
- * $Id: testlwp.c,v 1.4 2001/07/09 07:04:59 deraadt Exp $
+ * $KTH: testlwp.c,v 1.8 2000/10/20 17:10:38 lha Exp $
*
*/
@@ -52,6 +47,7 @@
#include <string.h>
#include <err.h>
#include <lwp.h>
+#include <lock.h>
#include <unistd.h>
#include <sys/time.h>
@@ -164,6 +160,9 @@ SelectConsumer(void *foo)
while(1) {
FD_ZERO(&readset);
+ if (pipa[0] >= FD_SETSIZE)
+ errx (1, "fd too large");
+
FD_SET(pipa[0], &readset);
IOMGR_Select(pipa[0] + 1, &readset, NULL, NULL, NULL);
len = read(pipa[0], str, 199);
@@ -198,7 +197,7 @@ startSelectPC (char *progname)
if (dup2(pipa[1], 0) == -1)
err(1, "dup2");
close(pipa[1]);
- execl(progname, "testlwp", "selectproducer", (char *)NULL);
+ execl(progname, "testlwp", "selectproducer", NULL);
err(1, "execl");
default:
break;
@@ -245,6 +244,35 @@ yaEndlessLoop(void)
errx (1, "Cannot create enterprise process");
}
+static void
+deadlock_write (void)
+{
+ struct Lock lock;
+
+ Lock_Init (&lock);
+ ObtainWriteLock(&lock);
+ ObtainWriteLock(&lock);
+}
+
+static void
+deadlock_read (void)
+{
+ struct Lock lock;
+
+ Lock_Init (&lock);
+ ObtainWriteLock(&lock);
+ ObtainReadLock(&lock);
+}
+
+static void
+deadlock_read2 (void)
+{
+ struct Lock lock;
+
+ Lock_Init (&lock);
+ ObtainReadLock(&lock);
+ ObtainWriteLock(&lock);
+}
/*
* Usage
@@ -260,6 +288,9 @@ usage(char *progname)
"selectconsumer\tSelect consumer\n"
"selectproducer\t(special case, just print a string on stdout repeatally)\n"
"cancel\t\tTest iomgr cancel\n"
+ "deadlock-write\tdeadlockdetection\n"
+ "deadlock-read\tdeadlockdetection\n"
+ "deadlock-read2\tdeadlockdetection\n"
"version\t\tPrint version\n");
printf("Use several of these tests together to test their interopability\n");
@@ -297,9 +328,15 @@ int main(int argc, char **argv)
startSelectPC (progname);
} else if (strcasecmp("cancel", argv[1]) == 0) {
yaEndlessLoop();
+ } else if (strcasecmp("deadlock-write", argv[1]) == 0) {
+ deadlock_write();
+ } else if (strcasecmp("deadlock-read", argv[1]) == 0) {
+ deadlock_read();
+ } else if (strcasecmp("deadlock-read2", argv[1]) == 0) {
+ deadlock_read2();
} else if (strcasecmp("version", argv[1]) == 0) {
printf("Version: "
- "$Id: testlwp.c,v 1.4 2001/07/09 07:04:59 deraadt Exp $\n");
+ "$KTH: testlwp.c,v 1.8 2000/10/20 17:10:38 lha Exp $\n");
exit (0);
} else {
printf("unknown command %s\n", argv[1]);
diff --git a/usr.sbin/afs/src/lwp/testprocess.c b/usr.sbin/afs/src/lwp/testprocess.c
index 8c00e09fd12..932e7fd58b6 100644
--- a/usr.sbin/afs/src/lwp/testprocess.c
+++ b/usr.sbin/afs/src/lwp/testprocess.c
@@ -8,7 +8,7 @@
*
* Todo: really a test-program
*
- * $Id: testprocess.c,v 1.2 2000/09/11 14:41:10 art Exp $
+ * $KTH: testprocess.c,v 1.1 1998/06/09 11:52:53 lha Exp $
*/
int savecontext();
diff --git a/usr.sbin/afs/src/lwp/timer.c b/usr.sbin/afs/src/lwp/timer.c
index 1923a6912be..d739d6fd34c 100644
--- a/usr.sbin/afs/src/lwp/timer.c
+++ b/usr.sbin/afs/src/lwp/timer.c
@@ -31,7 +31,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
-RCSID("$Id: timer.c,v 1.2 2000/09/11 14:41:10 art Exp $");
+RCSID("$KTH: timer.c,v 1.5 1998/05/18 05:44:41 art Exp $");
#endif
#include <sys/time.h>