Index: openafs/src/JAVA/libjafs/ACL.c diff -c openafs/src/JAVA/libjafs/ACL.c:1.3.2.1 openafs/src/JAVA/libjafs/ACL.c:1.3.2.2 *** openafs/src/JAVA/libjafs/ACL.c:1.3.2.1 Fri Oct 14 22:14:11 2005 --- openafs/src/JAVA/libjafs/ACL.c Tue May 26 20:13:58 2009 *************** *** 21,26 **** --- 21,27 ---- #include #include + #include #include "Internal.h" #include "org_openafs_jafs_ACL.h" *************** *** 54,60 **** #define ACL_LEN 1024 ! extern int errno; /** * Returns a formatted string representing the ACL for the specified path. --- 55,66 ---- #define ACL_LEN 1024 ! #ifndef ERROR_H ! #define ERROR_H ! #endif ! ! extern int error_intr; ! extern int error_nomem; /** * Returns a formatted string representing the ACL for the specified path. Index: openafs/src/JAVA/libjafs/FileInputStream.c diff -c openafs/src/JAVA/libjafs/FileInputStream.c:1.3.2.1 openafs/src/JAVA/libjafs/FileInputStream.c:1.3.2.2 *** openafs/src/JAVA/libjafs/FileInputStream.c:1.3.2.1 Fri Oct 14 22:14:11 2005 --- openafs/src/JAVA/libjafs/FileInputStream.c Tue May 26 20:13:58 2009 *************** *** 21,26 **** --- 21,27 ---- #include "Internal.h" #include "org_openafs_jafs_FileInputStream.h" + #include #include *************** *** 28,35 **** #include "dmalloc.h" #endif - extern int errno; - /** * Be carefull with the memory management: * --- 29,34 ---- Index: openafs/src/JAVA/libjafs/Internal.c diff -c openafs/src/JAVA/libjafs/Internal.c:1.4.2.1 openafs/src/JAVA/libjafs/Internal.c:1.4.2.2 *** openafs/src/JAVA/libjafs/Internal.c:1.4.2.1 Fri Oct 14 22:14:12 2005 --- openafs/src/JAVA/libjafs/Internal.c Tue May 26 20:13:58 2009 *************** *** 20,32 **** */ #include "Internal.h" #ifdef DMALLOC #include "dmalloc.h" #endif - extern int errno; - #ifndef LIBJUAFS // user class and fields // jclass userCls = 0; --- 20,31 ---- */ #include "Internal.h" + #include #ifdef DMALLOC #include "dmalloc.h" #endif #ifndef LIBJUAFS // user class and fields // jclass userCls = 0; Index: openafs/src/afs/Makefile.in diff -c openafs/src/afs/Makefile.in:1.19.2.2 openafs/src/afs/Makefile.in:1.19.2.3 *** openafs/src/afs/Makefile.in:1.19.2.2 Mon Oct 15 13:33:49 2007 --- openafs/src/afs/Makefile.in Wed Jun 3 14:26:00 2009 *************** *** 14,23 **** depinstall: ${TOP_INCDIR}/afs/afs.h ${TOP_INCDIR}/afs/osi_inode.h ${TOP_INCDIR}/afs/afs_stats.h \ ${TOP_INCDIR}/afs/exporter.h ${TOP_INCDIR}/afs/nfsclient.h afszcm.cat AFS_component_version_number.c ${TOP_INCDIR}/afs/unified_afs.h ${TOP_INCDIR}/afs/sysctl.h - case ${SYS_NAME} in \ - pmax_ul43 | pmax_ul43a) \ - ${INSTALL} longc_procs.h ${TOP_INCDIR}/afs ;; \ - esac afs_trace.h afs_trace.msf: afs_trace.et ${COMPILE_ET} -v 2 -p ${srcdir} afs_trace.et --- 14,19 ---- *************** *** 45,54 **** install: ${DESTDIR}${includedir}/afs/afs.h ${DESTDIR}${includedir}/afs/osi_inode.h ${DESTDIR}${includedir}/afs/afs_stats.h ${DESTDIR}${includedir}/afs/exporter.h ${DESTDIR}${includedir}/afs/nfsclient.h ${DESTDIR}${includedir}/afs/unified_afs.h ${DESTDIR}${includedir}/afs/sysctl.h case ${SYS_NAME} in \ - pmax_ul43 | pmax_ul43a) \ - ${INSTALL} longc_procs.h ${DESTDIR}${includedir}/afs ;; \ - esac - case ${SYS_NAME} in \ *linux* ) \ ${INSTALL} ${MKAFS_OSTYPE}/osi_vfs.h ${DESTDIR}${includedir}/afs || true ;;\ * ) \ --- 41,46 ---- *************** *** 133,142 **** dest: ${DEST}/include/afs/afs.h ${DEST}/include/afs/osi_inode.h ${DEST}/include/afs/afs_stats.h ${DEST}/include/afs/exporter.h ${DEST}/include/afs/nfsclient.h ${DEST}/include/afs/unified_afs.h ${DEST}/include/afs/sysctl.h case ${SYS_NAME} in \ - pmax_ul43 | pmax_ul43a) \ - ${INSTALL} longc_procs.h ${DEST}/include/afs ;; \ - esac - case ${SYS_NAME} in \ i386_fbsd* ) \ echo skipping afszcm.cat install for ${SYS_NAME} ;; \ * ) \ --- 125,130 ---- Index: openafs/src/afs/afs.h diff -c openafs/src/afs/afs.h:1.48.2.36 openafs/src/afs/afs.h:1.48.2.37 *** openafs/src/afs/afs.h:1.48.2.36 Mon Jan 19 14:27:19 2009 --- openafs/src/afs/afs.h Mon Apr 27 14:33:01 2009 *************** *** 687,694 **** --- 687,696 ---- struct lock__bsd__ rwlock; #endif #ifdef AFS_XBSD_ENV + #if !defined(AFS_DFBSD_ENV) struct lock rwlock; #endif + #endif afs_int32 parentVnode; /* Parent dir, if a file. */ afs_int32 parentUnique; struct VenusFid *mvid; /* Either parent dir (if root) or root (if mt pt) */ Index: openafs/src/afs/afs_buffer.c diff -c openafs/src/afs/afs_buffer.c:1.16.2.7 openafs/src/afs/afs_buffer.c:1.16.2.8 *** openafs/src/afs/afs_buffer.c:1.16.2.7 Thu Dec 13 14:18:47 2007 --- openafs/src/afs/afs_buffer.c Wed Jun 3 16:36:32 2009 *************** *** 11,17 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_buffer.c,v 1.16.2.7 2007/12/13 19:18:47 shadow Exp $"); #include "afs/sysincludes.h" #include "afsincludes.h" --- 11,17 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_buffer.c,v 1.16.2.8 2009/06/03 20:36:32 shadow Exp $"); #include "afs/sysincludes.h" #include "afsincludes.h" *************** *** 43,49 **** #include "afs/dir.h" #include "afs/afs_stats.h" - #include "afs/longc_procs.h" #include "afs/afs.h" #ifndef BUF_TIME_MAX --- 43,48 ---- Index: openafs/src/afs/afs_call.c diff -c openafs/src/afs/afs_call.c:1.74.2.33 openafs/src/afs/afs_call.c:1.74.2.34 *** openafs/src/afs/afs_call.c:1.74.2.33 Thu Mar 19 22:32:59 2009 --- openafs/src/afs/afs_call.c Sat May 30 13:56:39 2009 *************** *** 11,17 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_call.c,v 1.74.2.33 2009/03/20 02:32:59 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ --- 11,17 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_call.c,v 1.74.2.34 2009/05/30 17:56:39 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ *************** *** 1163,1168 **** --- 1163,1170 ---- } else if (parm == AFSOP_SET_RXPCK) { rx_extraPackets = parm2; afscall_set_rxpck_received = 1; + } else if (parm == AFSOP_SET_RXMAXMTU) { + rx_MyMaxSendSize = rx_maxReceiveSizeUser = rx_maxReceiveSize = parm2; } else code = EINVAL; Index: openafs/src/afs/afs_osi.c diff -c openafs/src/afs/afs_osi.c:1.48.2.20 openafs/src/afs/afs_osi.c:1.48.2.21 *** openafs/src/afs/afs_osi.c:1.48.2.20 Fri Mar 27 11:55:43 2009 --- openafs/src/afs/afs_osi.c Tue May 12 09:03:47 2009 *************** *** 1,5 **** /* ! * Copyright 2000, International Business Machines Corporation and others. * All Rights Reserved. * * This software has been released under the terms of the IBM Public --- 1,5 ---- /* ! * Copyrigh 2000, International Business Machines Corporation and others. * All Rights Reserved. * * This software has been released under the terms of the IBM Public *************** *** 11,17 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_osi.c,v 1.48.2.20 2009/03/27 15:55:43 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ --- 11,17 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_osi.c,v 1.48.2.21 2009/05/12 13:03:47 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ *************** *** 485,490 **** --- 485,492 ---- osi_linux_free(x); #elif defined(AFS_FBSD_ENV) osi_fbsd_free(x); + #elif defined(AFS_OBSD44_ENV) + osi_obsd_Free(x, asize); #else AFS_KFREE((struct osimem *)x, asize); #endif Index: openafs/src/afs/afs_pioctl.c diff -c openafs/src/afs/afs_pioctl.c:1.81.2.34 openafs/src/afs/afs_pioctl.c:1.81.2.36 *** openafs/src/afs/afs_pioctl.c:1.81.2.34 Mon Jan 19 13:09:34 2009 --- openafs/src/afs/afs_pioctl.c Wed Jun 3 11:14:38 2009 *************** *** 11,17 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_pioctl.c,v 1.81.2.34 2009/01/19 18:09:34 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #ifdef AFS_OBSD_ENV --- 11,17 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_pioctl.c,v 1.81.2.36 2009/06/03 15:14:38 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #ifdef AFS_OBSD_ENV *************** *** 91,96 **** --- 91,97 ---- DECL_PIOCTL(PFsCmd); DECL_PIOCTL(PCallBackAddr); DECL_PIOCTL(PNewUuid); + DECL_PIOCTL(PGetPAG); /* * A macro that says whether we're going to need HandleClientContext(). * This is currently used only by the nfs translator. *************** *** 198,203 **** --- 199,208 ---- PBogus, /* 0 */ PBogus, /* 0 */ PNewUuid, /* 9 -- generate new uuid */ + PBogus, /* 0 */ + PBogus, /* 0 */ + PBogus, /* 0 */ + PGetPAG, /* 13 -- get PAG value */ }; #define PSetClientContext 99 /* Special pioctl to setup caller's creds */ *************** *** 646,653 **** #ifdef AFS_LINUX22_ENV return -code; #else ! setuerror(code); ! return; #endif #endif #endif --- 651,657 ---- #ifdef AFS_LINUX22_ENV return -code; #else ! return (setuerror(code), code); #endif #endif #endif *************** *** 3865,3870 **** --- 3869,3901 ---- return 0; } + /*! + * VIOC_GETPAG (13) - Get PAG value + * + * \ingroup pioctl + * + * \param[in] ain not in use + * \param[out] aout PAG value or NOPAG + * + * \retval E2BIG Error not enough space to copy out value + * + * \post get PAG value for the caller's cred + */ + DECL_PIOCTL(PGetPAG) + { + afs_int32 pag; + + if (*aoutSize < sizeof(afs_int32)) { + return E2BIG; + } + + pag = PagInCred(*acred); + + memcpy(aout, (char *)&pag, sizeof(afs_int32)); + *aoutSize = sizeof(afs_int32); + return 0; + } + DECL_PIOCTL(PCallBackAddr) { #ifndef UKERNEL *************** *** 3962,3964 **** --- 3993,3996 ---- #endif /* UKERNEL */ return 0; } + Index: openafs/src/afs/afs_prototypes.h diff -c openafs/src/afs/afs_prototypes.h:1.53.2.27 openafs/src/afs/afs_prototypes.h:1.53.2.28 *** openafs/src/afs/afs_prototypes.h:1.53.2.27 Fri Mar 20 11:05:09 2009 --- openafs/src/afs/afs_prototypes.h Mon Apr 27 14:33:01 2009 *************** *** 610,619 **** /* ARCH/osi_groups.c */ ! #ifdef AFS_XBSD_ENV extern int setpag(struct proc *proc, struct ucred **cred, afs_uint32 pagvalue, afs_uint32 * newpag, int change_parent); #endif /* ARCH/osi_vm.c */ --- 610,621 ---- /* ARCH/osi_groups.c */ ! #if defined AFS_XBSD_ENV ! #if !defined(AFS_DFBSD_ENV) || !defined(UKERNEL) extern int setpag(struct proc *proc, struct ucred **cred, afs_uint32 pagvalue, afs_uint32 * newpag, int change_parent); #endif + #endif /* ARCH/osi_vm.c */ Index: openafs/src/afs/afs_segments.c diff -c openafs/src/afs/afs_segments.c:1.16.2.6 openafs/src/afs/afs_segments.c:1.16.2.7 *** openafs/src/afs/afs_segments.c:1.16.2.6 Tue Dec 4 16:12:16 2007 --- openafs/src/afs/afs_segments.c Tue May 12 12:42:48 2009 *************** *** 14,20 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_segments.c,v 1.16.2.6 2007/12/04 21:12:16 shadow Exp $"); #include "afs/sysincludes.h" /*Standard vendor system headers */ #include "afsincludes.h" /*AFS-based standard headers */ --- 14,20 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/afs_segments.c,v 1.16.2.7 2009/05/12 16:42:48 shadow Exp $"); #include "afs/sysincludes.h" /*Standard vendor system headers */ #include "afsincludes.h" /*AFS-based standard headers */ *************** *** 195,201 **** * on the memcache case since that's we adjust the file's size * and finish flushing partial vm pages. */ ! if (cacheDiskType != AFS_FCACHE_TYPE_MEM) #endif /* !AFS_AIX32_ENV && !AFS_SGI65_ENV */ { /* If we're not diskless, reading a file may stress the VM --- 195,201 ---- * on the memcache case since that's we adjust the file's size * and finish flushing partial vm pages. */ ! if ((cacheDiskType != AFS_FCACHE_TYPE_MEM) || (sync & AFS_LASTSTORE)) #endif /* !AFS_AIX32_ENV && !AFS_SGI65_ENV */ { /* If we're not diskless, reading a file may stress the VM Index: openafs/src/afs/longc_procs.h diff -c openafs/src/afs/longc_procs.h:1.3.2.1 openafs/src/afs/longc_procs.h:removed *** openafs/src/afs/longc_procs.h:1.3.2.1 Sun Apr 3 14:15:36 2005 --- openafs/src/afs/longc_procs.h Thu Jun 11 11:13:07 2009 *************** *** 1,321 **** - /* - * Copyright 2000, International Business Machines Corporation and others. - * All Rights Reserved. - * - * This software has been released under the terms of the IBM Public - * License. For details, see the LICENSE file in the top-level source - * directory or online at http://www.openafs.org/dl/license10.html - */ - - #ifndef _longc_procs_h_ - #define _longc_procs_h_ 1 - - #if !defined(LONGCALL_DEFS) && defined(KERNEL) && defined(DYNEL) && defined(AFS_DECOSF_ENV) - - #define LONGCALL_DEFS - - struct afs_longcall_procs { - int (*LC_xdr_u_short) (); - int (*LC_xdr_short) (); - int (*LC_xdr_opaque) (); - int (*LC_xdr_array) (); - int (*LC_xdr_bytes) (); - int (*LC_xdr_u_long) (); - int (*LC_xdr_string) (); - int (*LC_xdr_long) (); - int (*LC_xdr_int) (); - int (*LC_xdr_u_int) (); - int (*LC_ioctl) (); - int (*LC_copyout) (); - int (*LC_biodone) (); - int (*LC_ureadc) (); - int (*LC_strcmp) (); - int (*LC_uiomove) (); - int (*LC_uprintf) (); - int (*LC_strncpy) (); - int (*LC_flock) (); - int (*LC_setgroups) (); - struct ucred *(*LC_crcopy) (); - struct ucred *(*LC_crget) (); - int (*LC_crhold) (); - int (*LC_ip_stripoptions) (); - int (*LC_in_cksum) (); - struct mbuf *(*LC_m_pullup) (); - int (*LC_resettodr) (); - int (*LC_untimeout) (); - int (*LC_timeout) (); - int (*LC_mpurge) (); - int (*LC_xrele) (); - int (*LC_m_free) (); - int (*LC_m_clalloc) (); - int (*LC_splimp) (); - int (*LC_m_freem) (); - int (*LC_soclose) (); - int (*LC_sobind) (); - struct mbuf *(*LC_m_get) (); - int (*LC_socreate) (); - int (*LC_soreserve) (); - #if defined(AFS_DECOSF_ENV) - int (*LC_getf) (); - #else /* AFS_DECOSF_ENV */ - struct file *(*LC_getf) (); - #endif - int (*LC_splx) (); - int (*LC_microtime) (); - int (*LC_splnet) (); - int (*LC_bcmp) (); - #ifdef XDR_CHAR_IN_KERNEL - int (*LC_xdr_char) (); - #endif - int (*LC_iunlock) (); - int (*LC_ilock) (); - int (*LC_iput) (); - struct inode *(*LC_ialloc) (); - int (*LC_vno_close) (); - int (*LC_kmem_alloc) (); - int (*LC_kmem_free) (); - - int (*LC_m_cpytoc) (); - - int (*LC_ufs_brelse) (); - int (*LC_lookupname) (); - int (*LC_vn_rele) (); - int (*LC_vn_rdwr) (); - int (*LC_mapout) (); - struct mount *(*LC_getmp) (); - struct inode *(*LC_iget) (); - struct mbuf *(*LC_m_more) (); - int (*LC__spl1) (); - int (*LC_rdwri) (); - struct file *(*LC_falloc) (); - int (*LC_rmfree) (); - int (*LC_mapin) (); - long (*LC_rmalloc) (); - struct pte *(*LC_vtopte) (); - int (*LC_vattr_null) (); - int (*LC_strlen) (); - int (*LC_bcopy) (); - int (*LC_brelse) (); - struct buf *(*LC_geteblk) (); - int (*LC_panic) (); - int (*LC_strcpy) (); - int (*LC_printf) (); - int (*LC_copyinstr) (); - int (*LC_copyin) (); - int (*LC_sleep) (); - int (*LC_wakeup) (); - int (*LC_bzero) (); - int (*LC_suser) (); - int (*LC_crfree) (); - #if 0 - int (*LC_igetinode) (); - #endif - #if defined(AFS_DECOSF_ENV) - void (*LC_assert_wait) (); - int (*LC_closef) (); - int (*LC_fake_inode_init) (); - int (*LC_getnewvnode) (); - struct mount *(*LC_getvfs) (); - int (*LC_idrop) (); - int (*LC_insmntque) (); - int (*LC_ioctl_base) (); - caddr_t(*LC_kalloc) (); - void (*LC_kfree) (); - void (*LC_lock_done) (); - struct mbuf *(*LC_m_getclr) (); - struct mbuf *(*LC_m_retry) (); - struct mbuf *(*LC_m_retryhdr) (); - int (*LC_mpsleep) (); - int (*LC_namei) (); - unsigned int (*LC_nuxi_32) (); - unsigned short (*LC_nuxi_16) (); - int (*LC_setgroups_base) (); - int (*LC_substitute_real_creds) (); - int (*LC_swap_ipl) (); - void (*LC_thread_block) (); - /* XXX - should be kern_return_t */ - int (*LC_u_vp_create) (); - int (*LC_ubc_bufalloc) (); - int (*LC_ubc_flush_sync) (); - int (*LC_ubc_invalidate) (); - int (*LC_ubc_lookup) (); - int (*LC_ubc_page_dirty) (); - int (*LC_ubc_page_release) (); - int (*LC_ubc_sync_iodone) (); - int (*LC_vgetm) (); - int (*LC_vgone) (); - int (*LC_vn_close) (); - /* - int (*LC_vn_ioctl) (); - int (*LC_vn_read) (); - int (*LC_vn_select) (); - int (*LC_vn_write) (); - */ - void (*LC_vrele) (); - int (*LC_xdr_char) (); - #endif /* AFS_DECOSF_ENV */ - }; - extern struct afs_longcall_procs afs_longcall_procs; - - #ifndef LONGCALL_NO_MACROS - - #if defined(AFS_DECOSF_ENV) - #undef kmem_alloc - #undef kmem_free - #endif /* AFS_DECOSF_ENV */ - - #define crfree (*afs_longcall_procs.LC_crfree) - #define suser (*afs_longcall_procs.LC_suser) - #define bzero (*afs_longcall_procs.LC_bzero) - #define wakeup (*afs_longcall_procs.LC_wakeup) - #if !defined(AFS_DECOSF_ENV) - #define sleep (*afs_longcall_procs.LC_sleep) - #endif - #define copyin (*afs_longcall_procs.LC_copyin) - #define copyinstr (*afs_longcall_procs.LC_copyinstr) - #define printf (*afs_longcall_procs.LC_printf) - #define panic (*afs_longcall_procs.LC_panic) - #define geteblk (*afs_longcall_procs.LC_geteblk) - #define brelse (*afs_longcall_procs.LC_brelse) - #define bcopy (*afs_longcall_procs.LC_bcopy) - #define strlen (*afs_longcall_procs.LC_strlen) - #define vtopte (*afs_longcall_procs.LC_vtopte) - #define rmalloc (*afs_longcall_procs.LC_rmalloc) - - #define mapin (*afs_longcall_procs.LC_mapin) - #define strcpy (*afs_longcall_procs.LC_strcpy) - #define strncpy (*afs_longcall_procs.LC_strncpy) - - #define rmfree (*afs_longcall_procs.LC_rmfree) - #define falloc (*afs_longcall_procs.LC_falloc) - #define rdwri (*afs_longcall_procs.LC_rdwri) - - #ifdef XDR_CHAR_IN_KERNEL - #define xdr_char (*afs_longcall_procs.LC_xdr_char) - #endif - - #define iunlock (*afs_longcall_procs.LC_iunlock) - #define ilock (*afs_longcall_procs.LC_ilock) - #define iput (*afs_longcall_procs.LC_iput) - #define ialloc (*afs_longcall_procs.LC_ialloc) - #if !defined(AFS_DECOSF_ENV) - #define vno_close (*afs_longcall_procs.LC_vno_close) - #endif - #define kmem_alloc (*afs_longcall_procs.LC_kmem_alloc) - #define kmem_free (*afs_longcall_procs.LC_kmem_free) - - #define m_cpytoc (*afs_longcall_procs.LC_m_cpytoc) - - #define ufs_brelse (*afs_longcall_procs.LC_ufs_brelse) - #if !defined(AFS_DECOSF_ENV) - #define lookupname (*afs_longcall_procs.LC_lookupname) - #endif - /* #define vn_rele (*afs_longcall_procs.LC_vn_rele) */ - #define mapout (*afs_longcall_procs.LC_mapout) - #define getmp (*afs_longcall_procs.LC_getmp) - #define iget (*afs_longcall_procs.LC_iget) - #define m_more (*afs_longcall_procs.LC_m_more) - #define _spl1 (*afs_longcall_procs.LC__spl1) - - #define bcmp (*afs_longcall_procs.LC_bcmp) - #if !defined(AFS_DECOSF_ENV) - #define splnet (*afs_longcall_procs.LC_splnet) - #define splx (*afs_longcall_procs.LC_splx) - #endif - #define microtime (*afs_longcall_procs.LC_microtime) - /* #define ldiv$$ (*afs_longcall_procs[34]) */ - #define getf (*afs_longcall_procs.LC_getf) - #define soreserve (*afs_longcall_procs.LC_soreserve) - #define socreate (*afs_longcall_procs.LC_socreate) - #define m_get (*afs_longcall_procs.LC_m_get) - #define sobind (*afs_longcall_procs.LC_sobind) - #define soclose (*afs_longcall_procs.LC_soclose) - #define m_freem (*afs_longcall_procs.LC_m_freem) - #if !defined(AFS_DECOSF_ENV) - #define splimp (*afs_longcall_procs.LC_splimp) - #endif - #define m_clalloc (*afs_longcall_procs.LC_m_clalloc) - #define m_free (*afs_longcall_procs.LC_m_free) - #define xrele (*afs_longcall_procs.LC_xrele) - #define mpurge (*afs_longcall_procs.LC_mpurge) - /* #define lmul$$ (*afs_longcall_procs[48]) */ - /* #define timeout (*afs_longcall_procs.LC_timeout) */ - #define untimeout (*afs_longcall_procs.LC_untimeout) - #define resettodr (*afs_longcall_procs.LC_resettodr) - #define m_pullup (*afs_longcall_procs.LC_m_pullup) - #define ip_stripoptions (*afs_longcall_procs.LC_ip_stripoptions) - #define in_cksum (*afs_longcall_procs.LC_in_cksum) - #define crcopy (*afs_longcall_procs.LC_crcopy) - #if !defined(AFS_DECOSF_ENV) - #define crhold (*afs_longcall_procs.LC_crhold) - #endif - #define crget (*afs_longcall_procs.LC_crget) - #define setgroups (*afs_longcall_procs.LC_setgroups) - /* #define flock (*afs_longcall_procs.LC_flock) */ - #define uprintf (*afs_longcall_procs.LC_uprintf) - #define uiomove (*afs_longcall_procs.LC_uiomove) - #define strcmp (*afs_longcall_procs.LC_strcmp) - #define ureadc (*afs_longcall_procs.LC_ureadc) - #define biodone (*afs_longcall_procs.LC_biodone) - /* #define uldiv$$ (*afs_longcall_procs[68]) */ - #define copyout (*afs_longcall_procs.LC_copyout) - #define ioctl (*afs_longcall_procs.LC_ioctl) - #define xdr_int (*afs_longcall_procs.LC_xdr_int) - #define xdr_long (*afs_longcall_procs.LC_xdr_long) - #define xdr_string (*afs_longcall_procs.LC_xdr_string) - #define xdr_u_long (*afs_longcall_procs.LC_xdr_u_long) - #define xdr_u_int (*afs_longcall_procs.LC_xdr_u_int) - #define xdr_bytes (*afs_longcall_procs.LC_xdr_bytes) - #define xdr_array (*afs_longcall_procs.LC_xdr_array) - #define xdr_opaque (*afs_longcall_procs.LC_xdr_opaque) - #define xdr_short (*afs_longcall_procs.LC_xdr_short) - #define xdr_u_short (*afs_longcall_procs.LC_xdr_u_short) - - #if defined(AFS_DECOSF_ENV) - #define assert_wait (*afs_longcall_procs.LC_assert_wait) - #define closef (*afs_longcall_procs.LC_closef) - #define fake_inode_init (*afs_longcall_procs.LC_fake_inode_init) - #define getnewvnode (*afs_longcall_procs.LC_getnewvnode) - #define getvfs (*afs_longcall_procs.LC_getvfs) - #define idrop (*afs_longcall_procs.LC_idrop) - #define insmntque (*afs_longcall_procs.LC_insmntque) - #define ioctl_base (*afs_longcall_procs.LC_ioctl_base) - #define kalloc (*afs_longcall_procs.LC_kalloc) - #define kfree (*afs_longcall_procs.LC_kfree) - #define lock_done (*afs_longcall_procs.LC_lock_done) - #define m_getclr (*afs_longcall_procs.LC_m_getclr) - #define m_retry (*afs_longcall_procs.LC_m_retry) - #define m_retryhdr (*afs_longcall_procs.LC_m_retryhdr) - #define mpsleep (*afs_longcall_procs.LC_mpsleep) - #define namei (*afs_longcall_procs.LC_namei) - #define nuxi_32 (*afs_longcall_procs.LC_nuxi_32) - #define nuxi_16 (*afs_longcall_procs.LC_nuxi_16) - #define setgroups_base (*afs_longcall_procs.LC_setgroups_base) - #define substitute_real_creds (*afs_longcall_procs.LC_substitute_real_creds) - #define swap_ipl (*afs_longcall_procs.LC_swap_ipl) - #define thread_block (*afs_longcall_procs.LC_thread_block) - #define u_vp_create (*afs_longcall_procs.LC_u_vp_create) - #define ubc_bufalloc (*afs_longcall_procs.LC_ubc_bufalloc) - #define ubc_flush_sync (*afs_longcall_procs.LC_ubc_flush_sync) - #define ubc_invalidate (*afs_longcall_procs.LC_ubc_invalidate) - #define ubc_lookup (*afs_longcall_procs.LC_ubc_lookup) - #define ubc_page_dirty (*afs_longcall_procs.LC_ubc_page_dirty) - #define ubc_page_release (*afs_longcall_procs.LC_ubc_page_release) - #define ubc_sync_iodone (*afs_longcall_procs.LC_ubc_sync_iodone) - #define vgetm (*afs_longcall_procs.LC_vgetm) - #define vgone (*afs_longcall_procs.LC_vgone) - #define vn_close (*afs_longcall_procs.LC_vn_close) - /* - #define vn_ioctl (*afs_longcall_procs.LC_vn_ioctl) - #define vn_read (*afs_longcall_procs.LC_vn_read) - #define vn_select (*afs_longcall_procs.LC_vn_select) - #define vn_write (*afs_longcall_procs.LC_vn_write) - */ - #define vrele (*afs_longcall_procs.LC_vrele) - #define xdr_char (*afs_longcall_procs.LC_xdr_char) - #endif /* AFS_DECOSF_ENV */ - - #endif /* LONGCALL_NO_MACROS */ - - #endif - #endif --- 0 ---- Index: openafs/src/afs/DFBSD/osi_prototypes.h diff -c /dev/null openafs/src/afs/DFBSD/osi_prototypes.h:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/afs/DFBSD/osi_prototypes.h Mon Apr 27 14:33:01 2009 *************** *** 0 **** --- 1,22 ---- + /* + * Copyright 2000, International Business Machines Corporation and others. + * All Rights Reserved. + * + * This software has been released under the terms of the IBM Public + * License. For details, see the LICENSE file in the top-level source + * directory or online at http://www.openafs.org/dl/license10.html + */ + /* + * osi_prototypes.h + * + * Exported support routines. + */ + #ifndef _OSI_PROTO_H_ + #define _OSI_PROTO_H_ + + /* osi_file.c */ + extern afs_rwlock_t afs_xosi; + + + + #endif /* _OSI_PROTO_H_ */ Index: openafs/src/afs/LINUX/osi_cred.c diff -c openafs/src/afs/LINUX/osi_cred.c:1.10.2.4 openafs/src/afs/LINUX/osi_cred.c:1.10.2.6 *** openafs/src/afs/LINUX/osi_cred.c:1.10.2.4 Thu Jan 15 08:27:43 2009 --- openafs/src/afs/LINUX/osi_cred.c Mon May 11 10:55:40 2009 *************** *** 15,21 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/LINUX/osi_cred.c,v 1.10.2.4 2009/01/15 13:27:43 shadow Exp $"); #include "afs/sysincludes.h" #include "afsincludes.h" --- 15,21 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/LINUX/osi_cred.c,v 1.10.2.6 2009/05/11 14:55:40 shadow Exp $"); #include "afs/sysincludes.h" #include "afsincludes.h" *************** *** 104,109 **** --- 104,115 ---- #if defined(STRUCT_TASK_HAS_CRED) struct cred *new_creds; + /* If our current task doesn't have identical real and effective + * credentials, commit_cred won't let us change them, so we just + * bail here. + */ + if (current->cred != current->real_cred) + return; new_creds = prepare_creds(); new_creds->fsuid = cr->cr_uid; new_creds->uid = cr->cr_ruid; Index: openafs/src/afs/LINUX/osi_probe.c diff -c openafs/src/afs/LINUX/osi_probe.c:1.1.2.27 openafs/src/afs/LINUX/osi_probe.c:1.1.2.28 *** openafs/src/afs/LINUX/osi_probe.c:1.1.2.27 Thu Jan 15 08:13:21 2009 --- openafs/src/afs/LINUX/osi_probe.c Tue Jun 2 14:32:09 2009 *************** *** 52,58 **** #include #include "afs/param.h" #endif ! #if defined(EXPORTED_INIT_MM) #ifdef AFS_LINUX24_ENV #include /* early to avoid printf->printk mapping */ #ifndef OSI_PROBE_STANDALONE --- 52,58 ---- #include #include "afs/param.h" #endif ! #if defined(ENABLE_LINUX_SYSCALL_PROBING) && defined(EXPORTED_INIT_MM) #ifdef AFS_LINUX24_ENV #include /* early to avoid printf->printk mapping */ #ifndef OSI_PROBE_STANDALONE Index: openafs/src/afs/LINUX/osi_vm.c diff -c openafs/src/afs/LINUX/osi_vm.c:1.16.2.5 openafs/src/afs/LINUX/osi_vm.c:1.16.2.6 *** openafs/src/afs/LINUX/osi_vm.c:1.16.2.5 Fri Mar 27 11:45:49 2009 --- openafs/src/afs/LINUX/osi_vm.c Tue May 12 13:56:50 2009 *************** *** 11,17 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vm.c,v 1.16.2.5 2009/03/27 15:45:49 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ --- 11,17 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vm.c,v 1.16.2.6 2009/05/12 17:56:50 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ *************** *** 102,110 **** { struct inode *ip = AFSTOV(avc); ! if (!avc->states & CPageWrite) ! avc->states |= CPageWrite; ! else return; /* someone already writing */ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,5) --- 102,108 ---- { struct inode *ip = AFSTOV(avc); ! if (avc->states & CPageWrite) return; /* someone already writing */ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,5) *************** *** 120,126 **** AFS_GLOCK(); ObtainWriteLock(&avc->lock, 121); #endif - avc->states &= ~CPageWrite; } /* Purge VM for a file when its callback is revoked. --- 118,123 ---- Index: openafs/src/afs/LINUX/osi_vnodeops.c diff -c openafs/src/afs/LINUX/osi_vnodeops.c:1.81.2.79 openafs/src/afs/LINUX/osi_vnodeops.c:1.81.2.82 *** openafs/src/afs/LINUX/osi_vnodeops.c:1.81.2.79 Tue Apr 7 08:26:15 2009 --- openafs/src/afs/LINUX/osi_vnodeops.c Wed Jun 3 01:41:59 2009 *************** *** 22,28 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vnodeops.c,v 1.81.2.79 2009/04/07 12:26:15 shadow Exp $"); #include "afs/sysincludes.h" #include "afsincludes.h" --- 22,28 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vnodeops.c,v 1.81.2.82 2009/06/03 05:41:59 shadow Exp $"); #include "afs/sysincludes.h" #include "afsincludes.h" *************** *** 503,509 **** crfree(credp); return -code; - } #ifdef STRUCT_FILE_OPERATIONS_HAS_FLOCK --- 503,508 ---- *************** *** 1567,1575 **** ICL_TYPE_POINTER, pp, ICL_TYPE_INT32, page_count(pp), ICL_TYPE_INT32, 99999); ! ObtainReadLock(&vcp->lock); if (vcp->states & CPageWrite) { ! ReleaseReadLock(&vcp->lock); AFS_GUNLOCK(); unlock_kernel(); crfree(credp); --- 1566,1574 ---- ICL_TYPE_POINTER, pp, ICL_TYPE_INT32, page_count(pp), ICL_TYPE_INT32, 99999); ! ObtainWriteLock(&vcp->lock, 532); if (vcp->states & CPageWrite) { ! ReleaseWriteLock(&vcp->lock); AFS_GUNLOCK(); unlock_kernel(); crfree(credp); *************** *** 1585,1591 **** return(0); #endif } ! ReleaseReadLock(&vcp->lock); setup_uio(&tuio, &iovec, buffer, base, count, UIO_WRITE, AFS_UIOSYS); --- 1584,1591 ---- return(0); #endif } ! vcp->states |= CPageWrite; ! ReleaseWriteLock(&vcp->lock); setup_uio(&tuio, &iovec, buffer, base, count, UIO_WRITE, AFS_UIOSYS); *************** *** 1594,1609 **** i_size_write(ip, vcp->m.Length); ip->i_blocks = ((vcp->m.Length + 1023) >> 10) << 1; if (!code) { struct vrequest treq; - ObtainWriteLock(&vcp->lock, 533); if (!afs_InitReq(&treq, credp)) code = afs_DoPartialWrite(vcp, &treq); - ReleaseWriteLock(&vcp->lock); } code = code ? -code : count - tuio.uio_resid; afs_Trace4(afs_iclSetp, CM_TRACE_UPDATEPAGE, ICL_TYPE_POINTER, vcp, ICL_TYPE_POINTER, pp, ICL_TYPE_INT32, page_count(pp), ICL_TYPE_INT32, code); --- 1594,1611 ---- i_size_write(ip, vcp->m.Length); ip->i_blocks = ((vcp->m.Length + 1023) >> 10) << 1; + ObtainWriteLock(&vcp->lock, 533); if (!code) { struct vrequest treq; if (!afs_InitReq(&treq, credp)) code = afs_DoPartialWrite(vcp, &treq); } code = code ? -code : count - tuio.uio_resid; + vcp->states &= ~CPageWrite; + ReleaseWriteLock(&vcp->lock); + afs_Trace4(afs_iclSetp, CM_TRACE_UPDATEPAGE, ICL_TYPE_POINTER, vcp, ICL_TYPE_POINTER, pp, ICL_TYPE_INT32, page_count(pp), ICL_TYPE_INT32, code); *************** *** 1658,1664 **** do_it: status = afs_linux_writepage_sync(inode, pp, 0, offset); SetPageUptodate(pp); ! UnlockPage(pp); if (status == offset) return 0; else --- 1660,1671 ---- do_it: status = afs_linux_writepage_sync(inode, pp, 0, offset); SetPageUptodate(pp); ! #if defined(WRITEPAGE_ACTIVATE) ! if ( status != WRITEPAGE_ACTIVATE ) ! #else ! if ( status != AOP_WRITEPAGE_ACTIVATE ) ! #endif ! UnlockPage(pp); if (status == offset) return 0; else Index: openafs/src/afs/UKERNEL/afs_usrops.c diff -c openafs/src/afs/UKERNEL/afs_usrops.c:1.27.2.10 openafs/src/afs/UKERNEL/afs_usrops.c:1.27.2.11 *** openafs/src/afs/UKERNEL/afs_usrops.c:1.27.2.10 Mon Dec 29 16:26:24 2008 --- openafs/src/afs/UKERNEL/afs_usrops.c Mon Apr 27 14:33:01 2009 *************** *** 1,3 **** --- 1,4 ---- + /* * Copyright 2000, International Business Machines Corporation and others. * All Rights Reserved. *************** *** 15,21 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/UKERNEL/afs_usrops.c,v 1.27.2.10 2008/12/29 21:26:24 shadow Exp $"); #ifdef UKERNEL --- 16,22 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/UKERNEL/afs_usrops.c,v 1.27.2.11 2009/04/27 18:33:01 shadow Exp $"); #ifdef UKERNEL *************** *** 1315,1322 **** --- 1316,1328 ---- for (currp = readdir(cdirp); currp; currp = readdir(cdirp)) { if (afsd_debug) { printf("%s: Current directory entry:\n", rn); + #if defined(AFS_USR_DFBSD_ENV) + printf("\tinode=%d, name='%s'\n", currp->d_ino, + currp->d_name); + #else printf("\tinode=%d, reclen=%d, name='%s'\n", currp->d_ino, currp->d_reclen, currp->d_name); + #endif } /* *************** *** 2067,2072 **** --- 2073,2079 ---- iob.in_size = tlen; iob.out = &outbuf[0]; iob.out_size = sizeof(outbuf); + rc = call_syscall(AFSCALL_PIOCTL, 0, _VICEIOCTL(3), (long)&iob, 0, 0); if (rc != 0) { errno = rc; Index: openafs/src/afs/UKERNEL/sysincludes.h diff -c openafs/src/afs/UKERNEL/sysincludes.h:1.15.2.3 openafs/src/afs/UKERNEL/sysincludes.h:1.15.2.4 *** openafs/src/afs/UKERNEL/sysincludes.h:1.15.2.3 Mon Dec 29 16:26:24 2008 --- openafs/src/afs/UKERNEL/sysincludes.h Fri May 22 12:31:43 2009 *************** *** 140,145 **** --- 140,159 ---- #endif #endif /* AFS_USR_DARWIN_ENV || AFS_USR_FBSD_ENV */ + #ifdef HAVE_SYS_BITYPES_H + #include + #endif + #ifdef HAVE_SYS_STATFS_H + #include + #endif + #ifdef HAVE_SYS_STATVFS_H + #include + #endif + + #ifndef HAVE_FSBLKCNT_T + typedef unsigned int fsblkcnt_t; + #endif + #ifdef AFS_AFSDB_ENV #include #include *************** *** 1038,1044 **** struct timeval va_ctime; dev_t va_rdev; unsigned long va_blocksize; ! blkcnt_t va_blocks; unsigned long va_vcode; }; --- 1052,1058 ---- struct timeval va_ctime; dev_t va_rdev; unsigned long va_blocksize; ! fsblkcnt_t va_blocks; unsigned long va_vcode; }; Index: openafs/src/afs/VNOPS/afs_vnop_flock.c diff -c openafs/src/afs/VNOPS/afs_vnop_flock.c:1.24.2.10 openafs/src/afs/VNOPS/afs_vnop_flock.c:1.24.2.11 *** openafs/src/afs/VNOPS/afs_vnop_flock.c:1.24.2.10 Sat Mar 10 11:08:08 2007 --- openafs/src/afs/VNOPS/afs_vnop_flock.c Wed Jun 3 14:26:02 2009 *************** *** 16,22 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/VNOPS/afs_vnop_flock.c,v 1.24.2.10 2007/03/10 16:08:08 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ --- 16,22 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/afs/VNOPS/afs_vnop_flock.c,v 1.24.2.11 2009/06/03 18:26:02 shadow Exp $"); #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ *************** *** 954,964 **** return code; #else /* AFS_OSF_ENV */ if (!flockDone) - #ifdef DYNEL - (*afs_longcall_procs.LC_flock) (); - #else flock(); - #endif afs_PutFakeStat(&fakestate); return; #endif --- 954,960 ---- Index: openafs/src/afsd/afs.conf.linux diff -c openafs/src/afsd/afs.conf.linux:1.7.8.2 openafs/src/afsd/afs.conf.linux:1.7.8.3 *** openafs/src/afsd/afs.conf.linux:1.7.8.2 Sun Oct 2 23:14:31 2005 --- openafs/src/afsd/afs.conf.linux Sat May 30 13:56:41 2009 *************** *** 59,64 **** --- 59,66 ---- # -logfile Place where to put the logfile (default in /etc/AFSLog. # -waitclose make close calls always synchronous (slows em down, tho) # -files_per_subdir [n] number of files per cache subdir. (def=2048) + # -rxmaxmtu Max mtu. Useful when using VPN when packets might fragment. + # a value of 1244 should work. # -shutdown Shutdown afs daemons # --------------------------------------------------------------------------- XXLARGE="-fakestat -stat 4000 -dcache 4000 -daemons 6 -volumes 256 -files 50000" Index: openafs/src/afsd/afsd.c diff -c openafs/src/afsd/afsd.c:1.43.2.26 openafs/src/afsd/afsd.c:1.43.2.28 *** openafs/src/afsd/afsd.c:1.43.2.26 Thu Mar 19 22:32:59 2009 --- openafs/src/afsd/afsd.c Sat May 30 13:56:41 2009 *************** *** 31,36 **** --- 31,37 ---- * -confdir The configuration directory . * -nosettime Don't keep checking the time to avoid drift (default). * -settime Keep checking the time to avoid drift. + * -rxmaxmtu Set the max mtu to help with VPN issues. * -verbose Be chatty. * -disable-dynamic-vcaches Disable the use of -stat value as the starting size of * the size of the vcache/stat cache pool, *************** *** 61,67 **** #include RCSID ! ("$Header: /cvs/openafs/src/afsd/afsd.c,v 1.43.2.26 2009/03/20 02:32:59 shadow Exp $"); #define VFS 1 --- 62,68 ---- #include RCSID ! ("$Header: /cvs/openafs/src/afsd/afsd.c,v 1.43.2.28 2009/05/30 17:56:41 shadow Exp $"); #define VFS 1 *************** *** 319,324 **** --- 320,326 ---- int afsd_verbose = 0; /*Are we being chatty? */ int afsd_debug = 0; /*Are we printing debugging info? */ int afsd_CloseSynch = 0; /*Are closes synchronous or not? */ + int rxmaxmtu = 0; /* Are we forcing a limit on the mtu? */ #ifdef AFS_SGI62_ENV #define AFSD_INO_T ino64_t *************** *** 988,993 **** --- 990,997 ---- #ifdef AFS_SGI62_ENV printf("\tinode=%lld, reclen=%d, name='%s'\n", currp->d_ino, currp->d_reclen, currp->d_name); + #elif defined(AFS_DFBSD_ENV) + printf("\tinode=%d, name='%s'\n", currp->d_ino, currp->d_name); #else printf("\tinode=%d, reclen=%d, name='%s'\n", currp->d_ino, currp->d_reclen, currp->d_name); *************** *** 1759,1764 **** --- 1763,1774 ---- printf("afsd: %s dynamically allocated vcaches\n", ( afsd_dynamic_vcaches ? "enabling" : "disabling" )); #endif + /* set -rxmaxmtu */ + if (as->parms[35].items) { + /* -rxmaxmtu */ + rxmaxmtu = atoi(as->parms[35].items->data); + } + /* * Pull out all the configuration info for the workstation's AFS cache and * the cellular community we're willing to let our users see. *************** *** 2171,2176 **** --- 2181,2194 ---- fullpn_CellInfoFile); call_syscall(AFSOP_CELLINFO, fullpn_CellInfoFile); + if (rxmaxmtu) { + if (afsd_verbose) + printf("%s: Setting rxmaxmtu in kernel = %d\n", rn, rxmaxmtu); + code = call_syscall(AFSOP_SET_RXMAXMTU, rxmaxmtu); + if (code) + printf("%s: Error seting rxmaxmtu\n", rn); + } + if (enable_dynroot) { if (afsd_verbose) printf("%s: Enabling dynroot support in kernel.\n", rn); *************** *** 2470,2475 **** --- 2488,2494 ---- "set the time"); cmd_AddParm(ts, "-rxpck", CMD_SINGLE, CMD_OPTIONAL, "set rx_extraPackets to this value"); cmd_AddParm(ts, "-disable-dynamic-vcaches", CMD_FLAG, CMD_OPTIONAL, "disable stat/vcache cache growing as needed"); + cmd_AddParm(ts, "-rxmaxmtu", CMD_SINGLE, CMD_OPTIONAL, "set rx max MTU to use"); return (cmd_Dispatch(argc, argv)); } Index: openafs/src/afsweb/apache_afs_utils.c diff -c openafs/src/afsweb/apache_afs_utils.c:1.4 openafs/src/afsweb/apache_afs_utils.c:1.4.2.1 *** openafs/src/afsweb/apache_afs_utils.c:1.4 Tue Jul 15 19:14:33 2003 --- openafs/src/afsweb/apache_afs_utils.c Wed Jun 3 01:41:59 2009 *************** *** 93,127 **** return 0; } - /* get the current AFS pag for the calling process */ - static afs_int32 - curpag() - { - gid_t groups[30]; - afs_uint32 g0, g1; - afs_uint32 h, l, ret; - - if (getgroups(sizeof groups / sizeof groups[0], groups) < 2) - return 0; - - g0 = groups[0] & 0xffff; - g1 = groups[1] & 0xffff; - g0 -= 0x3f00; - g1 -= 0x3f00; - if (g0 < 0xc000 && g1 < 0xc000) { - l = ((g0 & 0x3fff) << 14) | (g1 & 0x3fff); - h = (g0 >> 14); - h = (g1 >> 14) + h + h + h; - ret = ((h << 28) | l); - /* Additional testing */ - if (((ret >> 24) & 0xff) == 'A') - return ret; - else - return -1; - } - return -1; - } - /* Returns the AFS pag number, if any, otherwise return -1 */ afs_int32 getPAG() --- 93,98 ---- *************** *** 131,137 **** assert(sizeof(afs_uint32) == 4); assert(sizeof(afs_int32) == 4); ! pag = curpag(); if (pag == 0 || pag == -1) return -1; --- 102,108 ---- assert(sizeof(afs_uint32) == 4); assert(sizeof(afs_int32) == 4); ! pag = ktc_curpag(); if (pag == 0 || pag == -1) return -1; Index: openafs/src/aklog/asetkey.c diff -c openafs/src/aklog/asetkey.c:1.4.2.10 openafs/src/aklog/asetkey.c:1.4.2.11 *** openafs/src/aklog/asetkey.c:1.4.2.10 Tue Apr 1 13:44:52 2008 --- openafs/src/aklog/asetkey.c Wed Jun 3 01:41:59 2009 *************** *** 1,5 **** /* ! * $Id: asetkey.c,v 1.4.2.10 2008/04/01 17:44:52 shadow Exp $ * * asetkey - Manipulates an AFS KeyFile * --- 1,5 ---- /* ! * $Id: asetkey.c,v 1.4.2.11 2009/06/03 05:41:59 shadow Exp $ * * asetkey - Manipulates an AFS KeyFile * *************** *** 37,42 **** --- 37,65 ---- #define USING_HEIMDAL 1 #endif + static int + char2hex(char c) + { + if (c >= '0' && c <= '9') + return (c - 48); + if ((c >= 'a') && (c <= 'f')) + return (c - 'a' + 10); + + if ((c >= 'A') && (c <= 'F')) + return (c - 'A' + 10); + + return -1; + } + + static int + hex2char(char c) + { + if (c <= 9) + return (c + 48); + + return (c - 10 + 'a'); + } + int main(int argc, char *argv[]) { *************** *** 48,53 **** --- 71,78 ---- fprintf(stderr, "%s: usage is '%s options, e.g.\n", argv[0], argv[0]); fprintf(stderr, "\t%s add \n", argv[0]); + fprintf(stderr, "\tOR\n\t%s add \n", argv[0]); + fprintf(stderr, "\t\tEx: %s add 0 \"80b6a7cd7a9dadb6\"\n", argv[0]); fprintf(stderr, "\t%s delete \n", argv[0]); fprintf(stderr, "\t%s list\n", argv[0]); exit(1); *************** *** 66,120 **** krb5_principal principal; krb5_keyblock *key; krb5_error_code retval; ! int kvno; if (argc != 5) { ! fprintf(stderr, "%s add: usage is '%s add " ! "\n", argv[0], argv[0]); ! exit(1); } - krb5_init_context(&context); - kvno = atoi(argv[2]); ! retval = krb5_parse_name(context, argv[4], &principal); ! if (retval != 0) { afs_com_err(argv[0], retval, "while parsing AFS principal"); exit(1); ! } ! retval = krb5_kt_read_service_key(context, argv[3], principal, kvno, ! ENCTYPE_DES_CBC_CRC, &key); ! if (retval != 0) { afs_com_err(argv[0], retval, "while extracting AFS service key"); exit(1); ! } ! #ifdef USING_HEIMDAL ! #define deref_key_length(key) \ ! key->keyvalue.length ! ! #define deref_key_contents(key) \ ! key->keyvalue.data #else ! #define deref_key_length(key) \ ! key->length ! ! #define deref_key_contents(key) \ ! key->contents #endif ! if (deref_key_length(key) != 8) { fprintf(stderr, "Key length should be 8, but is really %d!\n", deref_key_length(key)); exit(1); } - code = afsconf_AddKey(tdir, kvno, (char *) deref_key_contents(key), 1); if (code) { fprintf(stderr, "%s: failed to set key, code %ld.\n", argv[0], code); exit(1); } ! krb5_free_principal(context, principal); ! krb5_free_keyblock(context, key); } else if (strcmp(argv[1], "delete")==0) { long kvno; --- 91,169 ---- krb5_principal principal; krb5_keyblock *key; krb5_error_code retval; ! int kvno, keymode = 0; if (argc != 5) { ! if (argc == 4) ! keymode = 1; ! else { ! fprintf(stderr, "%s add: usage is '%s add " ! "\n", argv[0], argv[0]); ! fprintf(stderr, "\tOR\n\t%s add \n", argv[0]); ! fprintf(stderr, "\t\tEx: %s add 0 \"80b6a7cd7a9dadb6\"\n", argv[0]); ! exit(1); ! } } kvno = atoi(argv[2]); ! if (keymode) { ! char tkey[8]; ! int i; ! char *cp; ! if (strlen(argv[3]) != 16) { ! printf("key %s is not in right format\n", argv[3]); ! printf(" should be an 8byte hex representation \n"); ! printf(" Ex: setkey add 0 \"80b6a7cd7a9dadb6\"\n"); ! exit(1); ! } ! memset(tkey, 0, sizeof(tkey)); ! for (i = 7, cp = argv[3] + 15; i >= 0; i--, cp -= 2) ! tkey[i] = char2hex(*cp) + char2hex(*(cp - 1)) * 16; ! code = afsconf_AddKey(tdir, kvno, tkey, 1); ! } else { ! krb5_init_context(&context); ! ! retval = krb5_parse_name(context, argv[4], &principal); ! if (retval != 0) { afs_com_err(argv[0], retval, "while parsing AFS principal"); exit(1); ! } ! retval = krb5_kt_read_service_key(context, argv[3], principal, kvno, ! ENCTYPE_DES_CBC_CRC, &key); ! if (retval != 0) { afs_com_err(argv[0], retval, "while extracting AFS service key"); exit(1); ! } ! #ifdef USING_HEIMDAL ! #define deref_key_length(key) \ ! key->keyvalue.length ! ! #define deref_key_contents(key) \ ! key->keyvalue.data #else ! #define deref_key_length(key) \ ! key->length ! ! #define deref_key_contents(key) \ ! key->contents #endif ! if (deref_key_length(key) != 8) { fprintf(stderr, "Key length should be 8, but is really %d!\n", deref_key_length(key)); exit(1); + } + code = afsconf_AddKey(tdir, kvno, (char *) deref_key_contents(key), 1); } if (code) { fprintf(stderr, "%s: failed to set key, code %ld.\n", argv[0], code); exit(1); } ! if (keymode == 0) { ! krb5_free_principal(context, principal); ! krb5_free_keyblock(context, key); ! } } else if (strcmp(argv[1], "delete")==0) { long kvno; Index: openafs/src/aklog/klog.c diff -c openafs/src/aklog/klog.c:1.3.4.9 openafs/src/aklog/klog.c:1.3.4.10 *** openafs/src/aklog/klog.c:1.3.4.9 Fri Apr 18 16:50:30 2008 --- openafs/src/aklog/klog.c Wed Jun 3 16:58:29 2009 *************** *** 356,362 **** krb5_creds incred[1], mcred[1], *outcred = 0, *afscred; krb5_ccache cc = 0; krb5_get_init_creds_opt gic_opts[1]; ! char *tofree, *outname; int code; char *what; int i, dosetpag, evil, noprdb, id; --- 356,362 ---- krb5_creds incred[1], mcred[1], *outcred = 0, *afscred; krb5_ccache cc = 0; krb5_get_init_creds_opt gic_opts[1]; ! char *tofree = NULL, *outname; int code; char *what; int i, dosetpag, evil, noprdb, id; Index: openafs/src/auth/Makefile.in diff -c openafs/src/auth/Makefile.in:1.12.2.2 openafs/src/auth/Makefile.in:1.12.2.3 *** openafs/src/auth/Makefile.in:1.12.2.2 Thu Jul 13 13:19:39 2006 --- openafs/src/auth/Makefile.in Wed Jun 3 01:42:00 2009 *************** *** 13,19 **** KOBJS= cellconfig.o ktc.krb.o userok.o writeconfig.o authcon.o \ acfg_errors.o ktc_errors.o ! LIBS=libauth.a ${TOP_LIBDIR}/libsys.a \ ${TOP_LIBDIR}/librxkad.a ${TOP_LIBDIR}/libdes.a \ ${TOP_LIBDIR}/librx.a ${TOP_LIBDIR}/libsys.a \ ${TOP_LIBDIR}/liblwp.a ${TOP_LIBDIR}/util.a --- 13,19 ---- KOBJS= cellconfig.o ktc.krb.o userok.o writeconfig.o authcon.o \ acfg_errors.o ktc_errors.o ! LIBS=libauth.a \ ${TOP_LIBDIR}/librxkad.a ${TOP_LIBDIR}/libdes.a \ ${TOP_LIBDIR}/librx.a ${TOP_LIBDIR}/libsys.a \ ${TOP_LIBDIR}/liblwp.a ${TOP_LIBDIR}/util.a *************** *** 25,33 **** all: \ ${TOP_LIBDIR}/libauth.a \ ${TOP_LIBDIR}/libauth.krb.a \ ! depinstall \ ! copyauth \ ! setkey depinstall: \ ${TOP_INCDIR}/afs/keys.h \ --- 25,31 ---- all: \ ${TOP_LIBDIR}/libauth.a \ ${TOP_LIBDIR}/libauth.krb.a \ ! depinstall depinstall: \ ${TOP_INCDIR}/afs/keys.h \ *************** *** 84,91 **** ${DESTDIR}${includedir}/afs/keys.h \ ${DESTDIR}${includedir}/afs/cellconfig.h \ ${DESTDIR}${includedir}/afs/auth.h \ ! ${DESTDIR}${includedir}/afs/ktc.h \ ! ${DESTDIR}${sbindir}/copyauth # # Misc. targets --- 82,88 ---- ${DESTDIR}${includedir}/afs/keys.h \ ${DESTDIR}${includedir}/afs/cellconfig.h \ ${DESTDIR}${includedir}/afs/auth.h \ ! ${DESTDIR}${includedir}/afs/ktc.h # # Misc. targets *************** *** 170,175 **** ${DEST}/include/afs/keys.h \ ${DEST}/include/afs/cellconfig.h \ ${DEST}/include/afs/auth.h \ ! ${DEST}/include/afs/ktc.h \ ! ${DEST}/etc/copyauth --- 167,171 ---- ${DEST}/include/afs/keys.h \ ${DEST}/include/afs/cellconfig.h \ ${DEST}/include/afs/auth.h \ ! ${DEST}/include/afs/ktc.h Index: openafs/src/auth/cellconfig.c diff -c openafs/src/auth/cellconfig.c:1.40.2.19 openafs/src/auth/cellconfig.c:1.40.2.21 *** openafs/src/auth/cellconfig.c:1.40.2.19 Fri Nov 2 14:26:38 2007 --- openafs/src/auth/cellconfig.c Mon Jun 1 23:33:09 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/auth/cellconfig.c,v 1.40.2.19 2007/11/02 18:26:38 shadow Exp $"); #include #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/auth/cellconfig.c,v 1.40.2.21 2009/06/02 03:33:09 jaltman Exp $"); #include #include *************** *** 20,25 **** --- 20,26 ---- #include "afsincludes.h" #include "des/des.h" #include "rx/rxkad.h" + #include #else /* UKERNEL */ #include #ifdef AFS_NT40_ENV *************** *** 230,236 **** #if defined(AFS_OSF_ENV) ts = getservbyname(aname, ""); #else ! ts = getservbyname(aname, NULL); #endif if (ts) { /* we found it in /etc/services, so we use this value */ --- 231,237 ---- #if defined(AFS_OSF_ENV) ts = getservbyname(aname, ""); #else ! ts = (struct servent *) getservbyname(aname, NULL); #endif if (ts) { /* we found it in /etc/services, so we use this value */ *************** *** 635,665 **** return -1; } i = curEntry->cellInfo.numServers; ! if (cell && !strcmp(cell, curEntry->cellInfo.name)) ! code = ! ParseHostLine(tbuffer, &curEntry->cellInfo.hostAddr[i], ! curEntry->cellInfo.hostName[i], &clones[i]); ! else ! code = ! ParseHostLine(tbuffer, &curEntry->cellInfo.hostAddr[i], ! curEntry->cellInfo.hostName[i], 0); ! if (code) { ! if (code == AFSCONF_SYNTAX) { ! for (bp = tbuffer; *bp != '\n'; bp++) { /* Take out the from the buffer */ ! if (!*bp) ! break; } ! *bp = '\0'; ! fprintf(stderr, ! "Can't properly parse host line \"%s\" in configuration file %s\n", ! tbuffer, tbuf1); } ! free(curEntry); ! fclose(tf); ! afsconf_CloseInternal(adir); ! return -1; } - curEntry->cellInfo.numServers = ++i; } } fclose(tf); /* close the file now */ --- 636,676 ---- return -1; } i = curEntry->cellInfo.numServers; ! if (i < MAXHOSTSPERCELL) { ! if (cell && !strcmp(cell, curEntry->cellInfo.name)) ! code = ! ParseHostLine(tbuffer, ! &curEntry->cellInfo.hostAddr[i], ! curEntry->cellInfo.hostName[i], ! &clones[i]); ! else ! code = ! ParseHostLine(tbuffer, ! &curEntry->cellInfo.hostAddr[i], ! curEntry->cellInfo.hostName[i], 0); ! ! if (code) { ! if (code == AFSCONF_SYNTAX) { ! for (bp = tbuffer; *bp != '\n'; bp++) { /* Take out the from the buffer */ ! if (!*bp) ! break; ! } ! *bp = '\0'; ! fprintf(stderr, ! "Can't properly parse host line \"%s\" in configuration file %s\n", ! tbuffer, tbuf1); } ! free(curEntry); ! fclose(tf); ! afsconf_CloseInternal(adir); ! return -1; } ! curEntry->cellInfo.numServers = ++i; ! } else { ! fprintf(stderr, ! "Too many hosts for cell %s in configuration file %s\n", ! curEntry->cellInfo.name, tbuf1); } } } fclose(tf); /* close the file now */ Index: openafs/src/auth/ktc.c diff -c openafs/src/auth/ktc.c:1.15.2.11 openafs/src/auth/ktc.c:1.15.2.13 *** openafs/src/auth/ktc.c:1.15.2.11 Fri Mar 20 18:45:37 2009 --- openafs/src/auth/ktc.c Thu Jun 4 16:51:57 2009 *************** *** 17,23 **** #endif RCSID ! ("$Header: /cvs/openafs/src/auth/ktc.c,v 1.15.2.11 2009/03/20 22:45:37 shadow Exp $"); #if defined(UKERNEL) #include "afs/sysincludes.h" --- 17,23 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/auth/ktc.c,v 1.15.2.13 2009/06/04 20:51:57 shadow Exp $"); #if defined(UKERNEL) #include "afs/sysincludes.h" *************** *** 1613,1651 **** return 0; } ! static afs_uint32 ! curpag(void) { ! #if defined(AFS_AIX51_ENV) ! int code = getpagvalue("afs"); ! if (code < 0 && errno == EINVAL) ! code = 0; ! return code; ! #else ! gid_t groups[NGROUPS_MAX]; ! afs_uint32 g0, g1; ! afs_uint32 h, l, ret; ! if (getgroups(sizeof groups / sizeof groups[0], groups) < 2) ! return 0; ! g0 = groups[0] & 0xffff; ! g1 = groups[1] & 0xffff; ! g0 -= 0x3f00; ! g1 -= 0x3f00; ! if (g0 < 0xc000 && g1 < 0xc000) { ! l = ((g0 & 0x3fff) << 14) | (g1 & 0x3fff); ! h = (g0 >> 14); ! h = (g1 >> 14) + h + h + h; ! ret = ((h << 28) | l); ! /* Additional testing */ ! if (((ret >> 24) & 0xff) == 'A') ! return ret; ! else ! return -1; ! } ! return -1; #endif } int --- 1613,1667 ---- return 0; } ! afs_uint32 ! ktc_curpag(void) { ! int code; ! struct ViceIoctl iob; ! afs_int32 pag; ! /* now setup for the pioctl */ ! iob.in = -1; ! iob.in_size = 0; ! iob.out = &pag; ! iob.out_size = sizeof(afs_int32); ! code = PIOCTL(0, VIOC_GETPAG, &iob, 0); ! if (code < 0) { ! #if defined(AFS_AIX52_ENV) ! code = getpagvalue("afs"); ! if (code < 0 && errno == EINVAL) ! code = 0; ! return code; ! #elif defined(AFS_AIX51_ENV) ! return -1; ! #else ! gid_t groups[NGROUPS_MAX]; ! afs_uint32 g0, g1; ! afs_uint32 h, l, ret; ! ! if (getgroups(sizeof groups / sizeof groups[0], groups) < 2) ! return 0; ! ! g0 = groups[0] & 0xffff; ! g1 = groups[1] & 0xffff; ! g0 -= 0x3f00; ! g1 -= 0x3f00; ! if (g0 < 0xc000 && g1 < 0xc000) { ! l = ((g0 & 0x3fff) << 14) | (g1 & 0x3fff); ! h = (g0 >> 14); ! h = (g1 >> 14) + h + h + h; ! ret = ((h << 28) | l); ! /* Additional testing */ ! if (((ret >> 24) & 0xff) == 'A') ! return ret; ! else ! return -1; ! } ! return -1; #endif + } + return pag; } int *************** *** 1656,1674 **** afs_uint32 pag; struct stat sbuf; char fname[256], *prefix = "/ticket/"; int numenv; char **newenv, **senv, **denv; LOCK_GLOBAL_MUTEX; if (stat("/ticket", &sbuf) == -1) { prefix = "/tmp/tkt"; } ! pag = curpag() & 0xffffffff; if (pag == -1) { sprintf(fname, "%s%d", prefix, getuid()); } else { sprintf(fname, "%sp%ld", prefix, (long int) pag); } ktc_set_tkt_string(fname); --- 1672,1694 ---- afs_uint32 pag; struct stat sbuf; char fname[256], *prefix = "/ticket/"; + char fname5[256], *prefix5 = "FILE:/ticket/krb5cc_"; int numenv; char **newenv, **senv, **denv; LOCK_GLOBAL_MUTEX; if (stat("/ticket", &sbuf) == -1) { prefix = "/tmp/tkt"; + prefix5 = "FILE:/tmp/krb5cc_"; } ! pag = ktc_curpag() & 0xffffffff; if (pag == -1) { sprintf(fname, "%s%d", prefix, getuid()); + sprintf(fname5, "%s%d", prefix5, getuid()); } else { sprintf(fname, "%sp%ld", prefix, (long int) pag); + sprintf(fname5, "%sp%lud", prefix5, (long int) pag); } ktc_set_tkt_string(fname); *************** *** 1677,1689 **** newenv = (char **)malloc((numenv + 2) * sizeof(char *)); for (senv = environ, denv = newenv; *senv; senv++) { ! if (strncmp(*senv, "KRBTKFILE=", 10) != 0) *denv++ = *senv; } ! *denv = (char *)malloc(10 + strlen(fname) + 1); strcpy(*denv, "KRBTKFILE="); strcat(*denv, fname); *++denv = 0; environ = newenv; UNLOCK_GLOBAL_MUTEX; --- 1697,1714 ---- newenv = (char **)malloc((numenv + 2) * sizeof(char *)); for (senv = environ, denv = newenv; *senv; senv++) { ! if (strncmp(*senv, "KRBTKFILE=", 10) != 0 && ! strncmp(*senv, "KRB5CCNAME=", 11) != 0) *denv++ = *senv; } ! *denv = malloc(10+11 + strlen(fname) + strlen(fname5) + 2); strcpy(*denv, "KRBTKFILE="); strcat(*denv, fname); + *(denv+1) = *denv + strlen(*denv) + 1; + denv++; + strcpy(*denv, "KRB5CCNAME="); + strcat(*denv, fname5); *++denv = 0; environ = newenv; UNLOCK_GLOBAL_MUTEX; Index: openafs/src/bozo/bos.c diff -c openafs/src/bozo/bos.c:1.20.2.4 openafs/src/bozo/bos.c:1.20.2.5 *** openafs/src/bozo/bos.c:1.20.2.4 Wed Oct 31 00:13:34 2007 --- openafs/src/bozo/bos.c Thu Jun 11 10:19:35 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/bozo/bos.c,v 1.20.2.4 2007/10/31 04:13:34 shadow Exp $"); #include #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/bozo/bos.c,v 1.20.2.5 2009/06/11 14:19:35 shadow Exp $"); #include #include *************** *** 1270,1276 **** printf("bos: command line too big\n"); return (E2BIG); } ! strcat(tbuffer, " -f "); strcat(tbuffer, partName); } --- 1270,1276 ---- printf("bos: command line too big\n"); return (E2BIG); } ! strcat(tbuffer, " -force "); strcat(tbuffer, partName); } Index: openafs/src/bucoord/bc.p.h diff -c openafs/src/bucoord/bc.p.h:1.3.2.4 openafs/src/bucoord/bc.p.h:1.3.2.5 *** openafs/src/bucoord/bc.p.h:1.3.2.4 Tue Oct 30 11:23:50 2007 --- openafs/src/bucoord/bc.p.h Mon Apr 27 15:17:41 2009 *************** *** 144,147 **** #define BC_MAXSIMDUMPS 64 #define BC_MAXPORTS 128 /* max number of port offsets for volrestore */ /* debugging support */ ! #define dprintf(x) --- 144,147 ---- #define BC_MAXSIMDUMPS 64 #define BC_MAXPORTS 128 /* max number of port offsets for volrestore */ /* debugging support */ ! #define afs_dprintf(x) Index: openafs/src/bucoord/ubik_db_if.c diff -c openafs/src/bucoord/ubik_db_if.c:1.10.2.5 openafs/src/bucoord/ubik_db_if.c:1.10.2.6 *** openafs/src/bucoord/ubik_db_if.c:1.10.2.5 Fri Mar 27 09:46:13 2009 --- openafs/src/bucoord/ubik_db_if.c Mon Apr 27 15:17:41 2009 *************** *** 13,19 **** #include RCSID ! ("$Header: /cvs/openafs/src/bucoord/ubik_db_if.c,v 1.10.2.5 2009/03/27 13:46:13 shadow Exp $"); #include #include --- 13,19 ---- #include RCSID ! ("$Header: /cvs/openafs/src/bucoord/ubik_db_if.c,v 1.10.2.6 2009/04/27 19:17:41 shadow Exp $"); #include #include *************** *** 601,607 **** fileSize = (afs_int32) filesize(ctPtr->textStream); ! dprintf(("filesize is %d\n", fileSize)); rewind(ctPtr->textStream); --- 601,607 ---- fileSize = (afs_int32) filesize(ctPtr->textStream); ! afs_dprintf(("filesize is %d\n", fileSize)); rewind(ctPtr->textStream); *************** *** 1390,1396 **** ERROR(errno); #endif ! dprintf(("file is %s\n", tmpFileName)); normal_exit: return code; --- 1390,1396 ---- ERROR(errno); #endif ! afs_dprintf(("file is %s\n", tmpFileName)); normal_exit: return code; Index: openafs/src/cf/osconf.m4 diff -c openafs/src/cf/osconf.m4:1.51.2.40 openafs/src/cf/osconf.m4:1.51.2.41 *** openafs/src/cf/osconf.m4:1.51.2.40 Mon Dec 29 12:29:30 2008 --- openafs/src/cf/osconf.m4 Mon Apr 27 14:33:03 2009 *************** *** 246,251 **** --- 246,264 ---- YACC="byacc" ;; + i386_dfbsd_*) + LEX="flex -l" + MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}' + MT_LIBS="-pthread" + PAM_OPTMZ=-O2 + PAM_CFLAGS="-pipe -fPIC" + SHLIB_LDFLAGS="-shared -Xlinker -x" + SHLIB_LINKER="${MT_CC} -shared" + TXLIBS="-lncurses" + XCFLAGS="-pipe" + YACC="byacc" + ;; + amd64_fbsd_*) LEX="flex -l" MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}' Index: openafs/src/config/.cvsignore diff -c openafs/src/config/.cvsignore:1.5.2.1 openafs/src/config/.cvsignore:1.5.2.2 *** openafs/src/config/.cvsignore:1.5.2.1 Fri Jan 11 17:43:40 2008 --- openafs/src/config/.cvsignore Mon Jun 1 18:51:32 2009 *************** *** 3,8 **** --- 3,9 ---- Makefile.*_*[0123456789] Makefile.*_*[0123456789].in Makefile.version + Makefile.version-CML Makefile.version-NOCML afsconfig.h afsconfig.h.in Index: openafs/src/config/Makefile.component diff -c /dev/null openafs/src/config/Makefile.component:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/config/Makefile.component Wed May 27 15:45:10 2009 *************** *** 0 **** --- 1,2 ---- + include Makefile.config + include Makefile.version Index: openafs/src/config/Makefile.in diff -c openafs/src/config/Makefile.in:1.14.2.4 openafs/src/config/Makefile.in:1.14.2.6 *** openafs/src/config/Makefile.in:1.14.2.4 Fri Feb 9 13:44:39 2007 --- openafs/src/config/Makefile.in Mon Jun 1 13:52:14 2009 *************** *** 23,29 **** Makefile.version: ${srcdir}/Makefile.version-CML Makefile.version-NOCML $(RM) -f Makefile.version ! if [ -r SRC/../CML/state ] ; \ then $(CP) ${srcdir}/Makefile.version-CML Makefile.version ; \ else $(CP) Makefile.version-NOCML Makefile.version ; \ fi --- 23,29 ---- Makefile.version: ${srcdir}/Makefile.version-CML Makefile.version-NOCML $(RM) -f Makefile.version ! if [ -r @TOP_SRCDIR@/CML/state ] ; \ then $(CP) ${srcdir}/Makefile.version-CML Makefile.version ; \ else $(CP) Makefile.version-NOCML Makefile.version ; \ fi Index: openafs/src/config/Makefile.version-CML diff -c openafs/src/config/Makefile.version-CML:1.3 openafs/src/config/Makefile.version-CML:removed *** openafs/src/config/Makefile.version-CML:1.3 Fri Sep 7 19:34:53 2001 --- openafs/src/config/Makefile.version-CML Thu Jun 11 11:13:07 2009 *************** *** 1,25 **** - # Copyright 2000, International Business Machines Corporation and others. - # All Rights Reserved. - # - # This software has been released under the terms of the IBM Public - # License. For details, see the LICENSE file in the top-level source - # directory or online at http://www.openafs.org/dl/license10.html - - VERSFILE=AFS_component_version_number - - $(VERSFILE).o: $(VERSFILE).c - - # mkvers checks timestamps - - $(VERSFILE).c: - $(TOP_SRCDIR)/config/mkvers -o $(VERSFILE).c - # only done for RX in NT - # -c $(CML_PREFIX) - - $(VERSFILE).h: - $(TOP_SRCDIR)/config/mkvers -o $(VERSFILE).h -v - - $(VERSFILE).txt: - $(TOP_SRCDIR)/config/mkvers -o $(VERSFILE).txt -t - - noversion: install --- 0 ---- Index: openafs/src/config/Makefile.version-CML.in diff -c /dev/null openafs/src/config/Makefile.version-CML.in:1.1.4.3 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/config/Makefile.version-CML.in Mon Jun 1 13:52:14 2009 *************** *** 0 **** --- 1,30 ---- + # Copyright 2000, International Business Machines Corporation and others. + # All Rights Reserved. + # + # This software has been released under the terms of the IBM Public + # License. For details, see the LICENSE file in the top-level source + # directory or online at http://www.openafs.org/dl/license10.html + + PACKAGE=@PACKAGE@ + VERSION=@VERSION@ + + AFS_component_version_number.o: AFS_component_version_number.c $(TOP_SRCDIR)/config/mkvers + version.xml version.txt: $(TOP_SRCDIR)/config/mkvers + + # mkvers checks timestamps + + AFS_component_version_number.c: + $(TOP_SRCDIR)/config/mkvers -o AFS_component_version_number.c + # only done for RX in NT + # -c $(CML_PREFIX) + + AFS_component_version_number.h: + $(TOP_SRCDIR)/config/mkvers -o AFS_component_version_number.h -v + + version.txt: + $(TOP_SRCDIR)/config/mkvers -o version.txt -t + + version.xml: + $(TOP_SRCDIR)/config/mkvers -o version.xml -x + + noversion: install Index: openafs/src/config/Makefile.version-NOCML.in diff -c openafs/src/config/Makefile.version-NOCML.in:1.5.2.1 openafs/src/config/Makefile.version-NOCML.in:1.5.2.4 *** openafs/src/config/Makefile.version-NOCML.in:1.5.2.1 Wed Oct 11 09:16:24 2006 --- openafs/src/config/Makefile.version-NOCML.in Mon Jun 1 13:52:14 2009 *************** *** 14,16 **** --- 14,24 ---- echo 'char cml_version_number[]="@(#) OpenAFS ${VERSION} built ' `date +"%Y-%m-%d"` '";' >AFS_component_version_number.c echo 'char* AFSVersion = "${PACKAGE} ${VERSION}"; ' >>AFS_component_version_number.c + version.xml: + echo '' >version.xml + echo '' >>version.xml + echo '${VERSION}' >>version.xml + echo '' >>version.xml + + version.txt: + echo "Base configuration unknown" > version.txt Index: openafs/src/config/afs_args.h diff -c openafs/src/config/afs_args.h:1.13.2.10 openafs/src/config/afs_args.h:1.13.2.11 *** openafs/src/config/afs_args.h:1.13.2.10 Thu Mar 19 22:32:59 2009 --- openafs/src/config/afs_args.h Sat May 30 13:56:42 2009 *************** *** 47,52 **** --- 47,53 ---- #define AFSOP_BASIC_INIT 36 /* used to be part of START_AFS */ #define AFSOP_SET_BACKUPTREE 37 /* enable backup tree support */ #define AFSOP_SET_RXPCK 38 /*set rx_extraPackets*/ + #define AFSOP_SET_RXMAXMTU 40 /* set rx_MyMaxSendSize,rx_maxReceiveSizeUser,rx_maxReceiveSize */ /* The range 20-30 is reserved for AFS system offsets in the afs_syscall */ #define AFSCALL_PIOCTL 20 Index: openafs/src/config/afs_sysnames.h diff -c openafs/src/config/afs_sysnames.h:1.50.2.34 openafs/src/config/afs_sysnames.h:1.50.2.36 *** openafs/src/config/afs_sysnames.h:1.50.2.34 Fri Mar 27 11:55:45 2009 --- openafs/src/config/afs_sysnames.h Tue May 12 09:03:49 2009 *************** *** 249,254 **** --- 249,255 ---- #define SYS_NAME_ID_i386_obsd42 2611 #define SYS_NAME_ID_i386_obsd43 2612 #define SYS_NAME_ID_i386_obsd44 2613 + #define SYS_NAME_ID_i386_obsd45 2614 #define SYS_NAME_ID_amd64_linux2 2700 #define SYS_NAME_ID_amd64_linux22 2701 *************** *** 279,284 **** --- 280,288 ---- #define SYS_NAME_ID_arm_linux24 3802 #define SYS_NAME_ID_arm_linux26 3803 + #define SYS_NAME_ID_i386_dfbsd_22 3900 + #define SYS_NAME_ID_i386_dfbsd_23 3901 + /* * Placeholder to keep system-wide standard flags since this file is included by all * files (i.e in afs/param.h) Index: openafs/src/config/debug.h diff -c openafs/src/config/debug.h:1.4 openafs/src/config/debug.h:1.4.2.1 *** openafs/src/config/debug.h:1.4 Tue Jul 15 19:14:55 2003 --- openafs/src/config/debug.h Mon Apr 27 15:17:40 2009 *************** *** 112,132 **** #if defined(AFS_DEBUG) #if defined(lint) ! #define dprintf(flag, str) printf str #define dlprintf(flag, level, str) printf str #define dmprintf(flag, bit, str) printf str #else /* lint */ ! #define dprintf(flag, str) \ (void)((flag) ? \ ( osi_dp str, osi_dp("\t%s, %d\n", __FILE__, __LINE__)):0) ! #define dlprintf(flag, level, str) dprintf(((flag) >= (level)), str) ! #define dmprintf(flag, bit, str) dprintf(((flag)&(1<<((bit)-1))), str) #endif /* lint */ #else /* AFS_DEBUG */ ! #define dprintf(flag, str) #define dlprintf(flag, level,str) #define dmprintf(flag, bit, str) --- 112,132 ---- #if defined(AFS_DEBUG) #if defined(lint) ! #define afs_dprintf(flag, str) printf str #define dlprintf(flag, level, str) printf str #define dmprintf(flag, bit, str) printf str #else /* lint */ ! #define afs_dprintf(flag, str) \ (void)((flag) ? \ ( osi_dp str, osi_dp("\t%s, %d\n", __FILE__, __LINE__)):0) ! #define dlprintf(flag, level, str) afs_dprintf(((flag) >= (level)), str) ! #define dmprintf(flag, bit, str) afs_dprintf(((flag)&(1<<((bit)-1))), str) #endif /* lint */ #else /* AFS_DEBUG */ ! #define afs_dprintf(flag, str) #define dlprintf(flag, level,str) #define dmprintf(flag, bit, str) Index: openafs/src/config/mkvers.c diff -c openafs/src/config/mkvers.c:1.11 openafs/src/config/mkvers.c:1.11.2.2 *** openafs/src/config/mkvers.c:1.11 Sun Dec 7 17:49:24 2003 --- openafs/src/config/mkvers.c Mon Jun 1 13:52:14 2009 *************** *** 58,64 **** enum { CF_DEFAULT, CF_VERINFO, ! CF_TEXT } cfgFormat = CF_DEFAULT; char *programName; --- 58,65 ---- enum { CF_DEFAULT, CF_VERINFO, ! CF_TEXT, ! CF_XML } cfgFormat = CF_DEFAULT; char *programName; *************** *** 69,75 **** Usage(void) { printf ! ("Usage: %s [-d directory] [-o output file name] [-c component] [-v | -t]\n", programName); printf("%s creates the AFS_component_version_number.c file.\n", programName); --- 70,76 ---- Usage(void) { printf ! ("Usage: %s [-d directory] [-o output file name] [-c component] [-v | -t | -x]\n", programName); printf("%s creates the AFS_component_version_number.c file.\n", programName); *************** *** 81,86 **** --- 82,88 ---- ("-c component - if not \"afs\" prefix for cml_version_number variable.\n"); printf("-v generate NT versioninfo style declarations.\n"); printf("-t generate text file style information.\n"); + printf("-x generate XML revision information.\n"); exit(1); } *************** *** 148,153 **** --- 150,162 ---- printf("Specify only one alternative output format\n"); Usage(); } + } else if (!strcmp("-x", argv[i])) { + if (cfgFormat == CF_DEFAULT || cfgFormat == CF_XML) { + cfgFormat = CF_XML; + } else { + printf("Specify only one alternative output format\n"); + Usage(); + } } else { printf("%s: Unknown argument.\n", argv[i]); Usage(); *************** *** 162,167 **** --- 171,178 ---- strcat(outputFileBuf, ".h"); } else if (cfgFormat == CF_TEXT) { strcat(outputFileBuf, ".txt"); + } else if (cfgFormat == CF_XML) { + strcat(outputFileBuf, ".xml"); } else { strcat(outputFileBuf, ".c"); } *************** *** 172,178 **** if ((code = stat(outputFile, &sbuf)) < 0) { reBuild = 1; ! versTime = (time_t) 0; /* inidicates no output file. */ } else { versTime = sbuf.st_mtime; } --- 183,189 ---- if ((code = stat(outputFile, &sbuf)) < 0) { reBuild = 1; ! versTime = (time_t) 0; /* indicates no output file. */ } else { versTime = sbuf.st_mtime; } *************** *** 289,294 **** --- 300,313 ---- } else if (cfgFormat == CF_TEXT) { fprintf(fpVers, "Base configuration %s\n", stateDeltas[i].name); + } else if (cfgFormat == CF_XML) { + fprintf(fpVers, + "\n" + "\n" + "\n" + "Base configuration %s\n" + "\n", + stateDeltas[i].name); } else { fprintf(fpVers, "%sBase configuration %s", cml_string, stateDeltas[i].name); *************** *** 307,312 **** --- 326,338 ---- if (cfgFormat == CF_TEXT) { fprintf(fpVers, "%c%s\n", stateDeltas[i].type, stateDeltas[i].name); + } else if (cfgFormat == CF_XML) { + fprintf(fpVers, + "\n" + ";%c%s" + "\n", + stateDeltas[i].type, + stateDeltas[i].name); } else { fprintf(fpVers, ";%c%s", stateDeltas[i].type, stateDeltas[i].name); *************** *** 323,328 **** --- 349,361 ---- if (cfgFormat == CF_TEXT) { fprintf(fpVers, "%c%s\n", stateDeltas[i].type, stateDeltas[i].name); + } else if (cfgFormat == CF_XML) { + fprintf(fpVers, + "\n" + ";%c%s" + "\n", + stateDeltas[i].type, + stateDeltas[i].name); } else { fprintf(fpVers, ";%c%s", stateDeltas[i].type, stateDeltas[i].name); *************** *** 345,349 **** --- 378,384 ---- if (s) *s = '\0'; fprintf(fpVers, "%s%s\";\n", AFS_STRING, c ? c : "Unknown"); + } else if (cfgFormat == CF_XML) { + fprintf(fpVers, "\n"); } } Index: openafs/src/config/param.i386_dfbsd_23.h diff -c /dev/null openafs/src/config/param.i386_dfbsd_23.h:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/config/param.i386_dfbsd_23.h Mon Apr 27 14:33:03 2009 *************** *** 0 **** --- 1,179 ---- + #ifndef AFS_PARAM_H + #define AFS_PARAM_H + + /* Machine / Operating system information */ + #define SYS_NAME "i386_dfbsd_23" + #define SYS_NAME_ID SYS_NAME_ID_i386_dfbsd_23 + + #define AFSLITTLE_ENDIAN 1 + #define AFS_HAVE_FFS 1 /* Use system's ffs. */ + #define AFS_HAVE_STATVFS 1 /* System doesn't support statvfs */ + #define AFS_VM_RDWR_ENV 1 /* read/write implemented via VM */ + + + #ifndef UKERNEL + /* This section for kernel libafs compiles only */ + + #ifndef IGNORE_STDS_H + #include + #endif + + #define AFS_XBSD_ENV 1 /* {Free,Open,Net}BSD */ + #define AFS_X86_XBSD_ENV 1 + + #define AFS_NAMEI_ENV 1 /* User space interface to file system */ + #define AFS_64BIT_ENV 1 + #define AFS_64BIT_CLIENT 1 + #define AFS_64BIT_IOPS_ENV 1 /* Needed for NAMEI */ + #define AFS_DFBSD_ENV 1 + #define AFS_DFBSD22_ENV 1 + #define AFS_DFBSD23_ENV 1 + #define AFS_X86_DFBSD_ENV 1 + #define AFS_X86_DFBSD22_ENV 1 + #define AFS_X86_DFBSD23_ENV 1 + #define AFS_X86_ENV 1 + #define AFS_NONFSTRANS 1 + #define FTRUNC O_TRUNC + + #define IUPD 0x0010 + #define IACC 0x0020 + #define ICHG 0x0040 + #define IMOD 0x0080 + + #define IN_LOCK(ip) lockmgr(&ip->i_lock, LK_EXCLUSIVE, \ + NULL, curproc) + #define IN_UNLOCK(ip) lockmgr(&ip->i_lock, LK_RELEASE, \ + NULL, curproc) + + #include + + #define AFS_VFS_ENV 1 + #define AFS_VFSINCL_ENV 1 + #define AFS_GREEDY43_ENV 1 + #define AFS_ENV 1 + + #define AFS_SYSCALL 339 + #define AFS_MOUNT_AFS "afs" + + #ifndef MOUNT_UFS + #define MOUNT_UFS "ufs" + #endif + + #ifndef MOUNT_AFS + #define MOUNT_AFS AFS_MOUNT_AFS + #endif + + #define RXK_LISTENER_ENV 1 + #define AFS_GCPAGS 0 /* if nonzero, garbage collect PAGs */ + #define AFS_USE_GETTIMEOFDAY 1 /* use gettimeofday to implement rx clock */ + + /* Extra kernel definitions (from kdefs file) */ + #ifdef _KERNEL + #define AFS_GLOBAL_SUNLOCK 1 + #define AFS_VFS34 1 /* What is VFS34??? */ + #define AFS_SHORTGID 0 /* are group id's short? */ + #define afsio_iov uio_iov + #define afsio_iovcnt uio_iovcnt + #define afsio_offset uio_offset + #define afsio_seg uio_segflg + #define afsio_resid uio_resid + #define AFS_UIOSYS UIO_SYSSPACE + #define AFS_UIOUSER UIO_USERSPACE + #define AFS_CLBYTES CLBYTES + #define osi_GetTime(x) microtime(x) + #define AFS_KALLOC(x) osi_fbsd_alloc((x), 1) + #undef AFS_KALLOC_NOSLEEP + #define AFS_KALLOC_NOSLEEP(x) osi_fbsd_alloc((x), 0) + #define AFS_KFREE(x,y) osi_fbsd_free((x)) + #define v_count v_usecount + #define v_vfsp v_mount + #define vfs_bsize mnt_stat.f_bsize + #define vfs_fsid mnt_stat.f_fsid + #define va_nodeid va_fileid + #define vfs_vnodecovered mnt_vnodecovered + #define direct dirent + #define vnode_t struct vnode + + #ifndef MUTEX_DEFAULT + #define MUTEX_DEFAULT 0 + #endif /* MUTEX_DEFAULT */ + + #ifndef SSYS + #define SSYS 0x00002 + #endif /* SSYS */ + + #define p_rcred p_ucred + + #if !defined(ASSEMBLER) && !defined(__LANGUAGE_ASSEMBLY__) + enum vcexcl { NONEXCL, EXCL }; + + #ifdef KERNEL + #ifndef MIN + #define MIN(A,B) ((A) < (B) ? (A) : (B)) + #endif + #ifndef MAX + #define MAX(A,B) ((A) > (B) ? (A) : (B)) + #endif + #endif /* KERNEL */ + + #endif /* ! ASSEMBLER & ! __LANGUAGE_ASSEMBLY__ */ + #endif /* _KERNEL */ + + #else /* !defined(UKERNEL) */ + + /* This section for user space compiles only */ + + #define UKERNEL 1 /* user space kernel */ + #define AFS_ENV 1 + #define AFS_VFSINCL_ENV 1 + #define AFS_USR_DFBSD22_ENV 1 + #define AFS_USR_DFBSD23_ENV 1 + #define AFS_USR_DFBSD_ENV 1 + #define AFS_NONFSTRANS 1 + + #define AFS_MOUNT_AFS "afs" /* The name of the filesystem type. */ + #define AFS_SYSCALL 339 + #define AFS_NAMEI_ENV 1 /* User space interface to file system */ + #define AFS_64BIT_ENV 1 + #define AFS_64BIT_IOPS_ENV 1 /* Needed for NAMEI */ + #define AFS_USERSPACE_IP_ADDR 1 + #define RXK_LISTENER_ENV 1 + #define AFS_GCPAGS 0 /* if nonzero, garbage collect PAGs */ + + #include + + #define afsio_iov uio_iov + #define afsio_iovcnt uio_iovcnt + #define afsio_offset uio_offset + #define afsio_seg uio_segflg + #define afsio_fmode uio_fmode + #define afsio_resid uio_resid + #define AFS_UIOSYS 1 + #define AFS_UIOUSER UIO_USERSPACE + #define AFS_CLBYTES MCLBYTES + #define AFS_MINCHANGE 2 + #define VATTR_NULL usr_vattr_null + + #define AFS_DIRENT + #ifndef CMSERVERPREF + #define CMSERVERPREF + #endif + + #include + #include + #include + #include + #include + #include + #include + #include + + #endif /* !defined(UKERNEL) */ + + /* general user-space compiles */ + + #if defined(UKERNEL) || !defined(KERNEL) + #define STDLIB_HAS_MALLOC_PROTOS 1 + #endif + + #endif /* AFS_PARAM_H */ Index: openafs/src/config/param.i386_obsd44.h diff -c /dev/null openafs/src/config/param.i386_obsd44.h:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/config/param.i386_obsd44.h Tue May 12 09:03:49 2009 *************** *** 0 **** --- 1,72 ---- + /* + * Jim Rees, University of Michigan CITI + */ + + #ifndef AFS_PARAM_H + #define AFS_PARAM_H + + #ifndef IGNORE_STDS_H + #include + #endif + + #define SYS_NAME "i386_obsd44" + #define SYS_NAME_ID SYS_NAME_ID_i386_obsd44 + + #define AFS_XBSD_ENV 1 /* {Free,Open,Net}BSD */ + #define AFS_X86_XBSD_ENV 1 + + #define AFS_NAMEI_ENV 1 /* User space interface to file system */ + #define AFS_64BIT_ENV 1 + #define AFS_64BIT_CLIENT 1 + #define AFS_64BIT_IOPS_ENV 1 /* Needed for NAMEI */ + #define AFS_OBSD_ENV 1 + #define AFS_OBSD34_ENV 1 + #define AFS_OBSD35_ENV 1 + #define AFS_OBSD36_ENV 1 + #define AFS_OBSD37_ENV 1 + #define AFS_OBSD38_ENV 1 + #define AFS_OBSD39_ENV 1 + #define AFS_OBSD40_ENV 1 + #define AFS_OBSD41_ENV 1 + #define AFS_OBSD42_ENV 1 + #define AFS_OBSD43_ENV 1 + #define AFS_OBSD44_ENV 1 + #define AFS_NONFSTRANS 1 + #define AFS_VM_RDWR_ENV 1 + #define AFS_VFS_ENV 1 + #define AFS_VFSINCL_ENV 1 + + #define FTRUNC O_TRUNC + + #define AFS_SYSCALL 208 + #define AFS_MOUNT_AFS "afs" + + #define RXK_LISTENER_ENV 1 + #define AFS_GCPAGS 0 /* if nonzero, garbage collect PAGs */ + #define AFS_USE_GETTIMEOFDAY 1 /* use gettimeofday to implement rx clock */ + + #define AFSLITTLE_ENDIAN 1 + + #ifndef IGNORE_STDS_H + #include + #endif + + /* Extra kernel definitions (from kdefs file) */ + #ifdef _KERNEL + #define AFS_GLOBAL_SUNLOCK 1 + #define AFS_SHORTGID 0 /* are group id's short? */ + + #if !defined(ASSEMBLER) && !defined(__LANGUAGE_ASSEMBLY__) + enum vcexcl { NONEXCL, EXCL }; + + #ifndef MIN + #define MIN(A,B) ((A) < (B) ? (A) : (B)) + #endif + #ifndef MAX + #define MAX(A,B) ((A) > (B) ? (A) : (B)) + #endif + + #endif /* ! ASSEMBLER & ! __LANGUAGE_ASSEMBLY__ */ + #endif /* _KERNEL */ + + #endif /* AFS_PARAM_H */ Index: openafs/src/config/param.i386_obsd45.h diff -c /dev/null openafs/src/config/param.i386_obsd45.h:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/config/param.i386_obsd45.h Wed May 27 09:27:01 2009 *************** *** 0 **** --- 1,73 ---- + /* + * Jim Rees, University of Michigan CITI + */ + + #ifndef AFS_PARAM_H + #define AFS_PARAM_H + + #ifndef IGNORE_STDS_H + #include + #endif + + #define SYS_NAME "i386_obsd45" + #define SYS_NAME_ID SYS_NAME_ID_i386_obsd45 + + #define AFS_XBSD_ENV 1 /* {Free,Open,Net}BSD */ + #define AFS_X86_XBSD_ENV 1 + + #define AFS_NAMEI_ENV 1 /* User space interface to file system */ + #define AFS_64BIT_ENV 1 + #define AFS_64BIT_CLIENT 1 + #define AFS_64BIT_IOPS_ENV 1 /* Needed for NAMEI */ + #define AFS_OBSD_ENV 1 + #define AFS_OBSD34_ENV 1 + #define AFS_OBSD35_ENV 1 + #define AFS_OBSD36_ENV 1 + #define AFS_OBSD37_ENV 1 + #define AFS_OBSD38_ENV 1 + #define AFS_OBSD39_ENV 1 + #define AFS_OBSD40_ENV 1 + #define AFS_OBSD41_ENV 1 + #define AFS_OBSD42_ENV 1 + #define AFS_OBSD43_ENV 1 + #define AFS_OBSD44_ENV 1 + #define AFS_OBSD45_ENV 1 + #define AFS_NONFSTRANS 1 + #define AFS_VM_RDWR_ENV 1 + #define AFS_VFS_ENV 1 + #define AFS_VFSINCL_ENV 1 + + #define FTRUNC O_TRUNC + + #define AFS_SYSCALL 208 + #define AFS_MOUNT_AFS "afs" + + #define RXK_LISTENER_ENV 1 + #define AFS_GCPAGS 0 /* if nonzero, garbage collect PAGs */ + #define AFS_USE_GETTIMEOFDAY 1 /* use gettimeofday to implement rx clock */ + + #define AFSLITTLE_ENDIAN 1 + + #ifndef IGNORE_STDS_H + #include + #endif + + /* Extra kernel definitions (from kdefs file) */ + #ifdef _KERNEL + #define AFS_GLOBAL_SUNLOCK 1 + #define AFS_SHORTGID 0 /* are group id's short? */ + + #if !defined(ASSEMBLER) && !defined(__LANGUAGE_ASSEMBLY__) + enum vcexcl { NONEXCL, EXCL }; + + #ifndef MIN + #define MIN(A,B) ((A) < (B) ? (A) : (B)) + #endif + #ifndef MAX + #define MAX(A,B) ((A) > (B) ? (A) : (B)) + #endif + + #endif /* ! ASSEMBLER & ! __LANGUAGE_ASSEMBLY__ */ + #endif /* _KERNEL */ + + #endif /* AFS_PARAM_H */ Index: openafs/src/config/venus.h diff -c openafs/src/config/venus.h:1.10.2.3 openafs/src/config/venus.h:1.10.2.5 *** openafs/src/config/venus.h:1.10.2.3 Mon Jan 19 13:09:32 2009 --- openafs/src/config/venus.h Wed Jun 3 01:42:00 2009 *************** *** 174,179 **** --- 174,180 ---- #define VIOC_SETRXKCRYPT _VICEIOCTL(56) /* Set rxkad enc flag */ #define VIOC_PREFETCHTAPE _VICEIOCTL(66) /* osd prefetch from tape */ #define VIOC_FS_CMD _VICEIOCTL(67) /* fs extensions for osd etc. */ + #define VIOC_RESIDENCY_CMD VIOC_FS_CMD #define VIOC_STATISTICS _VICEIOCTL(68) /* arla: fetch statistics */ #define VIOC_GETVCXSTATUS2 _VICEIOCTL(69) /* vcache statistics */ *************** *** 182,186 **** --- 183,188 ---- #define VIOC_GETALIAS _CVICEIOCTL(2) /* get alias info */ #define VIOC_CBADDR _CVICEIOCTL(3) /* push callback addr */ #define VIOC_NEWUUID _CVICEIOCTL(9) /* new uuid */ + #define VIOC_GETPAG _CVICEIOCTL(13) /* get pag value */ #endif /* AFS_VENUS_H */ Index: openafs/src/dir/dir.c diff -c openafs/src/dir/dir.c:1.21.2.7 openafs/src/dir/dir.c:1.21.2.8 *** openafs/src/dir/dir.c:1.21.2.7 Tue Oct 30 11:23:52 2007 --- openafs/src/dir/dir.c Wed Jun 3 16:36:35 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/dir/dir.c,v 1.21.2.7 2007/10/30 15:23:52 shadow Exp $"); #ifdef KERNEL #if !defined(UKERNEL) --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/dir/dir.c,v 1.21.2.8 2009/06/03 20:36:35 shadow Exp $"); #ifdef KERNEL #if !defined(UKERNEL) *************** *** 70,76 **** #include "afs/dir.h" - #include "afs/longc_procs.h" #ifdef AFS_LINUX20_ENV #include "h/string.h" #endif --- 70,75 ---- Index: openafs/src/fsint/afscbint.xg diff -c openafs/src/fsint/afscbint.xg:1.6 openafs/src/fsint/afscbint.xg:1.6.2.1 *** openafs/src/fsint/afscbint.xg:1.6 Tue Mar 4 11:19:48 2003 --- openafs/src/fsint/afscbint.xg Wed Jun 3 16:36:35 2009 *************** *** 15,24 **** #include "common.xg" /*Common structures & definitions*/ - %#ifdef KERNEL - %#include "../afs/longc_procs.h" - %#endif - package RXAFSCB_ prefix S statindex 6 --- 15,20 ---- Index: openafs/src/fsint/afsint.xg diff -c openafs/src/fsint/afsint.xg:1.13.2.3 openafs/src/fsint/afsint.xg:1.13.2.5 *** openafs/src/fsint/afsint.xg:1.13.2.3 Mon Jan 19 13:09:33 2009 --- openafs/src/fsint/afsint.xg Wed Jun 3 16:36:35 2009 *************** *** 290,299 **** %#define NoSalvage 0 %#define Salvage 1 - %#ifdef KERNEL - %#include "../afs/longc_procs.h" - %#endif - %#define MAXCMDINT64S 3 %#define MAXCMDINT32S 200 %#define MAXCMDCHARS 256 --- 290,295 ---- *************** *** 666,671 **** --- 662,674 ---- OUT struct FsCmdOutputs *Outputs ) = 220; + #ifdef RPC_CLIENT + %int RXAFS_ResidencyCmd(struct rx_connection *z_conn, AFSFid *Fid, struct FsCmdInputs *Inputs, struct FsCmdOutputs *Outputs) + %{ + % return RXAFS_FsCmd(z_conn, Fid, Inputs, Outputs); + %} + #endif + InlineBulkStatus( IN AFSCBFids *FidsArray, OUT AFSBulkStats *StatArray, Index: openafs/src/libafs/MakefileProto.DFBSD.in diff -c /dev/null openafs/src/libafs/MakefileProto.DFBSD.in:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/libafs/MakefileProto.DFBSD.in Mon Apr 27 14:33:03 2009 *************** *** 0 **** --- 1,103 ---- + # Copyright 2000, International Business Machines Corporation and others. + # All Rights Reserved. + # + # This software has been released under the terms of the IBM Public + # License. For details, see the LICENSE file in the top-level source + # directory or online at http://www.openafs.org/dl/license10.html + # + srcdir=@srcdir@ + include @TOP_OBJDIR@/src/config/Makefile.config + + + # OS specific object files: + AFS_OS_OBJS = \ + osi_groups.o \ + osi_file.o \ + osi_inode.o \ + osi_misc.o \ + osi_sleep.o \ + osi_vm.o \ + osi_vnodeops.o \ + osi_module.o + + #AFS_OS_NFSOBJS = \ + # osi_vfsops_nfs.o + + AFS_OS_NONFSOBJS = \ + osi_vfsops.o + + + # System specific build commands and flags + KSRC = @BSD_KERNEL_PATH@ + KBLD = @BSD_KERNEL_BUILD@ + + KDEFS=-Wall -nostdinc -I/usr/include -D_KERNEL -DKLD_MODULE \ + -elf + + DBUG = -O2 + DEFINES= -DAFSDEBUG -DKERNEL -DAFS -DVICE -DNFS -DUFS -DINET -DQUOTA -DGETMOUNT + CFLAGS=-I. -I.. -I${TOP_OBJDIR}/src/config ${FSINCLUDES} $(DEFINES) $(KDEFS) $(KOPTS) ${DBUG} + + + # Name of directory to hold object files and libraries. + KOBJ = MODLOAD + + # This tells Makefile.common to use it's single directory build target. + COMPDIRS = single_compdir + INSTDIRS = single_instdir + DESTDIRS = single_destdir + + #include Makefile.common + all: + echo "skipping" + + setup: + echo "skipping" + + # Below this line are targets when in the COMMON directory: + LIBAFS = libafsnfs.ko + LIBAFSNONFS = libafs.ko + + INST_LIBAFS = ${DESTDIR}${afskerneldir}/${LIBAFS} + INST_LIBAFSNONFS = ${DESTDIR}${afskerneldir}/${LIBAFSNONFS} + + DEST_LIBAFS = ${DEST}/root.client/bin/${LIBAFS} + DEST_LIBAFSNONFS = ${DEST}/root.client/bin/${LIBAFSNONFS} + + + # Without this line, gmake tries to build libafs + .PHONY: libafs + + # libafs: $(LIBAFS) $(LIBAFSNONFS) + libafs: $(LIBAFSNONFS) + # install_libafs: $(INST_LIBAFS) $(INST_LIBAFSNONFS) + install_libafs: $(INST_LIBAFSNONFS) + # dest_libafs: $(DEST_LIBAFS) $(DEST_LIBAFSNONFS) + dest_libafs: $(DEST_LIBAFSNONFS) + #libafs: + # echo WARNING: No kernel module for ${SYS_NAME} + + #install_libafs: + # echo WARNING: No kernel module for ${SYS_NAME} + + #dest_libafs: + # echo WARNING: No kernel module for ${SYS_NAME} + + + $(INST_LIBAFS): $(LIBAFS) + $(INSTALL) -f $? $@ + + $(INST_LIBAFSNONFS): $(LIBAFSNONFS) + $(INSTALL) -f $? $@ + + $(DEST_LIBAFS): $(LIBAFS) + $(INSTALL) -f $? $@ + + $(DEST_LIBAFSNONFS): $(LIBAFSNONFS) + $(INSTALL) -f $? $@ + + ${LIBAFS}: $(AFSAOBJS) $(AFSNFSOBJS) + echo "Skipping kernel module build" + + ${LIBAFSNONFS}: $(AFSAOBJS) $(AFSNONFSOBJS) + echo "Skipping kernel module build" Index: openafs/src/libuafs/MakefileProto.DFBSD.in diff -c /dev/null openafs/src/libuafs/MakefileProto.DFBSD.in:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/libuafs/MakefileProto.DFBSD.in Mon Apr 27 14:33:03 2009 *************** *** 0 **** --- 1,46 ---- + # Copyright 2000, International Business Machines Corporation and others. + # All Rights Reserved. + # + # This software has been released under the terms of the IBM Public + # License. For details, see the LICENSE file in the top-level source + # directory or online at http://www.openafs.org/dl/license10.html + # + srcdir=@srcdir@ + include @TOP_OBJDIR@/src/config/Makefile.config + + + # System specific build commands and flags + CC = @CC@ + DEFINES= -D_REENTRANT -DKERNEL -DUKERNEL + KOPTS= + CFLAGS=-I. -I.. -I${TOP_OBJDIR}/src/config ${FSINCLUDES} $(DEFINES) $(KOPTS) ${DBG} + OPTF=-O + # WEBOPTS = -I../nsapi -DNETSCAPE_NSAPI -DNET_SSL -DXP_UNIX -DMCC_HTTPD + + TEST_CFLAGS=-D_REENTRANT -DAFS_PTHREAD_ENV -DAFS_DFFBSD_ENV + TEST_LDFLAGS= + TEST_LIBS=-lpthread + + + LIBUAFS = libuafs.a + LIBJUAFS = libjuafs.a + LIBAFSWEB = nsafs.so + LIBAFSWEBKRB = nsafs.krb.so + + include Makefile.common + + $(LIBUAFS): $(UAFSOBJ) + -$(RM) -f $(LIBUAFS) + $(AR) $(ARFLAGS) $(LIBUAFS) $(UAFSOBJ) + + $(LIBJUAFS): $(JUAFSOBJ) + -$(RM) -f $(LIBJUAFS) + $(AR) $(ARFLAGS) $(LIBJUAFS) $(JUAFSOBJ) + + $(LIBAFSWEB): $(AFSWEBOBJ) ${DES}/libdes.a + -$(RM) -f $(LIBAFSWEB) + ld -b $(LIBAFSWEB) $(AFSWEBOBJ) ${DES}/libdes.a $(WEBLIBS) + + $(LIBAFSWEBKRB): $(AFSWEBOBJKRB) ${DES}/libdes.a + -$(RM) -f $(LIBAFSWEBKRB) + ld -b $(LIBAFSWEBKRB) $(AFSWEBOBJKRB) ${DES}/libdes.a $(WEBLIBS) Index: openafs/src/lwp/waitkey.c diff -c openafs/src/lwp/waitkey.c:1.13.2.1 openafs/src/lwp/waitkey.c:1.13.2.2 *** openafs/src/lwp/waitkey.c:1.13.2.1 Tue Oct 30 11:23:59 2007 --- openafs/src/lwp/waitkey.c Mon Apr 27 14:33:04 2009 *************** *** 23,29 **** #include RCSID ! ("$Header: /cvs/openafs/src/lwp/waitkey.c,v 1.13.2.1 2007/10/30 15:23:59 shadow Exp $"); #include #include --- 23,29 ---- #include RCSID ! ("$Header: /cvs/openafs/src/lwp/waitkey.c,v 1.13.2.2 2009/04/27 18:33:04 shadow Exp $"); #include #include *************** *** 166,173 **** --- 166,188 ---- return 1; #else #if defined(AFS_DARWIN_ENV) || defined(AFS_XBSD_ENV) + #if defined(AFS_DFBSD_ENV) + struct appx_sbuf { + unsigned char *_base; + int _size; + }; + struct APPX_FILE + { + struct __FILE_public pub; + struct appx_sbuf _bf; /* the buffer (at least 1 byte, if !NULL) */ + }; + struct APPX_FILE *appx_stdin = (struct APPX_FILE *) stdin; + if (appx_stdin->_bf._size > 0) + return 1; + #else if (stdin->_bf._size > 0) return 1; + #endif #else if (stdin->_cnt > 0) return 1; Index: openafs/src/packaging/RedHat/openafs-client.init diff -c openafs/src/packaging/RedHat/openafs-client.init:1.1.2.5 openafs/src/packaging/RedHat/openafs-client.init:1.1.2.6 *** openafs/src/packaging/RedHat/openafs-client.init:1.1.2.5 Thu Jan 24 19:00:18 2008 --- openafs/src/packaging/RedHat/openafs-client.init Tue May 12 12:58:53 2009 *************** *** 6,12 **** # description: OpenAFS is a distributed filesystem. # Should-Start: dkms # ! # $Revision: 1.1.2.5 $ [ -f /etc/init.d/functions ] && . /etc/init.d/functions [ -f /etc/sysconfig/openafs ] && . /etc/sysconfig/openafs --- 6,12 ---- # description: OpenAFS is a distributed filesystem. # Should-Start: dkms # ! # $Revision: 1.1.2.6 $ [ -f /etc/init.d/functions ] && . /etc/init.d/functions [ -f /etc/sysconfig/openafs ] && . /etc/sysconfig/openafs *************** *** 37,42 **** --- 37,43 ---- RETVAL=$? echo [ $RETVAL -eq 0 ] && touch /var/lock/subsys/openafs-client + [ $RETVAL -eq 0 ] && [ "$AFS_POST_INIT" ] && $AFS_POST_INIT return $RETVAL } Index: openafs/src/packaging/RedHat/openafs.spec.in diff -c openafs/src/packaging/RedHat/openafs.spec.in:1.1.2.29 openafs/src/packaging/RedHat/openafs.spec.in:1.1.2.30 *** openafs/src/packaging/RedHat/openafs.spec.in:1.1.2.29 Wed Mar 25 14:42:48 2009 --- openafs/src/packaging/RedHat/openafs.spec.in Wed Jun 3 01:42:00 2009 *************** *** 1,4 **** ! # Openafs Spec $Revision: 1.1.2.29 $ # TEMPORARY fix for patch fuzz so we can build on Fedora 10 %define _default_patch_fuzz 2 --- 1,4 ---- ! # Openafs Spec $Revision: 1.1.2.30 $ # TEMPORARY fix for patch fuzz so we can build on Fedora 10 %define _default_patch_fuzz 2 *************** *** 1149,1155 **** %{_bindir}/unlog %{_sbindir}/backup %{_sbindir}/butc - %{_sbindir}/copyauth %{_sbindir}/fms %{_sbindir}/fstrace %{_sbindir}/kas --- 1149,1154 ---- Index: openafs/src/pam/afs_auth.c diff -c openafs/src/pam/afs_auth.c:1.12.2.2 openafs/src/pam/afs_auth.c:1.12.2.3 *** openafs/src/pam/afs_auth.c:1.12.2.2 Tue Aug 26 10:12:23 2008 --- openafs/src/pam/afs_auth.c Mon Apr 27 14:33:04 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/pam/afs_auth.c,v 1.12.2.2 2008/08/26 14:12:23 shadow Exp $"); #include #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/pam/afs_auth.c,v 1.12.2.3 2009/04/27 18:33:04 shadow Exp $"); #include #include *************** *** 190,196 **** RET(PAM_AUTH_ERR); } #else ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #elif defined(_POSIX_PTHREAD_SEMANTICS) && defined(AFS_SUN5_ENV) getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf), &upwd); --- 190,196 ---- RET(PAM_AUTH_ERR); } #else ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_DFBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #elif defined(_POSIX_PTHREAD_SEMANTICS) && defined(AFS_SUN5_ENV) getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf), &upwd); Index: openafs/src/pam/afs_password.c diff -c openafs/src/pam/afs_password.c:1.10.2.1 openafs/src/pam/afs_password.c:1.10.2.2 *** openafs/src/pam/afs_password.c:1.10.2.1 Sun May 29 23:37:48 2005 --- openafs/src/pam/afs_password.c Mon Apr 27 14:33:04 2009 *************** *** 19,25 **** #include RCSID ! ("$Header: /cvs/openafs/src/pam/afs_password.c,v 1.10.2.1 2005/05/30 03:37:48 shadow Exp $"); #include #include --- 19,25 ---- #include RCSID ! ("$Header: /cvs/openafs/src/pam/afs_password.c,v 1.10.2.2 2009/04/27 18:33:04 shadow Exp $"); #include #include *************** *** 134,140 **** RET(PAM_AUTH_ERR); } #else ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #else upwd = getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf)); --- 134,140 ---- RET(PAM_AUTH_ERR); } #else ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_DFBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #else upwd = getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf)); Index: openafs/src/pam/afs_setcred.c diff -c openafs/src/pam/afs_setcred.c:1.13.2.2 openafs/src/pam/afs_setcred.c:1.13.2.3 *** openafs/src/pam/afs_setcred.c:1.13.2.2 Mon Dec 10 13:29:41 2007 --- openafs/src/pam/afs_setcred.c Mon Apr 27 14:33:04 2009 *************** *** 20,26 **** #include RCSID ! ("$Header: /cvs/openafs/src/pam/afs_setcred.c,v 1.13.2.2 2007/12/10 18:29:41 shadow Exp $"); #include #include --- 20,26 ---- #include RCSID ! ("$Header: /cvs/openafs/src/pam/afs_setcred.c,v 1.13.2.3 2009/04/27 18:33:04 shadow Exp $"); #include #include *************** *** 170,176 **** RET(PAM_AUTH_ERR); } #else ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #else upwd = getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf)); --- 170,176 ---- RET(PAM_AUTH_ERR); } #else ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_DFBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #else upwd = getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf)); Index: openafs/src/pam/afs_util.c diff -c openafs/src/pam/afs_util.c:1.12.2.7 openafs/src/pam/afs_util.c:1.12.2.8 *** openafs/src/pam/afs_util.c:1.12.2.7 Fri Mar 20 18:45:38 2009 --- openafs/src/pam/afs_util.c Wed Jun 3 01:42:01 2009 *************** *** 27,33 **** #endif RCSID ! ("$Header: /cvs/openafs/src/pam/afs_util.c,v 1.12.2.7 2009/03/20 22:45:38 shadow Exp $"); #include "afs_util.h" --- 27,33 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/pam/afs_util.c,v 1.12.2.8 2009/06/03 05:42:01 shadow Exp $"); #include "afs_util.h" *************** *** 176,224 **** return (ret); } - /* get the current AFS pag for the calling process */ - static afs_int32 - curpag(void) - { - #if defined(AFS_AIX51_ENV) - int code = getpagvalue("afs"); - if (code < 0 && errno == EINVAL) - code = 0; - return code; - #else - gid_t groups[NGROUPS_MAX]; - afs_uint32 g0, g1; - afs_uint32 h, l, ret; - - if (getgroups(sizeof groups / sizeof groups[0], groups) < 2) - return 0; - - g0 = groups[0] & 0xffff; - g1 = groups[1] & 0xffff; - g0 -= 0x3f00; - g1 -= 0x3f00; - if (g0 < 0xc000 && g1 < 0xc000) { - l = ((g0 & 0x3fff) << 14) | (g1 & 0x3fff); - h = (g0 >> 14); - h = (g1 >> 14) + h + h + h; - ret = ((h << 28) | l); - /* Additional testing */ - if (((ret >> 24) & 0xff) == 'A') - return ret; - else - return -1; - } - return -1; - #endif - } - /* Returns the AFS pag number, if any, otherwise return -1 */ afs_int32 getPAG(void) { afs_int32 pag; ! pag = curpag(); if (pag == 0 || pag == -1) return -1; --- 176,188 ---- return (ret); } /* Returns the AFS pag number, if any, otherwise return -1 */ afs_int32 getPAG(void) { afs_int32 pag; ! pag = ktc_curpag(); if (pag == 0 || pag == -1) return -1; Index: openafs/src/pam/test_pam.c diff -c openafs/src/pam/test_pam.c:1.7.2.1 openafs/src/pam/test_pam.c:1.7.2.2 *** openafs/src/pam/test_pam.c:1.7.2.1 Sun May 29 23:37:48 2005 --- openafs/src/pam/test_pam.c Mon Apr 27 14:33:04 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/pam/test_pam.c,v 1.7.2.1 2005/05/30 03:37:48 shadow Exp $"); #include #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/pam/test_pam.c,v 1.7.2.2 2009/04/27 18:33:04 shadow Exp $"); #include #include *************** *** 34,40 **** static const char *new_envstring = "GOTHEREVIATESTPAM=1"; static const char *new_homestring = "HOME=/tmp"; ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) #define getpassphrase getpass #endif --- 34,40 ---- static const char *new_envstring = "GOTHEREVIATESTPAM=1"; static const char *new_homestring = "HOME=/tmp"; ! #if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_DFBSD_ENV) || defined(AFS_NBSD_ENV) #define getpassphrase getpass #endif Index: openafs/src/platform/DFBSD/Makefile.in diff -c /dev/null openafs/src/platform/DFBSD/Makefile.in:1.1.4.2 *** /dev/null Thu Jun 11 11:13:07 2009 --- openafs/src/platform/DFBSD/Makefile.in Mon Apr 27 14:33:04 2009 *************** *** 0 **** --- 1,14 ---- + # Copyright 2000, International Business Machines Corporation and others. + # All Rights Reserved. + # + # This software has been released under the terms of the IBM Public + # License. For details, see the LICENSE file in the top-level source + # directory or online at http://www.openafs.org/dl/license10.html + + SHELL=/bin/sh + + # We have no platform-specific stuff for this platform (yet). + all: + install: + dest: + clean: Index: openafs/src/ptserver/ptprocs.c diff -c openafs/src/ptserver/ptprocs.c:1.21.2.10 openafs/src/ptserver/ptprocs.c:1.21.2.12 *** openafs/src/ptserver/ptprocs.c:1.21.2.10 Wed Mar 18 23:45:02 2009 --- openafs/src/ptserver/ptprocs.c Wed Jun 3 17:49:17 2009 *************** *** 51,57 **** #include RCSID ! ("$Header: /cvs/openafs/src/ptserver/ptprocs.c,v 1.21.2.10 2009/03/19 03:45:02 shadow Exp $"); #include #include --- 51,57 ---- #include RCSID ! ("$Header: /cvs/openafs/src/ptserver/ptprocs.c,v 1.21.2.12 2009/06/03 21:49:17 shadow Exp $"); #include #include *************** *** 215,221 **** code = iNewEntry(call, aname, aid, oid, &cid); osi_auditU(call, PTS_INewEntEvent, code, AUD_ID, aid, AUD_STR, aname, AUD_ID, oid, AUD_END); ! ViceLog(25, ("PTS_INewEntry: code %d cid %d aid %d aname %s oid %d", code, cid, aid, aname, oid)); return code; } --- 215,221 ---- code = iNewEntry(call, aname, aid, oid, &cid); osi_auditU(call, PTS_INewEntEvent, code, AUD_ID, aid, AUD_STR, aname, AUD_ID, oid, AUD_END); ! ViceLog(5, ("PTS_INewEntry: code %d cid %d aid %d aname %s oid %d\n", code, cid, aid, aname, oid)); return code; } *************** *** 295,301 **** code = newEntry(call, aname, flag, oid, aid, &cid); osi_auditU(call, PTS_NewEntEvent, code, AUD_ID, *aid, AUD_STR, aname, AUD_ID, oid, AUD_END); ! ViceLog(25, ("PTS_NewEntry: code %d cid %d aid %d aname %s oid %d", code, cid, *aid, aname, oid)); return code; } --- 295,301 ---- code = newEntry(call, aname, flag, oid, aid, &cid); osi_auditU(call, PTS_NewEntEvent, code, AUD_ID, *aid, AUD_STR, aname, AUD_ID, oid, AUD_END); ! ViceLog(5, ("PTS_NewEntry: code %d cid %d aid %d aname %s oid %d\n", code, cid, *aid, aname, oid)); return code; } *************** *** 367,373 **** code = whereIsIt(call, aid, apos, &cid); osi_auditU(call, PTS_WheIsItEvent, code, AUD_ID, aid, AUD_LONG, *apos, AUD_END); ! ViceLog(125, ("PTS_WhereIsIt: code %d cid %d aid %d apos %d", code, cid, aid, *apos)); return code; } --- 367,373 ---- code = whereIsIt(call, aid, apos, &cid); osi_auditU(call, PTS_WheIsItEvent, code, AUD_ID, aid, AUD_LONG, *apos, AUD_END); ! ViceLog(125, ("PTS_WhereIsIt: code %d cid %d aid %d apos %d\n", code, cid, aid, *apos)); return code; } *************** *** 421,427 **** code = dumpEntry(call, apos, aentry, &cid); osi_auditU(call, PTS_DmpEntEvent, code, AUD_LONG, apos, AUD_END); ! ViceLog(125, ("PTS_DumpEntry: code %d cid %d apos %d", code, cid, apos)); return code; } --- 421,427 ---- code = dumpEntry(call, apos, aentry, &cid); osi_auditU(call, PTS_DmpEntEvent, code, AUD_LONG, apos, AUD_END); ! ViceLog(125, ("PTS_DumpEntry: code %d cid %d apos %d\n", code, cid, apos)); return code; } *************** *** 485,491 **** code = addToGroup(call, aid, gid, &cid); osi_auditU(call, PTS_AdToGrpEvent, code, AUD_ID, gid, AUD_ID, aid, AUD_END); ! ViceLog(5, ("PTS_AddToGroup: code %d cid %d gid %d aid %d", code, cid, gid, aid)); return code; } --- 485,491 ---- code = addToGroup(call, aid, gid, &cid); osi_auditU(call, PTS_AdToGrpEvent, code, AUD_ID, gid, AUD_ID, aid, AUD_END); ! ViceLog(5, ("PTS_AddToGroup: code %d cid %d gid %d aid %d\n", code, cid, gid, aid)); return code; } *************** *** 578,584 **** code = nameToID(call, aname, aid); osi_auditU(call, PTS_NmToIdEvent, code, AUD_END); ! ViceLog(125, ("PTS_NameToID: code %d", code)); return code; } --- 578,584 ---- code = nameToID(call, aname, aid); osi_auditU(call, PTS_NmToIdEvent, code, AUD_END); ! ViceLog(125, ("PTS_NameToID: code %d\n", code)); return code; } *************** *** 645,651 **** osi_audit(PTS_NmToIdEvent, code, AUD_STR, aname->namelist_val[i], AUD_ID, aid->idlist_val[i], AUD_END); ! ViceLog(125, ("PTS_NameToID: code %d aname %s aid %d", code, aname->namelist_val[i], aid->idlist_val[i])); if (count++ > 50) IOMGR_Poll(), count = 0; --- 645,651 ---- osi_audit(PTS_NmToIdEvent, code, AUD_STR, aname->namelist_val[i], AUD_ID, aid->idlist_val[i], AUD_END); ! ViceLog(125, ("PTS_NameToID: code %d aname %s aid %d\n", code, aname->namelist_val[i], aid->idlist_val[i])); if (count++ > 50) IOMGR_Poll(), count = 0; *************** *** 673,679 **** code = idToName(call, aid, aname); osi_auditU(call, PTS_IdToNmEvent, code, AUD_END); ! ViceLog(125, ("PTS_IDToName: code %d", code)); return code; } --- 673,679 ---- code = idToName(call, aid, aname); osi_auditU(call, PTS_IdToNmEvent, code, AUD_END); ! ViceLog(125, ("PTS_IDToName: code %d\n", code)); return code; } *************** *** 723,729 **** sprintf(aname->namelist_val[i], "%d", aid->idlist_val[i]); osi_audit(PTS_IdToNmEvent, code, AUD_ID, aid->idlist_val[i], AUD_STR, aname->namelist_val[i], AUD_END); ! ViceLog(125, ("PTS_idToName: code %d aid %d aname %s", code, aid->idlist_val[i], aname->namelist_val[i])); if (count++ > 50) IOMGR_Poll(), count = 0; --- 723,729 ---- sprintf(aname->namelist_val[i], "%d", aid->idlist_val[i]); osi_audit(PTS_IdToNmEvent, code, AUD_ID, aid->idlist_val[i], AUD_STR, aname->namelist_val[i], AUD_END); ! ViceLog(125, ("PTS_idToName: code %d aid %d aname %s\n", code, aid->idlist_val[i], aname->namelist_val[i])); if (count++ > 50) IOMGR_Poll(), count = 0; *************** *** 746,752 **** code = Delete(call, aid, &cid); osi_auditU(call, PTS_DelEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(25, ("PTS_Delete: code %d cid %d aid %d", code, cid, aid)); return code; } --- 746,752 ---- code = Delete(call, aid, &cid); osi_auditU(call, PTS_DelEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(5, ("PTS_Delete: code %d cid %d aid %d\n", code, cid, aid)); return code; } *************** *** 988,994 **** code = UpdateEntry(call, aid, name, uentry, &cid); osi_auditU(call, PTS_UpdEntEvent, code, AUD_ID, aid, AUD_STR, name, AUD_END); ! ViceLog(5, ("PTS_UpdateEntry: code %d cid %d aid %d name %s", code, cid, aid, name)); return code; } --- 988,994 ---- code = UpdateEntry(call, aid, name, uentry, &cid); osi_auditU(call, PTS_UpdEntEvent, code, AUD_ID, aid, AUD_STR, name, AUD_END); ! ViceLog(5, ("PTS_UpdateEntry: code %d cid %d aid %d name %s\n", code, cid, aid, name)); return code; } *************** *** 1086,1092 **** code = removeFromGroup(call, aid, gid, &cid); osi_auditU(call, PTS_RmFmGrpEvent, code, AUD_ID, gid, AUD_ID, aid, AUD_END); ! ViceLog(5, ("PTS_RemoveFromGroup: code %d cid %d gid %d aid %d", code, cid, gid, aid)); return code; } --- 1086,1092 ---- code = removeFromGroup(call, aid, gid, &cid); osi_auditU(call, PTS_RmFmGrpEvent, code, AUD_ID, gid, AUD_ID, aid, AUD_END); ! ViceLog(5, ("PTS_RemoveFromGroup: code %d cid %d gid %d aid %d\n", code, cid, gid, aid)); return code; } *************** *** 1175,1181 **** code = getCPS(call, aid, alist, over, &cid); osi_auditU(call, PTS_GetCPSEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_GetCPS: code %d cid %d aid %d", code, cid, aid)); return code; } --- 1175,1181 ---- code = getCPS(call, aid, alist, over, &cid); osi_auditU(call, PTS_GetCPSEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_GetCPS: code %d cid %d aid %d\n", code, cid, aid)); return code; } *************** *** 1260,1266 **** code = getCPS2(call, aid, ahost, alist, over, &cid); osi_auditU(call, PTS_GetCPS2Event, code, AUD_ID, aid, AUD_HOST, ahost, AUD_END); ! ViceLog(125, ("PTS_GetCPS2: code %d cid %d aid %d ahost %d", code, cid, aid, ahost)); return code; } --- 1260,1266 ---- code = getCPS2(call, aid, ahost, alist, over, &cid); osi_auditU(call, PTS_GetCPS2Event, code, AUD_ID, aid, AUD_HOST, ahost, AUD_END); ! ViceLog(125, ("PTS_GetCPS2: code %d cid %d aid %d ahost %d\n", code, cid, aid, ahost)); return code; } *************** *** 1355,1361 **** code = getHostCPS(call, ahost, alist, over); osi_auditU(call, PTS_GetHCPSEvent, code, AUD_HOST, ahost, AUD_END); ! ViceLog(125, ("PTS_GetHostCPS: code %d ahost %d", code, ahost)); return code; } --- 1355,1361 ---- code = getHostCPS(call, ahost, alist, over); osi_auditU(call, PTS_GetHCPSEvent, code, AUD_HOST, ahost, AUD_END); ! ViceLog(125, ("PTS_GetHostCPS: code %d ahost %d\n", code, ahost)); return code; } *************** *** 1428,1434 **** code = listMax(call, uid, gid); osi_auditU(call, PTS_LstMaxEvent, code, AUD_END); ! ViceLog(125, ("PTS_ListMax: code %d", code)); return code; } --- 1428,1434 ---- code = listMax(call, uid, gid); osi_auditU(call, PTS_LstMaxEvent, code, AUD_END); ! ViceLog(125, ("PTS_ListMax: code %d\n", code)); return code; } *************** *** 1476,1482 **** code = setMax(call, aid, gflag, &cid); osi_auditU(call, PTS_SetMaxEvent, code, AUD_ID, aid, AUD_LONG, gflag, AUD_END); ! ViceLog(125, ("PTS_SetMax: code %d cid %d aid %d gflag %d", code, cid, aid, gflag)); return code; } --- 1476,1482 ---- code = setMax(call, aid, gflag, &cid); osi_auditU(call, PTS_SetMaxEvent, code, AUD_ID, aid, AUD_LONG, gflag, AUD_END); ! ViceLog(125, ("PTS_SetMax: code %d cid %d aid %d gflag %d\n", code, cid, aid, gflag)); return code; } *************** *** 1532,1538 **** code = listEntry(call, aid, aentry, &cid); osi_auditU(call, PTS_LstEntEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListEntry: code %d cid %d aid %d", code, cid, aid)); return code; } --- 1532,1538 ---- code = listEntry(call, aid, aentry, &cid); osi_auditU(call, PTS_LstEntEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListEntry: code %d cid %d aid %d\n", code, cid, aid)); return code; } *************** *** 1607,1613 **** code = listEntries(call, flag, startindex, bulkentries, nextstartindex, &cid); osi_auditU(call, PTS_LstEntsEvent, code, AUD_LONG, flag, AUD_END); ! ViceLog(125, ("PTS_ListEntries: code %d cid %d flag %d", code, cid, flag)); return code; } --- 1607,1613 ---- code = listEntries(call, flag, startindex, bulkentries, nextstartindex, &cid); osi_auditU(call, PTS_LstEntsEvent, code, AUD_LONG, flag, AUD_END); ! ViceLog(125, ("PTS_ListEntries: code %d cid %d flag %d\n", code, cid, flag)); return code; } *************** *** 1753,1759 **** code = changeEntry(call, aid, name, oid, newid, &cid); osi_auditU(call, PTS_ChgEntEvent, code, AUD_ID, aid, AUD_STR, name, AUD_LONG, oid, AUD_LONG, newid, AUD_END); ! ViceLog(5, ("PTS_ChangeEntry: code %d cid %d aid %d name %s oid %d newid %d", code, cid, aid, name, oid, newid)); return code; } --- 1753,1759 ---- code = changeEntry(call, aid, name, oid, newid, &cid); osi_auditU(call, PTS_ChgEntEvent, code, AUD_ID, aid, AUD_STR, name, AUD_LONG, oid, AUD_LONG, newid, AUD_END); ! ViceLog(5, ("PTS_ChangeEntry: code %d cid %d aid %d name %s oid %d newid %d\n", code, cid, aid, name, oid, newid)); return code; } *************** *** 1822,1828 **** setFieldsEntry(call, id, mask, flags, ngroups, nusers, spare1, spare2, &cid); osi_auditU(call, PTS_SetFldEntEvent, code, AUD_ID, id, AUD_END); ! ViceLog(5, ("PTS_SetFieldsEntry: code %d cid %d id %d", code, cid, id)); return code; } --- 1822,1828 ---- setFieldsEntry(call, id, mask, flags, ngroups, nusers, spare1, spare2, &cid); osi_auditU(call, PTS_SetFldEntEvent, code, AUD_ID, id, AUD_END); ! ViceLog(5, ("PTS_SetFieldsEntry: code %d cid %d id %d\n", code, cid, id)); return code; } *************** *** 1924,1930 **** code = listElements(call, aid, alist, over, &cid); osi_auditU(call, PTS_LstEleEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListElements: code %d cid %d aid %d", code, cid, aid)); return code; } --- 1924,1930 ---- code = listElements(call, aid, alist, over, &cid); osi_auditU(call, PTS_LstEleEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListElements: code %d cid %d aid %d\n", code, cid, aid)); return code; } *************** *** 1993,1999 **** code = listSuperGroups(call, aid, alist, over, &cid); osi_auditU(call, PTS_LstSGrps, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListSuperGroups: code %d cid %d aid %d", code, cid, aid)); return code; #else return RXGEN_OPCODE; --- 1993,1999 ---- code = listSuperGroups(call, aid, alist, over, &cid); osi_auditU(call, PTS_LstSGrps, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListSuperGroups: code %d cid %d aid %d\n", code, cid, aid)); return code; #else return RXGEN_OPCODE; *************** *** 2073,2079 **** code = listOwned(call, aid, alist, lastP, &cid); osi_auditU(call, PTS_LstOwnEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListOwned: code %d cid %d aid %d", code, cid, aid)); return code; } --- 2073,2079 ---- code = listOwned(call, aid, alist, lastP, &cid); osi_auditU(call, PTS_LstOwnEvent, code, AUD_ID, aid, AUD_END); ! ViceLog(125, ("PTS_ListOwned: code %d cid %d aid %d\n", code, cid, aid)); return code; } *************** *** 2166,2172 **** code = isAMemberOf(call, uid, gid, flag, &cid); osi_auditU(call, PTS_IsMemOfEvent, code, AUD_LONG, uid, AUD_LONG, gid, AUD_END); ! ViceLog(125, ("PTS_IsAMemberOf: code %d cid %d uid %d gid %d", code, cid, uid, gid)); return code; } --- 2166,2172 ---- code = isAMemberOf(call, uid, gid, flag, &cid); osi_auditU(call, PTS_IsMemOfEvent, code, AUD_LONG, uid, AUD_LONG, gid, AUD_END); ! ViceLog(125, ("PTS_IsAMemberOf: code %d cid %d uid %d gid %d\n", code, cid, uid, gid)); return code; } Index: openafs/src/ptserver/pts.c diff -c openafs/src/ptserver/pts.c:1.13.2.7 openafs/src/ptserver/pts.c:1.13.2.8 *** openafs/src/ptserver/pts.c:1.13.2.7 Tue Mar 18 11:59:07 2008 --- openafs/src/ptserver/pts.c Tue May 12 15:40:57 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/ptserver/pts.c,v 1.13.2.7 2008/03/18 15:59:07 shadow Exp $"); #include #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/ptserver/pts.c,v 1.13.2.8 2009/05/12 19:40:57 shadow Exp $"); #include #include *************** *** 176,181 **** --- 176,185 ---- changed = 1; sec = 1; } + if (as->parms[22].items) { /* -encrypt */ + changed = 1; + sec = 3; + } if (as->parms[18].items || as->parms[20].items) { /* -test, -localauth */ changed = 1; confdir = AFSDIR_SERVER_ETC_DIRPATH; *************** *** 1022,1027 **** --- 1026,1033 ---- "use local authentication"); cmd_AddParm(ts, "-auth", CMD_FLAG, CMD_OPTIONAL, "use user's authentication (default)"); + cmd_AddParm(ts, "-encrypt", CMD_FLAG, CMD_OPTIONAL, + "encrypt commands"); } /* Index: openafs/src/ptserver/ptserver.c diff -c openafs/src/ptserver/ptserver.c:1.21.2.14 openafs/src/ptserver/ptserver.c:1.21.2.15 *** openafs/src/ptserver/ptserver.c:1.21.2.14 Mon Dec 22 14:23:32 2008 --- openafs/src/ptserver/ptserver.c Wed Jun 3 18:12:02 2009 *************** *** 113,119 **** #include RCSID ! ("$Header: /cvs/openafs/src/ptserver/ptserver.c,v 1.21.2.14 2008/12/22 19:23:32 shadow Exp $"); #include #ifdef AFS_AIX32_ENV --- 113,119 ---- #include RCSID ! ("$Header: /cvs/openafs/src/ptserver/ptserver.c,v 1.21.2.15 2009/06/03 22:12:02 shadow Exp $"); #include #ifdef AFS_AIX32_ENV *************** *** 279,294 **** int alen; lcstring(arg, argv[a], sizeof(arg)); alen = strlen(arg); ! if ((strncmp(arg, "-database", alen) == 0) ! || (strncmp(arg, "-db", alen) == 0)) { ! pr_dbaseName = argv[++a]; /* specify a database */ ! } else if (strcmp(argv[a], "-d") == 0) { if ((a + 1) >= argc) { fprintf(stderr, "missing argument for -d\n"); return -1; } debuglevel = atoi(argv[++a]); LogLevel = debuglevel; } else if (strncmp(arg, "-p", alen) == 0) { lwps = atoi(argv[++a]); if (lwps > 16) { /* maximum of 16 */ --- 279,294 ---- int alen; lcstring(arg, argv[a], sizeof(arg)); alen = strlen(arg); ! if (strcmp(argv[a], "-d") == 0) { if ((a + 1) >= argc) { fprintf(stderr, "missing argument for -d\n"); return -1; } debuglevel = atoi(argv[++a]); LogLevel = debuglevel; + } else if ((strncmp(arg, "-database", alen) == 0) + || (strncmp(arg, "-db", alen) == 0)) { + pr_dbaseName = argv[++a]; /* specify a database */ } else if (strncmp(arg, "-p", alen) == 0) { lwps = atoi(argv[++a]); if (lwps > 16) { /* maximum of 16 */ Index: openafs/src/ptserver/ptuser.c diff -c openafs/src/ptserver/ptuser.c:1.16.2.17 openafs/src/ptserver/ptuser.c:1.16.2.18 *** openafs/src/ptserver/ptuser.c:1.16.2.17 Mon Feb 4 12:53:56 2008 --- openafs/src/ptserver/ptuser.c Tue May 12 15:40:57 2009 *************** *** 15,21 **** #endif RCSID ! ("$Header: /cvs/openafs/src/ptserver/ptuser.c,v 1.16.2.17 2008/02/04 17:53:56 shadow Exp $"); #if defined(UKERNEL) #include "afs/sysincludes.h" --- 15,21 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/ptserver/ptuser.c,v 1.16.2.18 2009/05/12 19:40:57 shadow Exp $"); #if defined(UKERNEL) #include "afs/sysincludes.h" *************** *** 203,208 **** --- 203,210 ---- code = ktc_GetToken(&sname, &ttoken, sizeof(ttoken), NULL); if (code) { afs_com_err(whoami, code, "(getting token)"); + if (secLevel > 1) + return code; scIndex = 0; } else { if (ttoken.kvno >= 0 && ttoken.kvno <= 256) *************** *** 215,221 **** scIndex = 2; } sc[2] = ! rxkad_NewClientSecurityObject(rxkad_clear, &ttoken.sessionKey, ttoken.kvno, ttoken.ticketLen, ttoken.ticket); } --- 217,224 ---- scIndex = 2; } sc[2] = ! rxkad_NewClientSecurityObject((secLevel > 1) ? rxkad_crypt : ! rxkad_clear, &ttoken.sessionKey, ttoken.kvno, ttoken.ticketLen, ttoken.ticket); } Index: openafs/src/rx/rx.c diff -c openafs/src/rx/rx.c:1.58.2.55 openafs/src/rx/rx.c:1.58.2.56 *** openafs/src/rx/rx.c:1.58.2.55 Sat Mar 7 09:11:01 2009 --- openafs/src/rx/rx.c Tue May 12 13:12:41 2009 *************** *** 17,23 **** #endif RCSID ! ("$Header: /cvs/openafs/src/rx/rx.c,v 1.58.2.55 2009/03/07 14:11:01 shadow Exp $"); #ifdef KERNEL #include "afs/sysincludes.h" --- 17,23 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/rx/rx.c,v 1.58.2.56 2009/05/12 17:12:41 shadow Exp $"); #ifdef KERNEL #include "afs/sysincludes.h" *************** *** 6153,6201 **** s->packetRequests); if (version >= RX_DEBUGI_VERSION_W_NEWPACKETTYPES) { ! fprintf(file, "alloc-failures(rcv %d/%d,send %d/%d,ack %d)\n", s->receivePktAllocFailures, s->receiveCbufPktAllocFailures, s->sendPktAllocFailures, s->sendCbufPktAllocFailures, s->specialPktAllocFailures); } else { ! fprintf(file, "alloc-failures(rcv %d,send %d,ack %d)\n", s->receivePktAllocFailures, s->sendPktAllocFailures, s->specialPktAllocFailures); } fprintf(file, ! " greedy %d, " "bogusReads %d (last from host %x), " ! "noPackets %d, " "noBuffers %d, " "selects %d, " ! "sendSelects %d\n", s->socketGreedy, s->bogusPacketOnRead, s->bogusHost, s->noPacketOnRead, s->noPacketBuffersOnRead, s->selects, s->sendSelects); fprintf(file, " packets read: "); for (i = 0; i < RX_N_PACKET_TYPES; i++) { ! fprintf(file, "%s %d ", rx_packetTypes[i], s->packetsRead[i]); } fprintf(file, "\n"); fprintf(file, ! " other read counters: data %d, " "ack %d, " "dup %d " ! "spurious %d " "dally %d\n", s->dataPacketsRead, s->ackPacketsRead, s->dupPacketsRead, s->spuriousPacketsRead, s->ignorePacketDally); fprintf(file, " packets sent: "); for (i = 0; i < RX_N_PACKET_TYPES; i++) { ! fprintf(file, "%s %d ", rx_packetTypes[i], s->packetsSent[i]); } fprintf(file, "\n"); fprintf(file, ! " other send counters: ack %d, " "data %d (not resends), " ! "resends %d, " "pushed %d, " "acked&ignored %d\n", s->ackPacketsSent, s->dataPacketsSent, s->dataPacketsReSent, s->dataPacketsPushed, s->ignoreAckedPacket); fprintf(file, ! " \t(these should be small) sendFailed %d, " "fatalErrors %d\n", s->netSendFailures, (int)s->fatalErrors); if (s->nRttSamples) { --- 6153,6201 ---- s->packetRequests); if (version >= RX_DEBUGI_VERSION_W_NEWPACKETTYPES) { ! fprintf(file, "alloc-failures(rcv %u/%u,send %u/%u,ack %u)\n", s->receivePktAllocFailures, s->receiveCbufPktAllocFailures, s->sendPktAllocFailures, s->sendCbufPktAllocFailures, s->specialPktAllocFailures); } else { ! fprintf(file, "alloc-failures(rcv %u,send %u,ack %u)\n", s->receivePktAllocFailures, s->sendPktAllocFailures, s->specialPktAllocFailures); } fprintf(file, ! " greedy %u, " "bogusReads %u (last from host %x), " ! "noPackets %u, " "noBuffers %u, " "selects %u, " ! "sendSelects %u\n", s->socketGreedy, s->bogusPacketOnRead, s->bogusHost, s->noPacketOnRead, s->noPacketBuffersOnRead, s->selects, s->sendSelects); fprintf(file, " packets read: "); for (i = 0; i < RX_N_PACKET_TYPES; i++) { ! fprintf(file, "%s %u ", rx_packetTypes[i], s->packetsRead[i]); } fprintf(file, "\n"); fprintf(file, ! " other read counters: data %u, " "ack %u, " "dup %u " ! "spurious %u " "dally %u\n", s->dataPacketsRead, s->ackPacketsRead, s->dupPacketsRead, s->spuriousPacketsRead, s->ignorePacketDally); fprintf(file, " packets sent: "); for (i = 0; i < RX_N_PACKET_TYPES; i++) { ! fprintf(file, "%s %u ", rx_packetTypes[i], s->packetsSent[i]); } fprintf(file, "\n"); fprintf(file, ! " other send counters: ack %u, " "data %u (not resends), " ! "resends %u, " "pushed %u, " "acked&ignored %u\n", s->ackPacketsSent, s->dataPacketsSent, s->dataPacketsReSent, s->dataPacketsPushed, s->ignoreAckedPacket); fprintf(file, ! " \t(these should be small) sendFailed %u, " "fatalErrors %u\n", s->netSendFailures, (int)s->fatalErrors); if (s->nRttSamples) { Index: openafs/src/rx/rx_getaddr.c diff -c openafs/src/rx/rx_getaddr.c:1.15.2.13 openafs/src/rx/rx_getaddr.c:1.15.2.14 *** openafs/src/rx/rx_getaddr.c:1.15.2.13 Wed Oct 11 07:29:02 2006 --- openafs/src/rx/rx_getaddr.c Mon Apr 27 14:33:04 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/rx/rx_getaddr.c,v 1.15.2.13 2006/10/11 11:29:02 jaltman Exp $"); #ifndef AFS_DJGPP_ENV #ifndef KERNEL --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/rx/rx_getaddr.c,v 1.15.2.14 2009/04/27 18:33:04 shadow Exp $"); #ifndef AFS_DJGPP_ENV #ifndef KERNEL *************** *** 45,50 **** --- 45,55 ---- #define NIFS 512 + #if defined(AFS_USR_DFBSD_ENV) + #include + #include + #endif + #ifdef KERNEL /* only used for generating random noise */ *************** *** 328,334 **** /* this function returns the total number of interface addresses ** the buffer has to be passed in by the caller */ ! #else static int rx_getAllAddr_internal(afs_int32 buffer[], int maxSize, int loopbacks) { --- 333,339 ---- /* this function returns the total number of interface addresses ** the buffer has to be passed in by the caller */ ! #else /* UKERNEL indirectly, on DARWIN or XBSD */ static int rx_getAllAddr_internal(afs_int32 buffer[], int maxSize, int loopbacks) { *************** *** 337,342 **** --- 342,348 ---- struct ifconf ifc; struct ifreq ifs[NIFS], *ifr; struct sockaddr_in *a; + /* can't ever be AFS_DARWIN_ENV or AFS_XBSD_ENV, no? */ #if defined(AFS_AIX41_ENV) || defined (AFS_DARWIN_ENV) || defined(AFS_XBSD_ENV) char *cp, *cplim, *cpnext; /* used only for AIX 41 */ #endif Index: openafs/src/rx/rx_kcommon.c diff -c openafs/src/rx/rx_kcommon.c:1.44.2.21 openafs/src/rx/rx_kcommon.c:1.44.2.22 *** openafs/src/rx/rx_kcommon.c:1.44.2.21 Fri Mar 27 11:55:45 2009 --- openafs/src/rx/rx_kcommon.c Sat May 30 13:56:42 2009 *************** *** 15,21 **** #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/rx/rx_kcommon.c,v 1.44.2.21 2009/03/27 15:55:45 shadow Exp $"); #include "rx/rx_kcommon.h" --- 15,21 ---- #include "afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/rx/rx_kcommon.c,v 1.44.2.22 2009/05/30 17:56:42 shadow Exp $"); #include "rx/rx_kcommon.h" *************** *** 389,395 **** if (i == -1) { pp->timeout.sec = 3; /* pp->timeout.usec = 0; */ ! pp->ifMTU = RX_REMOTE_PACKET_SIZE; } else { pp->timeout.sec = 2; /* pp->timeout.usec = 0; */ --- 389,395 ---- if (i == -1) { pp->timeout.sec = 3; /* pp->timeout.usec = 0; */ ! pp->ifMTU = MIN(RX_REMOTE_PACKET_SIZE, rx_MyMaxSendSize); } else { pp->timeout.sec = 2; /* pp->timeout.usec = 0; */ *************** *** 405,411 **** pp->ifMTU = rxmtu; } } else { /* couldn't find the interface, so assume the worst */ ! pp->ifMTU = RX_REMOTE_PACKET_SIZE; } #else /* AFS_USERSPACE_IP_ADDR */ #ifdef AFS_DARWIN80_ENV --- 405,411 ---- pp->ifMTU = rxmtu; } } else { /* couldn't find the interface, so assume the worst */ ! pp->ifMTU = MIN(RX_REMOTE_PACKET_SIZE, rx_MyMaxSendSize); } #else /* AFS_USERSPACE_IP_ADDR */ #ifdef AFS_DARWIN80_ENV *************** *** 441,447 **** } else { /* couldn't find the interface, so assume the worst */ pp->timeout.sec = 3; /* pp->timeout.usec = 0; */ ! pp->ifMTU = RX_REMOTE_PACKET_SIZE; } #endif /* else AFS_USERSPACE_IP_ADDR */ #else /* AFS_SUN5_ENV */ --- 441,447 ---- } else { /* couldn't find the interface, so assume the worst */ pp->timeout.sec = 3; /* pp->timeout.usec = 0; */ ! pp->ifMTU = MIN(RX_REMOTE_PACKET_SIZE, rx_MyMaxSendSize); } #endif /* else AFS_USERSPACE_IP_ADDR */ #else /* AFS_SUN5_ENV */ *************** *** 450,456 **** if (mtu <= 0) { pp->timeout.sec = 3; /* pp->timeout.usec = 0; */ ! pp->ifMTU = RX_REMOTE_PACKET_SIZE; } else { pp->timeout.sec = 2; /* pp->timeout.usec = 0; */ --- 450,456 ---- if (mtu <= 0) { pp->timeout.sec = 3; /* pp->timeout.usec = 0; */ ! pp->ifMTU = MIN(RX_REMOTE_PACKET_SIZE, rx_MyMaxSendSize); } else { pp->timeout.sec = 2; /* pp->timeout.usec = 0; */ *************** *** 466,472 **** pp->ifMTU = rxmtu; } } else { /* couldn't find the interface, so assume the worst */ ! pp->ifMTU = RX_REMOTE_PACKET_SIZE; } #endif /* AFS_SUN5_ENV */ #else /* ADAPT_MTU */ --- 466,472 ---- pp->ifMTU = rxmtu; } } else { /* couldn't find the interface, so assume the worst */ ! pp->ifMTU = MIN(RX_REMOTE_PACKET_SIZE,rx_MyMaxSendSize); } #endif /* AFS_SUN5_ENV */ #else /* ADAPT_MTU */ Index: openafs/src/rx/rx_kcommon.h diff -c openafs/src/rx/rx_kcommon.h:1.27.2.8 openafs/src/rx/rx_kcommon.h:1.27.2.9 *** openafs/src/rx/rx_kcommon.h:1.27.2.8 Fri Oct 5 18:23:50 2007 --- openafs/src/rx/rx_kcommon.h Wed Jun 3 14:26:03 2009 *************** *** 136,142 **** #include "rx/xdr.h" #include "rx/rx.h" #include "rx/rx_globals.h" - #include "afs/longc_procs.h" #include "afs/afs_stats.h" #include "h/errno.h" #ifdef KERNEL --- 136,141 ---- Index: openafs/src/rx/rx_kernel.h diff -c openafs/src/rx/rx_kernel.h:1.13.2.2 openafs/src/rx/rx_kernel.h:1.13.2.3 *** openafs/src/rx/rx_kernel.h:1.13.2.2 Wed May 31 12:01:45 2006 --- openafs/src/rx/rx_kernel.h Wed Jun 3 14:26:03 2009 *************** *** 49,54 **** #define AFS_IFNET_T ifnet_t #endif - #include "afs/longc_procs.h" - #endif /* __RX_KERNEL_INCL_ */ --- 49,52 ---- Index: openafs/src/rx/rx_packet.h diff -c openafs/src/rx/rx_packet.h:1.13.2.1 openafs/src/rx/rx_packet.h:1.13.2.2 *** openafs/src/rx/rx_packet.h:1.13.2.1 Sun May 29 23:41:45 2005 --- openafs/src/rx/rx_packet.h Mon Apr 27 14:33:04 2009 *************** *** 41,47 **** #define MAX(a,b) ((a)>(b)?(a):(b)) #endif #else /* AFS_NT40_ENV */ ! #if !defined(AFS_DARWIN_ENV) && !defined(AFS_USR_DARWIN_ENV) && !defined(AFS_XBSD_ENV) && !defined(AFS_USR_FBSD_ENV) && !defined(AFS_LINUX20_ENV) #include /* MIN, MAX on Solaris */ #endif #include /* MIN, MAX elsewhere */ --- 41,47 ---- #define MAX(a,b) ((a)>(b)?(a):(b)) #endif #else /* AFS_NT40_ENV */ ! #if !defined(AFS_DARWIN_ENV) && !defined(AFS_USR_DARWIN_ENV) && !defined(AFS_XBSD_ENV) && !defined(AFS_USR_FBSD_ENV) && !defined(AFS_USR_DFBSD_ENV) && !defined(AFS_LINUX20_ENV) #include /* MIN, MAX on Solaris */ #endif #include /* MIN, MAX elsewhere */ Index: openafs/src/rx/xdr_rx.c diff -c openafs/src/rx/xdr_rx.c:1.10.2.4 openafs/src/rx/xdr_rx.c:1.10.2.5 *** openafs/src/rx/xdr_rx.c:1.10.2.4 Wed May 31 12:01:45 2006 --- openafs/src/rx/xdr_rx.c Wed Jun 3 16:36:35 2009 *************** *** 19,25 **** #endif RCSID ! ("$Header: /cvs/openafs/src/rx/xdr_rx.c,v 1.10.2.4 2006/05/31 16:01:45 rees Exp $"); #ifdef KERNEL #include "afs/sysincludes.h" --- 19,25 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/rx/xdr_rx.c,v 1.10.2.5 2009/06/03 20:36:35 shadow Exp $"); #ifdef KERNEL #include "afs/sysincludes.h" *************** *** 55,62 **** #endif /* !UKERNEL */ #include "rx/rx.h" - #include "afs/longc_procs.h" - #else /* KERNEL */ #include #include --- 55,60 ---- Index: openafs/src/rx/OBSD/rx_knet.c diff -c openafs/src/rx/OBSD/rx_knet.c:1.6 openafs/src/rx/OBSD/rx_knet.c:1.6.2.1 *** openafs/src/rx/OBSD/rx_knet.c:1.6 Tue Jul 15 19:16:25 2003 --- openafs/src/rx/OBSD/rx_knet.c Tue May 12 09:03:49 2009 *************** *** 11,17 **** #include "../afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/rx/OBSD/rx_knet.c,v 1.6 2003/07/15 23:16:25 shadow Exp $"); #include "../rx/rx_kcommon.h" --- 11,17 ---- #include "../afs/param.h" RCSID ! ("$Header: /cvs/openafs/src/rx/OBSD/rx_knet.c,v 1.6.2.1 2009/05/12 13:03:49 shadow Exp $"); #include "../rx/rx_kcommon.h" *************** *** 42,48 **** if (haveGlock) AFS_GUNLOCK(); ! code = soreceive(asocket, (addr ? &nam : NULL), &u, NULL, NULL, NULL); if (haveGlock) AFS_GLOCK(); --- 42,52 ---- if (haveGlock) AFS_GUNLOCK(); ! code = soreceive(asocket, (addr ? &nam : NULL), &u, NULL, NULL, NULL ! #if defined(AFS_OBSD45_ENV) ! , 0 ! #endif ! ); if (haveGlock) AFS_GLOCK(); Index: openafs/src/rx/UKERNEL/rx_kcommon.h diff -c openafs/src/rx/UKERNEL/rx_kcommon.h:1.4.2.1 openafs/src/rx/UKERNEL/rx_kcommon.h:1.4.2.2 *** openafs/src/rx/UKERNEL/rx_kcommon.h:1.4.2.1 Wed Oct 5 01:58:45 2005 --- openafs/src/rx/UKERNEL/rx_kcommon.h Wed Jun 3 14:26:04 2009 *************** *** 22,28 **** #include "afs/lock.h" #include "rx/rx.h" #include "rx/rx_globals.h" - #include "afs/longc_procs.h" #include "afs/afs_stats.h" extern struct usr_ifnet *usr_ifnet; --- 22,27 ---- Index: openafs/src/rxkad/Makefile.in diff -c openafs/src/rxkad/Makefile.in:1.19.2.3 openafs/src/rxkad/Makefile.in:1.19.2.4 *** openafs/src/rxkad/Makefile.in:1.19.2.3 Mon May 30 14:30:36 2005 --- openafs/src/rxkad/Makefile.in Wed Jun 3 01:42:01 2009 *************** *** 26,32 **** ${TOP_LIBDIR}/libdes.a \ ${TOP_LIBDIR}/librx.a \ ${TOP_LIBDIR}/liblwp.a \ - ${TOP_LIBDIR}/libsys.a \ ${TOP_LIBDIR}/libafsutil.a all: ${TOP_LIBDIR}/librxkad.a fc_test depinstall --- 26,31 ---- Index: openafs/src/rxkad/bg-fcrypt.c diff -c openafs/src/rxkad/bg-fcrypt.c:1.5.2.5 openafs/src/rxkad/bg-fcrypt.c:1.5.2.6 *** openafs/src/rxkad/bg-fcrypt.c:1.5.2.5 Tue Jul 31 18:22:21 2007 --- openafs/src/rxkad/bg-fcrypt.c Wed Jun 3 16:36:35 2009 *************** *** 38,44 **** #endif RCSID ! ("$Header: /cvs/openafs/src/rxkad/bg-fcrypt.c,v 1.5.2.5 2007/07/31 22:22:21 shadow Exp $"); #define DEBUG 0 #ifdef KERNEL --- 38,44 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/rxkad/bg-fcrypt.c,v 1.5.2.6 2009/06/03 20:36:35 shadow Exp $"); #define DEBUG 0 #ifdef KERNEL *************** *** 56,63 **** #include #endif - #include "afs/longc_procs.h" - #else /* KERNEL */ #include --- 56,61 ---- Index: openafs/src/rxkad/domestic/fcrypt.c diff -c openafs/src/rxkad/domestic/fcrypt.c:1.11.2.8 openafs/src/rxkad/domestic/fcrypt.c:1.11.2.9 *** openafs/src/rxkad/domestic/fcrypt.c:1.11.2.8 Tue Oct 30 11:24:05 2007 --- openafs/src/rxkad/domestic/fcrypt.c Thu Jun 4 12:12:58 2009 *************** *** 20,26 **** #endif RCSID ! ("$Header: /cvs/openafs/src/rxkad/domestic/fcrypt.c,v 1.11.2.8 2007/10/30 15:24:05 shadow Exp $"); #define DEBUG 0 #ifdef KERNEL --- 20,26 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/rxkad/domestic/fcrypt.c,v 1.11.2.9 2009/06/04 16:12:58 shadow Exp $"); #define DEBUG 0 #ifdef KERNEL *************** *** 41,48 **** #include #endif - #include "afs/longc_procs.h" - #else /* KERNEL */ #include --- 41,46 ---- Index: openafs/src/sgistuff/rcmd.c diff -c openafs/src/sgistuff/rcmd.c:1.1.2.2 openafs/src/sgistuff/rcmd.c:1.1.2.3 *** openafs/src/sgistuff/rcmd.c:1.1.2.2 Tue Aug 16 14:00:44 2005 --- openafs/src/sgistuff/rcmd.c Mon Apr 27 15:17:42 2009 *************** *** 19,25 **** #include RCSID ! ("$Header: /cvs/openafs/src/sgistuff/rcmd.c,v 1.1.2.2 2005/08/16 18:00:44 shadow Exp $"); #ifdef aiws /*AIX*/ #include --- 19,25 ---- #include RCSID ! ("$Header: /cvs/openafs/src/sgistuff/rcmd.c,v 1.1.2.3 2009/04/27 19:17:42 shadow Exp $"); #ifdef aiws /*AIX*/ #include *************** *** 55,62 **** #endif /* defined(AFS_HPUX_ENV) */ #ifdef TCP_DEBUG #include ! # define DPRINTF(args) dprintf args ! dprintf(args) char *args; { char **argv; --- 55,62 ---- #endif /* defined(AFS_HPUX_ENV) */ #ifdef TCP_DEBUG #include ! # define DPRINTF(args) afs_dprintf args ! afs_dprintf(args) char *args; { char **argv; Index: openafs/src/sys/Makefile.in diff -c openafs/src/sys/Makefile.in:1.27.2.16 openafs/src/sys/Makefile.in:1.27.2.17 *** openafs/src/sys/Makefile.in:1.27.2.16 Wed Sep 3 14:27:40 2008 --- openafs/src/sys/Makefile.in Wed Jun 3 01:42:02 2009 *************** *** 165,171 **** pagsh.krb: libsys.a ${CC} ${CFLAGS} -c ${srcdir}/pagsh.c -DAFS_KERBEROS_ENV ! ${CC} ${CFLAGS} -o pagsh.krb pagsh.o ${LIBS} # # Test programs. --- 165,171 ---- pagsh.krb: libsys.a ${CC} ${CFLAGS} -c ${srcdir}/pagsh.c -DAFS_KERBEROS_ENV ! ${CC} ${CFLAGS} -o pagsh.krb pagsh.o ${TOP_LIBDIR}/libauth.krb.a ${TOP_LIBDIR}/librxkad.a ${TOP_LIBDIR}/libdes.a ${LIBS} # # Test programs. Index: openafs/src/sys/pagsh.c diff -c openafs/src/sys/pagsh.c:1.9.2.9 openafs/src/sys/pagsh.c:1.9.2.10 *** openafs/src/sys/pagsh.c:1.9.2.9 Fri Mar 20 18:45:37 2009 --- openafs/src/sys/pagsh.c Wed Jun 3 01:42:02 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/sys/pagsh.c,v 1.9.2.9 2009/03/20 22:45:37 shadow Exp $"); #ifdef AFS_AIX32_ENV #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/sys/pagsh.c,v 1.9.2.10 2009/06/03 05:42:02 shadow Exp $"); #ifdef AFS_AIX32_ENV #include *************** *** 83,175 **** fprintf(stderr, "No shell\n"); exit(1); } - - - #ifdef AFS_KERBEROS_ENV - /* stolen from auth/ktc.c */ - - static afs_uint32 - curpag(void) - { - #if defined(AFS_AIX51_ENV) - int code = getpagvalue("afs"); - if (code < 0 && errno == EINVAL) - code = 0; - return code; - #else - afs_uint32 groups[NGROUPS_MAX]; - afs_uint32 g0, g1; - afs_uint32 h, l, ret; - - if (getgroups(sizeof groups / sizeof groups[0], groups) < 2) - return 0; - - g0 = groups[0] & 0xffff; - g1 = groups[1] & 0xffff; - g0 -= 0x3f00; - g1 -= 0x3f00; - if ((g0 < 0xc000) && (g1 < 0xc000)) { - l = ((g0 & 0x3fff) << 14) | (g1 & 0x3fff); - h = (g0 >> 14); - h = (g1 >> 14) + h + h + h; - ret = ((h << 28) | l); - /* Additional testing */ - if (((ret >> 24) & 0xff) == 'A') - return ret; - else - return -1; - } - return -1; - #endif - } - - int - ktc_newpag(void) - { - extern char **environ; - - afs_uint32 pag; - struct stat sbuf; - char fname[256], *prefix = "/ticket/"; - char fname5[256], *prefix5 = "FILE:/ticket/krb5cc_"; - int numenv; - char **newenv, **senv, **denv; - - if (stat("/ticket", &sbuf) == -1) { - prefix = "/tmp/tkt"; - prefix5 = "FILE:/tmp/krb5cc_"; - } - - pag = curpag() & 0xffffffff; - if (pag == -1) { - sprintf(fname, "%s%d", prefix, getuid()); - sprintf(fname5, "%s%d", prefix5, getuid()); - } else { - sprintf(fname, "%sp%ld", prefix, pag); - sprintf(fname5, "%sp%ld", prefix5, pag); - } - /* ktc_set_tkt_string(fname); */ - - for (senv = environ, numenv = 0; *senv; senv++) - numenv++; - newenv = (char **)malloc((numenv + 2) * sizeof(char *)); - - for (senv = environ, denv = newenv; *senv; *senv++) { - if (strncmp(*senv, "KRBTKFILE=", 10) != 0 && - strncmp(*senv, "KRB5CCNAME=", 11) != 0) - *denv++ = *senv; - } - - *denv = malloc(10+11 + strlen(fname) + strlen(fname5) + 2); - strcpy(*denv, "KRBTKFILE="); - strcat(*denv, fname); - *(denv+1) = *denv + strlen(*denv) + 1; - denv++; - strcpy(*denv, "KRB5CCNAME="); - strcat(*denv, fname5); - *++denv = 0; - environ = newenv; - return 0; - } - - #endif --- 83,85 ---- Index: openafs/src/tests/Makefile.in diff -c openafs/src/tests/Makefile.in:1.12.2.3 openafs/src/tests/Makefile.in:1.12.2.4 *** openafs/src/tests/Makefile.in:1.12.2.3 Mon Mar 31 11:53:48 2008 --- openafs/src/tests/Makefile.in Tue May 12 12:23:14 2009 *************** *** 360,371 **** uninstall: all: run-tests OpenAFS/Dirpath.pm libxfiles.a libdumpscan.a $(TEST_PROGRAMS)\ ! afsdump_scan afsdump_dirlist afsdump_extract dumptool @chmod +x run-tests clean: -rm -f xf_errs.c xf_errs.h dumpscan_errs.c dumpscan_errs.h *.o \ ! $(TARGETS) run-tests $(TEST_PROGRAMS) OpenAFS/Dirpath.pm include ../config/Makefile.version --- 360,371 ---- uninstall: all: run-tests OpenAFS/Dirpath.pm libxfiles.a libdumpscan.a $(TEST_PROGRAMS)\ ! afsdump_scan afsdump_dirlist afsdump_extract dumptool OpenAFS/Dirpath.sh @chmod +x run-tests clean: -rm -f xf_errs.c xf_errs.h dumpscan_errs.c dumpscan_errs.h *.o \ ! $(TARGETS) run-tests $(TEST_PROGRAMS) OpenAFS/Dirpath.pm OpenAFS/Dirpath.sh include ../config/Makefile.version *************** *** 424,428 **** --- 424,463 ---- @echo "" >>$@ @echo "1;" >>$@ + OpenAFS/Dirpath.sh: Makefile + @echo "Creating OpenAFS/Dirpath.sh" + @echo "# auto-generated by src/tests/Makefile" >>$@ + @echo "# source or '.' in this file in shell" >>$@ + @echo "# DO NOT EDIT" >>$@ + @echo " AFSCONFDIR=@afsconfdir@" >>$@ + @echo " VICEETCDIR=@viceetcdir@" >>$@ + @echo " AFSSRVBINDIR=@afssrvbindir@" >>$@ + @echo " AFSSRVSBINDIR=@afssrvsbindir@" >>$@ + @echo " AFSSRVLIBEXECDIR=@afssrvlibexecdir@" >>$@ + @echo " AFSDBDIR=@afsdbdir@" >>$@ + @echo " AFSLOGSDIR=@afslogsdir@" >>$@ + @echo " AFSLOCALDIR=@afslocaldir@" >>$@ + @echo " AFSBACKUPDIR=@afsbackupdir@" >>$@ + @echo " AFSBOSCONFIGDIR=@afsbosconfigdir@" >>$@ + @echo " OSTYPE=@MKAFS_OSTYPE@" >>$@ + @if test "${sysconfdir}/openafs/server" = "/usr/afs/etc" ; then \ + echo "# transarc paths" ;\ + echo " CACHEDIR=/usr/vice/cache" ;\ + echo " AFSDDIR=/usr/vice/etc" ;\ + echo " INITDIR=/usr/vice/etc" ; \ + echo " AFSKERNELDIR=/usr/vice/etc/modload" ;\ + echo " AFSWSBINDIR=/usr/afsws/bin" ;\ + else \ + echo "# modern paths" ;\ + echo " CACHEDIR=@localstatedir@/openafs/cache" ;\ + echo " AFSDDIR=@afssrvsbindir@" ;\ + echo " INITDIR=@sysconfdir@" ;\ + echo " AFSKERNELDIR=@afskerneldir@" ;\ + echo " AFSWSBINDIR=@afssrvbindir@" ;\ + fi >>$@ + @echo "export AFSCONFDIR VICEETCDIR AFSSRVBINDIR AFSSRVSBINDIR" >>$@ + @echo "export AFSSRVLIBEXECDIR AFSDBDIR AFSLOGSDIR AFSLOCALDIR" >>$@ + @echo "export AFSBACKUPDIR AFSBOSCONFIGDIR OSTYPE CACHEDIR AFSDDIR" >>$@ + @echo "export INITDIR AFSKERNELDIR AFSWSBINDIR" >>$@ .PHONY: all install clean realclean distclean mostlyclean install uninstall check Index: openafs/src/tests/afs-rmcell.sh diff -c openafs/src/tests/afs-rmcell.sh:1.1 openafs/src/tests/afs-rmcell.sh:1.1.10.1 *** openafs/src/tests/afs-rmcell.sh:1.1 Mon Jan 14 02:49:17 2002 --- openafs/src/tests/afs-rmcell.sh Tue May 12 12:23:14 2009 *************** *** 1,5 **** #!/bin/sh ! /bin/rm -rf /usr/afs/db/prdb.DB0 /usr/afs/db/prdb.DBSYS1 /usr/afs/db/vldb.DB0 /usr/afs/db/vldb.DBSYS1 /usr/afs/local/BosConfig /usr/afs/etc/UserList /usr/afs/etc/ThisCell /usr/afs/etc/CellServDB /bin/rm -rf /vicepa/AFSIDat /bin/rm -rf /vicepb/AFSIDat /bin/rm -rf /vicepa/V*.vol --- 1,21 ---- #!/bin/sh ! ! source OpenAFS/Dirpath.sh ! ! # Remove database files ! /bin/rm -rf ${AFSDBDIR}/prdb.DB0 ${AFSDBDIR}/prdb.DBSYS1 \ ! ${AFSDBDIR}/vldb.DB0 ${AFSDBDIR}/vldb.DBSYS1 \ ! ${AFSDBDIR}/kaserver.DB0 ${AFSDBDIR}/kaserver.DBSYS1 ! ! # Remove cell configuration (server-side) ! /bin/rm -rf ${AFSCONFDIR}/ThisCell ${AFSCONFDIR}/CellServDB \ ! ${AFSCONFDIR}/KeyFile ${AFSCONFDIR}/krb.conf ${AFSCONFDIR}/UserList ! ! # Remove remaining server configuration, logs, and local ! /bin/rm -rf ${AFSBOSCONFIGDIR}/BosConfig ${AFSLOGSDIR}/logs/* \ ! ${AFSLOCALDIR}/* ! ! # Remove data /bin/rm -rf /vicepa/AFSIDat /bin/rm -rf /vicepb/AFSIDat /bin/rm -rf /vicepa/V*.vol Index: openafs/src/tests/OpenAFS/Dirpath.pm.in diff -c openafs/src/tests/OpenAFS/Dirpath.pm.in:1.1 openafs/src/tests/OpenAFS/Dirpath.pm.in:removed *** openafs/src/tests/OpenAFS/Dirpath.pm.in:1.1 Tue Jan 15 14:22:11 2002 --- openafs/src/tests/OpenAFS/Dirpath.pm.in Thu Jun 11 11:13:08 2009 *************** *** 1,25 **** - # This is -*- perl -*- - - package OpenAFS::Dirpath; - - use strict; - use vars qw( @ISA @EXPORT $openafsdirpath); - @ISA = qw(Exporter); - require Exporter; - @EXPORT = qw($openafsdirpath); - - # Dirpath configuration - $openafsdirpath = { - 'afsconfdir' => '@afsconfdir@', - 'viceetcdir' => '@viceetcdir@', - 'afssrvbindir' => '@afssrvbindir@', - 'afssrvsbindir' => '@afssrvsbindir@', - 'afssrvlibexecdir' => '@afssrvlibexecdir@', - 'afsdbdir' => '@afsdbdir@', - 'afslogsdir' => '@afslogsdir@', - 'afslocaldir' => '@afslocaldir@', - 'afsbackupdir' => '@afsbackupdir@', - 'afsbosconfigdir' => '@afsbosconfigdir@' - }; - - 1; --- 0 ---- Index: openafs/src/ubik/ubikclient.c diff -c openafs/src/ubik/ubikclient.c:1.8.2.3 openafs/src/ubik/ubikclient.c:1.8.2.4 *** openafs/src/ubik/ubikclient.c:1.8.2.3 Mon Jul 31 13:07:51 2006 --- openafs/src/ubik/ubikclient.c Mon Apr 27 14:33:04 2009 *************** *** 15,21 **** #endif RCSID ! ("$Header: /cvs/openafs/src/ubik/ubikclient.c,v 1.8.2.3 2006/07/31 17:07:51 shadow Exp $"); #if defined(UKERNEL) #include "afs/sysincludes.h" --- 15,21 ---- #endif RCSID ! ("$Header: /cvs/openafs/src/ubik/ubikclient.c,v 1.8.2.4 2009/04/27 18:33:04 shadow Exp $"); #if defined(UKERNEL) #include "afs/sysincludes.h" *************** *** 27,32 **** --- 27,33 ---- #include "afs/rxgen_consts.h" #include "ubik.h" #include "afs/pthread_glock.h" + #include #else /* defined(UKERNEL) */ #include #include Index: openafs/src/util/hostparse.c diff -c openafs/src/util/hostparse.c:1.13.2.1 openafs/src/util/hostparse.c:1.13.2.2 *** openafs/src/util/hostparse.c:1.13.2.1 Tue Oct 30 11:24:09 2007 --- openafs/src/util/hostparse.c Mon Apr 27 14:33:05 2009 *************** *** 15,25 **** #include RCSID ! ("$Header: /cvs/openafs/src/util/hostparse.c,v 1.13.2.1 2007/10/30 15:24:09 shadow Exp $"); #ifdef UKERNEL #include "afs/sysincludes.h" #include "afs/afsutil.h" #else /* UKERNEL */ #include #include --- 15,26 ---- #include RCSID ! ("$Header: /cvs/openafs/src/util/hostparse.c,v 1.13.2.2 2009/04/27 18:33:05 shadow Exp $"); #ifdef UKERNEL #include "afs/sysincludes.h" #include "afs/afsutil.h" + #include #else /* UKERNEL */ #include #include Index: openafs/src/util/vice.h diff -c openafs/src/util/vice.h:1.7 openafs/src/util/vice.h:1.7.2.1 *** openafs/src/util/vice.h:1.7 Tue Jul 15 19:17:17 2003 --- openafs/src/util/vice.h Mon Apr 27 14:33:05 2009 *************** *** 19,25 **** * between user processes and Venus. */ #include ! #ifdef AFS_SUN_ENV #include #endif --- 19,25 ---- * between user processes and Venus. */ #include ! #if defined(AFS_SUN_ENV) || defined(AFS_DFBSD_ENV) || defined(AFS_USR_DFBSD_ENV) #include #endif Index: openafs/src/vlserver/vldbint.xg diff -c openafs/src/vlserver/vldbint.xg:1.5.6.1 openafs/src/vlserver/vldbint.xg:1.5.6.2 *** openafs/src/vlserver/vldbint.xg:1.5.6.1 Tue Feb 5 13:56:29 2008 --- openafs/src/vlserver/vldbint.xg Wed Jun 3 16:36:35 2009 *************** *** 16,22 **** %#ifdef KERNEL %#define afs_xdr_array(a,b,c,d,e,f) afs_xdr_arrayN(a,b,c,d,e,f) - %#include "../afs/longc_procs.h" %#endif /* Current limitations on parameters that affect other packages (i.e. volume) */ --- 16,21 ---- Index: openafs/src/vol/ihandle.c diff -c openafs/src/vol/ihandle.c:1.18.2.6 openafs/src/vol/ihandle.c:1.18.2.7 *** openafs/src/vol/ihandle.c:1.18.2.6 Mon Oct 27 19:54:12 2008 --- openafs/src/vol/ihandle.c Fri May 22 12:00:46 2009 *************** *** 15,21 **** #include RCSID ! ("$Header: /cvs/openafs/src/vol/ihandle.c,v 1.18.2.6 2008/10/27 23:54:12 shadow Exp $"); #include #include --- 15,21 ---- #include RCSID ! ("$Header: /cvs/openafs/src/vol/ihandle.c,v 1.18.2.7 2009/05/22 16:00:46 shadow Exp $"); #include #include *************** *** 803,812 **** return 0; IH_LOCK; assert(ihP->ih_refcnt > 0); ih_fdclose(ihP); ! IH_UNLOCK; return 0; } --- 803,834 ---- return 0; IH_LOCK; + ihP->ih_refcnt++; /* must not disappear over unlock */ + if (ihP->ih_synced) { + FdHandle_t *fdP; + IH_UNLOCK; + + fdP = IH_OPEN(ihP); + if (fdP) { + OS_SYNC(fdP->fd_fd); + FDH_CLOSE(fdP); + } + + IH_LOCK; + } + assert(ihP->ih_refcnt > 0); + ihP->ih_synced = 0; + ih_fdclose(ihP); ! if (ihP->ih_refcnt > 1) { ! ihP->ih_refcnt--; ! IH_UNLOCK; ! } else { ! IH_UNLOCK; ! ih_release(ihP); ! } return 0; } *************** *** 884,891 **** IH_UNLOCK; fdP = IH_OPEN(ihP); ! if (fdP) OS_SYNC(fdP->fd_fd); ! FDH_CLOSE(fdP); IH_LOCK; } --- 906,915 ---- IH_UNLOCK; fdP = IH_OPEN(ihP); ! if (fdP) { ! OS_SYNC(fdP->fd_fd); ! FDH_CLOSE(fdP); ! } IH_LOCK; } Index: openafs/src/vol/vnode.c diff -c openafs/src/vol/vnode.c:1.19.2.7 openafs/src/vol/vnode.c:1.19.2.8 *** openafs/src/vol/vnode.c:1.19.2.7 Mon Feb 16 23:37:59 2009 --- openafs/src/vol/vnode.c Fri May 22 12:00:46 2009 *************** *** 17,23 **** #include RCSID ! ("$Header: /cvs/openafs/src/vol/vnode.c,v 1.19.2.7 2009/02/17 04:37:59 shadow Exp $"); #include #include --- 17,23 ---- #include RCSID ! ("$Header: /cvs/openafs/src/vol/vnode.c,v 1.19.2.8 2009/05/22 16:00:46 shadow Exp $"); #include #include *************** *** 959,965 **** for (vnp = VnodeHashTable[i]; vnp; vnp = vnp->hashNext) { if (vnp->volumePtr == vp) { IH_REALLYCLOSE(vnp->handle); - IH_RELEASE(vnp->handle); } } } --- 959,964 ---- Index: openafs/src/volser/vos.c diff -c openafs/src/volser/vos.c:1.40.2.29 openafs/src/volser/vos.c:1.40.2.30 *** openafs/src/volser/vos.c:1.40.2.29 Mon Mar 23 14:19:57 2009 --- openafs/src/volser/vos.c Mon Apr 27 16:18:23 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/volser/vos.c,v 1.40.2.29 2009/03/23 18:19:57 shadow Exp $"); #include #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/volser/vos.c,v 1.40.2.30 2009/04/27 20:18:23 jaltman Exp $"); #include #include *************** *** 5840,5846 **** cmd_AddParm(ts, "-partition", CMD_SINGLE, 0, "partition name for new site"); cmd_AddParm(ts, "-id", CMD_SINGLE, 0, "volume name or ID"); ! cmd_AddParm(ts, "-valid", CMD_FLAG, CMD_OPTIONAL | CMD_HIDE, "publish as an up-to-date site in VLDB"); COMMONPARMS; ts = cmd_CreateSyntax("remsite", RemoveSite, NULL, --- 5840,5846 ---- cmd_AddParm(ts, "-partition", CMD_SINGLE, 0, "partition name for new site"); cmd_AddParm(ts, "-id", CMD_SINGLE, 0, "volume name or ID"); ! cmd_AddParm(ts, "-valid", CMD_FLAG, CMD_OPTIONAL, "publish as an up-to-date site in VLDB"); COMMONPARMS; ts = cmd_CreateSyntax("remsite", RemoveSite, NULL, *************** *** 5905,5911 **** cmd_AddParm(ts, "-clearuse", CMD_FLAG, CMD_OPTIONAL, "clear dayUse"); COMMONPARMS; ! ts = cmd_CreateSyntax("offline", volOffline, NULL, (char *)CMD_HIDDEN); cmd_AddParm(ts, "-server", CMD_SINGLE, 0, "server name"); cmd_AddParm(ts, "-partition", CMD_SINGLE, 0, "partition name"); cmd_AddParm(ts, "-id", CMD_SINGLE, 0, "volume name or ID"); --- 5905,5911 ---- cmd_AddParm(ts, "-clearuse", CMD_FLAG, CMD_OPTIONAL, "clear dayUse"); COMMONPARMS; ! ts = cmd_CreateSyntax("offline", volOffline, NULL, "force the volume status to offline"); cmd_AddParm(ts, "-server", CMD_SINGLE, 0, "server name"); cmd_AddParm(ts, "-partition", CMD_SINGLE, 0, "partition name"); cmd_AddParm(ts, "-id", CMD_SINGLE, 0, "volume name or ID"); *************** *** 5913,5919 **** cmd_AddParm(ts, "-busy", CMD_FLAG, CMD_OPTIONAL, "busy volume"); COMMONPARMS; ! ts = cmd_CreateSyntax("online", volOnline, NULL, (char *)CMD_HIDDEN); cmd_AddParm(ts, "-server", CMD_SINGLE, 0, "server name"); cmd_AddParm(ts, "-partition", CMD_SINGLE, 0, "partition name"); cmd_AddParm(ts, "-id", CMD_SINGLE, 0, "volume name or ID"); --- 5913,5919 ---- cmd_AddParm(ts, "-busy", CMD_FLAG, CMD_OPTIONAL, "busy volume"); COMMONPARMS; ! ts = cmd_CreateSyntax("online", volOnline, NULL, "force the volume status to online"); cmd_AddParm(ts, "-server", CMD_SINGLE, 0, "server name"); cmd_AddParm(ts, "-partition", CMD_SINGLE, 0, "partition name"); cmd_AddParm(ts, "-id", CMD_SINGLE, 0, "volume name or ID"); *************** *** 5971,5977 **** "prefix of the volume whose VLDB entry is to be deleted"); cmd_AddParm(ts, "-server", CMD_SINGLE, CMD_OPTIONAL, "machine name"); cmd_AddParm(ts, "-partition", CMD_SINGLE, CMD_OPTIONAL, "partition name"); ! cmd_AddParm(ts, "-noexecute", CMD_FLAG, CMD_OPTIONAL | CMD_HIDE, "no execute"); COMMONPARMS; --- 5971,5977 ---- "prefix of the volume whose VLDB entry is to be deleted"); cmd_AddParm(ts, "-server", CMD_SINGLE, CMD_OPTIONAL, "machine name"); cmd_AddParm(ts, "-partition", CMD_SINGLE, CMD_OPTIONAL, "partition name"); ! cmd_AddParm(ts, "-noexecute", CMD_FLAG, CMD_OPTIONAL, "no execute"); COMMONPARMS; Index: openafs/src/volser/vsprocs.c diff -c openafs/src/volser/vsprocs.c:1.33.2.22 openafs/src/volser/vsprocs.c:1.33.2.23 *** openafs/src/volser/vsprocs.c:1.33.2.22 Mon Oct 27 19:54:12 2008 --- openafs/src/volser/vsprocs.c Sun May 31 19:15:21 2009 *************** *** 11,17 **** #include RCSID ! ("$Header: /cvs/openafs/src/volser/vsprocs.c,v 1.33.2.22 2008/10/27 23:54:12 shadow Exp $"); #include #include --- 11,17 ---- #include RCSID ! ("$Header: /cvs/openafs/src/volser/vsprocs.c,v 1.33.2.23 2009/05/31 23:15:21 shadow Exp $"); #include #include *************** *** 2316,2322 **** &cookie); EGOTO1(mfail, code, "Failed to do the%s dump from old site to new site\n", ! afromvol); VDONE; VPRINT1("Setting volume flags on destination volume %u ...", newVol); --- 2316,2322 ---- &cookie); EGOTO1(mfail, code, "Failed to do the%s dump from old site to new site\n", ! (flags & RV_NOCLONE) ? "" : " incremental"); VDONE; VPRINT1("Setting volume flags on destination volume %u ...", newVol);