commit dbd2e6c12057de7eccd09a05a5712f196157b322 Author: Derrick Brashear Date: Tue Sep 7 14:40:53 2010 -0400 openafs 1.5.77 make 1.5.77 in various places we need it Change-Id: Ic7e487ce76f86f50d2565e75a3b2f7642ecadd87 Reviewed-on: http://gerrit.openafs.org/2713 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fba7087c981b01d37ecce3d0a1645fa7ebdf6779 Author: Derrick Brashear Date: Tue Sep 7 20:31:20 2010 -0400 ubik recovery and remote use correct file number the file propagation "out of band" changes should not hardcode recovery on file 0, but instead work on any file the interface is acting on. use the provided file number. Reviewed-on: http://gerrit.openafs.org/2715 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit f8ff458ef02d5ef49bc467304e40571d871385c8) Change-Id: I2cf324c9759f9878c5b37603480a9c803c041641 Reviewed-on: http://gerrit.openafs.org/2717 commit fce40951d4e3fc586e5e7bca545c1b4c6adbff04 Author: Jeffrey Altman Date: Tue Sep 7 14:35:22 2010 -0400 Windows: 1.5.77 Change Log summary Change-Id: Ic0362956470ddb76fac64d21927b3e51b7980ea6 Reviewed-on: http://gerrit.openafs.org/2710 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit 99811e3e5faf5917975d7ec3c3d16e2ed9a5bf50) Reviewed-on: http://gerrit.openafs.org/2712 commit cb498f02f7bc90dab005c478033413eedca27478 Author: Jeffrey Altman Date: Fri Sep 3 00:02:17 2010 -0400 Windows: revise NTSTATUS response for ALLBUSY, ALLOFFLINE, and ALLDOWN Replace STATUS_IO_TIMEOUT with RPC_NT_SERVER_TOO_BUSY for CM_ERROR_ALLBUSY. Replace STATUS_PATH_NOT_FOUND with RPC_NT_SERVER_UNAVAILABLE for CM_ERROR_ALLOFFLINE and CM_ERROR_ALLBUSY. These errors provide a more meaningful message to end users when a failure occurs. LICENSE MIT Change-Id: I34483f8f696285477fa0f8a8dac3b0ff33dee6b4 Reviewed-on: http://gerrit.openafs.org/2663 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit de441ba420b8fc38ce1b36bee06097f21cc6514b) Reviewed-on: http://gerrit.openafs.org/2714 commit fcca1f7bbee8198d8aeead3003bbff28f5dd9080 Author: Jeffrey Altman Date: Tue Sep 7 08:21:12 2010 -0400 Windows: Improve SMB detection of Local System account Depending on the authentication method, the smb session authenticated name for the "local system" account may be the nul string. In this case it is impossible to use the name to determine if the authenticated entity is the "local system" account as required by smb_SetToken. To work around this problem, smb_AuthenticateUserExt() will now obtain the Security Identifier (SID) for the authenticated account. The string representation of the SID will be used in place of the name by smb_ReceiveV3SessionSetupX() when constructing the smb_user_t object. A new flag, SMB_USERNAMEFLAG_SID, indicates when the name is in fact a SID. smb_userIsLocalSystem() checks for the SMB_USERNAMEFLAG_SID flag and performs a SID comparison when it is set. smb_SetToken() will accept either MACHINE\user or a SID string as the smbname. It will obtain the SID if possible and create a SID-based smb_user_t. It is possible that a SYSTEM service will use an anonymous (S-1-5-7) SMB connection. In that case, we also check the RPC Impersonation SID to see if it is SYSTEM. If so, the RPC identity supercedes the SMB identity for SetToken. smb_IoctlRead, smb_IoctlV3Read and smb_IoctlRawRead are now all consistent with regards to name processing. Fixed a couple of comments as well. FIXES 128022 LICENSE MIT Change-Id: I8f9ccd4a4dddea52d151288855c7e129e2f31b28 Reviewed-on: http://gerrit.openafs.org/2709 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman (cherry picked from commit 19f50c13b4542cc84c33eaca4b2cc6ac0b75eb98) Reviewed-on: http://gerrit.openafs.org/2711 commit 81e9b15f568bbfdbbfa54c2f2aaf7f1f1e5beb62 Author: Jeffrey Altman Date: Thu Sep 2 21:17:24 2010 -0400 Windows: Modify signature of buf_CleanAsync and buf_CleanAsyncLocked The buf_CleanAsync() and buf_CleanAsyncLocked() signature does not include a cm_scache_t pointer even though buf_CleanAsyncLocked() needs a pointer to the matching cm_scache_t object. There are some calls when the cm_scache_t object is already known. For those cases it is more efficient to avoid the additional lookup especially when buf_CleanAsync*() is being called on every buffer associated with the cm_scache_t object. At the same time add a flags field and a constant CM_BUF_WRITE_SCP_LOCKED to permit the lock state of the cm_scache_t to be passed in. Finally, fix up the usage in buf_FlushCleanPages() which gains the most from these changes. LICENSE MIT Change-Id: I3726441ff83a89e24d790174ca71396d633f1be6 Reviewed-on: http://gerrit.openafs.org/2662 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman (cherry picked from commit 1ef135110b7d850e2c40bbbb6b7de69c76872fa9) Reviewed-on: http://gerrit.openafs.org/2708 commit a7e9c8316765b3b7a8933aafba3681e2e4d106ef Author: Jeffrey Altman Date: Thu Sep 2 21:05:15 2010 -0400 Windows: Permit cm_scache rwlock to be dropped when "Stablized" The cm_buf_opts_t cm_BufStabilize() function was implemented such that holding the cm_scache_t.rw lock had to be exclusively held until cm_BufUnstablize() was called. Unfortunately, this prevents using Stabilize/Unstabilize to protect the cm_scache_t during Flush operations as the cm_scache_t.rw lock must be acquired after the cm_buf_t mutex and not before it. This patchset reimplements the synchronization logic using the new CM_SCACHEFLAG_SIZESETTING flag and cm_SyncOp(). LICENSE MIT Change-Id: Iaada83f7f3b75bb3b213b33b2399e900e48a2fbc Reviewed-on: http://gerrit.openafs.org/2661 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit fa961c02fbb7dc54fa4c02c38dfd07c44eb696d3) Reviewed-on: http://gerrit.openafs.org/2707 commit da0a17c9fc0bb54f081355ace48f0ea988dce7bc Author: Jeffrey Altman Date: Sun Aug 29 23:41:02 2010 -0400 Windows: fail cm_CheckNTOpen if READ|DELETE for readonly file If the readonly file attribute is set (stored as a unix mode) then a CreateFile operation should fail if the file is opened for DELETE in combination with any other privilege. LICENSE MIT Change-Id: Ie8ebb6d230cf65d9ce2411bab2fcc4e561081505 Reviewed-on: http://gerrit.openafs.org/2660 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit ee26ce51f67c7a91d843184374240bbc29e1660b) Reviewed-on: http://gerrit.openafs.org/2706 commit 695fc9ba0111ca0455395fac62ce50ec42f48329 Author: Jeffrey Altman Date: Thu Aug 26 11:33:43 2010 -0400 Windows: Add validation for directory buffer contents If the directory buffer contents are garbage we can crash the service. Add some simple validation checks to ensure that cm_dirEntry_t objects have the correct flag value and that the name strings are not too long. LICENSE BSD Change-Id: If4a276007ff7a21a641825037a1035ea20db79c5 Reviewed-on: http://gerrit.openafs.org/2658 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit 72584be7fb0b6eb01ca5cb9c0703e9bc1b92f547) Reviewed-on: http://gerrit.openafs.org/2705 commit 8c4d5075c3b074584db03b7858a8d066057318f4 Author: Jeffrey Altman Date: Tue Aug 24 16:46:45 2010 -0400 Windows: cm_TryBulkStatRPC must process VIO errors If the bulkStat errorCode indicates that a particular object is inaccessible due to a VIO error, we must update the server status appropriately in order to permit failover. LICENSE MIT Change-Id: I19ce3d2c5b138d519fb1c437f6d5109d7d8b1310 Reviewed-on: http://gerrit.openafs.org/2657 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit 3f69933c4243d6861d5cce701c28f2dee088e6c2) Reviewed-on: http://gerrit.openafs.org/2704 commit 0ed1eca089eb965d4416dcb5f26b97d082e66786 Author: Jeffrey Altman Date: Tue Aug 24 16:42:57 2010 -0400 Windows: better handle RX_MSGSIZE errors An RX_MSGSIZE error is returned by the new PMTU detection code. It is critical that such an error result in a retry of the operation that failed. Otherwise, the PMTU detection can't work and the server will be marked down. Secondly, it is important that such errors not leak to the application layer. Map them to CM_ERROR_RETRY in all cases. LICENSE MIT Change-Id: I966fe259080bd31ec60fdb6715f54e18e190c790 Reviewed-on: http://gerrit.openafs.org/2656 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit b11ff643b5665ec252ca96dc19af1446fb72481f) Reviewed-on: http://gerrit.openafs.org/2703 commit 5010d19abc4eb35434dbf4918105daf43a8c4e67 Author: Jeffrey Altman Date: Tue Aug 24 16:40:38 2010 -0400 Windows: print the value of cm_OfflineROIsValid to afsd_init.log If we say we are printing the value of cm_OfflineROIsValid, do so and not cm_deleteReadOnly. LICENSE MIT Change-Id: I8b0bc73798feea413f8ce79f9965664fc050ef76 Reviewed-on: http://gerrit.openafs.org/2655 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit 874c5ca8359d49703f1f37d7fb70204c182d0f86) Reviewed-on: http://gerrit.openafs.org/2702 commit f024479e88ada8d924c0f8ebb29afa94b0c64b49 Author: Jeffrey Altman Date: Sun Aug 22 10:05:59 2010 -0400 Windows: Handle RX_RESTARTING consistently for all RPCs Translate RX_RESTARTING to the same cache manager error code for all RPC classes. LICENSE MIT Change-Id: I4540e9886d1de68d9b3f8a2e72508f876225ff4a Reviewed-on: http://gerrit.openafs.org/2654 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit 87c9e7e6e4f8be4778d183940f349557193146c7) Reviewed-on: http://gerrit.openafs.org/2701 commit 54fd97ac8c19dae4ff6524bd463cc01316fbf701 Author: Jeffrey Altman Date: Sat Aug 21 00:23:45 2010 -0400 Windows: Log cell along with volume id for server errors When logging server volume instance errors to the windows application event log, be sure to log the cell as well. Translating from server ip address is non-trivial. Make it easier for administrators triaging issues to plug the volume and cell info into vos commands. LICENSE MIT Change-Id: I801fcd5c1afba4a8cdef4386fec72b9a529d4cfb Reviewed-on: http://gerrit.openafs.org/2653 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit 2ef83d24846e6035b752fcbe98d980e046e074f9) Reviewed-on: http://gerrit.openafs.org/2700 commit 66221b5ba602e1ad1a292b09652fb6f4d965af6b Author: Jeffrey Altman Date: Sat Aug 21 00:22:22 2010 -0400 Windows: unix modes represented in octal Since unix mode bits are represented in octal in most cases make sure we log them that way. LICENSE MIT Change-Id: Ia8106c7bbd3230380c7efa437b6eb0a90398bda3 Reviewed-on: http://gerrit.openafs.org/2652 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman (cherry picked from commit a97282bf76730fd05c2365aa1c58ce96174efd37) Reviewed-on: http://gerrit.openafs.org/2699 Tested-by: Derrick Brashear commit 3edc17fd817359969ec1327115db10f0d4aa1066 Author: Derrick Brashear Date: Fri Sep 3 08:18:41 2010 -0400 rx msgsize retry logic change only rewrite to RX_MSGSIZE if the MTU changed. otherwise, leave well enough alone Change-Id: If7311c623c61064c52b42fbb131aa8ff007c3741 Reviewed-on: http://gerrit.openafs.org/2664 Tested-by: BuildBot Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit b91e7e86b429b6182d8ee23c471bef4f48af560f) Reviewed-on: http://gerrit.openafs.org/2698 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b030d05e0501790499d84d048f29549b9e0d1aa0 Author: Andrew Deason Date: Fri Sep 3 10:59:45 2010 -0500 cacheout: Improve error handling Bail out when we encounter errors in initialization. Among other things, this prevents a segfault if we can't read the client configuration. Change-Id: I8b35163c5c4750eb05539a225069327051a3f148 Reviewed-on: http://gerrit.openafs.org/2665 Tested-by: BuildBot Reviewed-by: Jeffrey Hutzelman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit defd84d0fb43a068d2b9ae88a103ffea266c8d95) Reviewed-on: http://gerrit.openafs.org/2697 commit a06053cbb4f0c32127a73aeeca90fc5309ff4c08 Author: Andrew Deason Date: Fri Sep 3 16:32:11 2010 -0500 vos: Show effects in single-volume dryrun mode Fix -dryrun mode for 'vos syncvldb' to also show the effects when run against a specific volume id. Change-Id: I3a2db96fc8016939f2f2f9561aba29527701ad59 Reviewed-on: http://gerrit.openafs.org/2667 Tested-by: Andrew Deason Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit e07f87070c901d71c2f4fa594738ce0a16c77ea1) Reviewed-on: http://gerrit.openafs.org/2696 commit 6f2ba2c18a0f0c154f3b6696fec694a9179b055f Author: Andrew Deason Date: Fri Sep 3 15:20:10 2010 -0500 vos: Show after effects in dryrun mode The dryrun mode of operation for 'vos syncvldb' and 'vos syncserv' does not currently show the "status after" portion of its output, so they don't really show what the commands will do. Change them so "status after" is shown for -dryrun when sync'ing servers or partitions, and count changes towards the count at the end. Change-Id: I6cc20c28a989925a1262570b286fdd7d290c0a9a Reviewed-on: http://gerrit.openafs.org/2666 Tested-by: Andrew Deason Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 5705a46a75917cb34b4ea9161dde4ee43d0d4eb0) Reviewed-on: http://gerrit.openafs.org/2695 commit 0a7498a90b5257ca24e600a6913e8939cd81b3f7 Author: Marc Dionne Date: Sun Sep 5 10:48:52 2010 -0400 afs_DoBulkStat: don't call afs_Analyze without holding the GLOCK Limit the scope of the GUNLOCK-GLOCK blocks to cover only the RX calls. This prevents afs_Analyze from being called without the GLOCK, which causes an oops in afs_icl_Event4() where there's an ASSERT_GLOCK. Change-Id: Ifa6942d08f22479c0affba3ebd1fc9bf4063d8a5 Reviewed-on: http://gerrit.openafs.org/2668 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 526b8a7ca53977d6cdb91427932ac6b18bb7064d) Reviewed-on: http://gerrit.openafs.org/2694 commit 1df1d53a6e392eead9be6430e9294bc28480db45 Author: Andrew Deason Date: Wed Sep 1 11:14:37 2010 -0500 RedHat: Do not force krb5-config path If the %krb5config macro is not defined, do not force using /usr/kerbers/bin/krb5-config, since sometimes that is not where it is (RHEL6 puts it in /usr/bin). Instead only specify KRB5_CONFIG if krb5config is defined; otherwise let configure find krb5-config for us. Change-Id: I35cc03ddbba7edd2c03d8f72b9636d4a7f6e64c0 Reviewed-on: http://gerrit.openafs.org/2642 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 469cc14bd16b9e1a7ed8404224de63862c1f52f5) Reviewed-on: http://gerrit.openafs.org/2693 commit 6c05fc5c4d5db0e1504c6c69df880f023456ccb1 Author: Andrew Deason Date: Wed Sep 1 10:32:53 2010 -0500 RedHat: Update openafs.spec for configure changes We no longer have the configure options --enable-disconnected and --with-krb5-conf. Remove them from the spec file and instead specify krb5-config via the KRB5_CONFIG variable. Change-Id: Ic9d9505f0526e38bf084683d9be3367851005a97 Reviewed-on: http://gerrit.openafs.org/2641 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 83f85c9ad6c439eb9676436a3e09c40c2813f1c1) Reviewed-on: http://gerrit.openafs.org/2692 commit 8ff34a177197e3b62847856c4c9e97e910dba9ab Author: Andrew Deason Date: Wed Sep 1 10:18:17 2010 -0500 RedHat: Use git-version in makesrpm.pl We no longer have the OpenAFS version in the AM_INIT_AUTOMAKE. Get the version from the equivalent AC_INIT version, which is determined by running build-tools/git-version. So, run git-version to get the version. Change-Id: I5feb72ba35566315654ab88f2047be8a7ac6b40a Reviewed-on: http://gerrit.openafs.org/2640 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 346ccf51ddedadd7f6709276237c26b7871ffbaf) Reviewed-on: http://gerrit.openafs.org/2691 commit 92de18b6cc344b742261e4344070721fa909eb6c Author: Andrew Deason Date: Wed Sep 1 10:12:31 2010 -0500 RedHat: Use configure.ac in makesrpm.pl We don't have a configure.in anymore; instead we have a configure.ac. Change-Id: Ic79b5577cf2d5cd3021fe933ca5405fb2d514a4d Reviewed-on: http://gerrit.openafs.org/2639 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 86ccd1c0f486d38b13a71a3c99879f546ad18b15) Reviewed-on: http://gerrit.openafs.org/2690 commit f2e7059dbe1f7ce0297d6968a87841980dca6410 Author: Russ Allbery Date: Wed Sep 1 10:52:30 2010 -0700 Update Autoconf Kerberos probes to latest rra-c-util version We will now look for krb5-config in /usr/kerberos/bin (the path used on Red Hat Enterprise prior to RHEL6) if it isn't found in the user's PATH. This update also adds a new probe for krb5_get_init_creds_opt_free which is not yet used, but may eventually be useful for klog.krb5. Change-Id: Iefd67c02ac44fd5f1a30883d1cd6ea4e489b32b1 Reviewed-on: http://gerrit.openafs.org/2644 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit ae868642e1936509184cbe9b539733445902bdf3) Reviewed-on: http://gerrit.openafs.org/2689 commit d622e893c12fa1b43e99dc12bd27ec7dc5c8bcfc Author: Jonathan Billings Date: Tue Aug 31 15:15:26 2010 -0400 Linux: Updated RedHat spec file with new demand attach servers and docs Added the following to the openafs-server package: dafileserver dafssync-debug dasalvager davolserver salvageserver salvsync-debug Added the man pages for the above. Added a man page for krb.excl Change-Id: Ifac99e77de4f7b07dc6e76df0237b1960a73cb0d Reviewed-on: http://gerrit.openafs.org/2630 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 69c1d5e2debdafd971216ab4afc3e90702d5860b) Reviewed-on: http://gerrit.openafs.org/2688 commit ccc9d2a37a652a823d01cefae51183dbd77e5568 Author: Hartmut Reuter Date: Tue Aug 31 13:30:41 2010 +0200 Let SRXAFS_GetStatistics64 return correct values for the workstations h_GetWorkstats was called also for 64bit which let random contents in the other half of the 64bit field. Worse: little and big endian machines filled different parts of the field so that a later masking in fsprobe would net help for all kinds of servers. Now a small wrapper h_GetWorkstats64 is called which calls h_GetWorkstats correctly. Change-Id: Iaeafd77dfa03d88caa98e4e352f95bfb33d736df Reviewed-on: http://gerrit.openafs.org/2629 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 8006ff8bf4a6f1944243309e5130538e3cbe62d5) Reviewed-on: http://gerrit.openafs.org/2687 commit f3409e4d374f127ec8684c7d816553da38c58681 Author: Derrick Brashear Date: Sat Aug 28 17:19:45 2010 -0400 macos afsdb reinit resolver on address change assume a new address means we probably have new resolver info; reinit when we get the callback. FIXES 126440 Change-Id: I0d5ac0576f2b2e90093b93974b0354cac35d84a3 Reviewed-on: http://gerrit.openafs.org/2622 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 5aa8c5d9794b909ef9195992ee12f963e254574b) Reviewed-on: http://gerrit.openafs.org/2686 commit 91be7d3b69627fe2920c6ab1b9eaac341cd87903 Author: Matt Benjamin Date: Sun Aug 29 15:06:22 2010 -0400 cache bypass Also increment page refcount in readpage As noticed by a commenter, afs_linux_bypass_readpage needs the same get_page operation as in afs_linux_bypass_readpages, as background page accounting assumes we have done it. Change-Id: Ib2e1cb7ec971e68b022dd1740584369d04b8b833 Reviewed-on: http://gerrit.openafs.org/2626 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit aaf9b4ddd5ce9ed83be038bba01199b1d400ddf3) Reviewed-on: http://gerrit.openafs.org/2685 commit 56e0c3d8edf223cab1c5ccd52f7d4a0bb0abf73b Author: Matt Benjamin Date: Fri Aug 27 19:11:32 2010 -0400 DFBSD update dfbsd userland Add new sysnames. Fix some userland header inclusions, defend against kernel-mode ioctl interpretation when building UKERNEL. Add fragments missing from DFBSD MakefileProto template. Change-Id: I56659bfe43dc24ef8a158aaf486c9a6f23643002 Reviewed-on: http://gerrit.openafs.org/2619 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 239a62034b849565d680baa9e5b8e6921256ffd5) Reviewed-on: http://gerrit.openafs.org/2684 commit 88bcd3ed6367280bd97ae56cc2c25308e82d86e0 Author: Matt Benjamin Date: Sun Aug 29 17:33:03 2010 -0400 FBSD try-relax child vnode locking (recurse only) In cases where afs_vop_lookup would return a child vnode locked, continue to take an exclusive lock, but allow recursion (LK_CANRECURSE). Allow recursion also at afs_vop_link, where we specifically encountered a conflict due to recursion. Change-Id: I5f5b0979ce3c86e517f96ea60b96ebdd26401acb Reviewed-on: http://gerrit.openafs.org/2625 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit ec85304dd738935d8be3f8934b166f78a10995bf) Reviewed-on: http://gerrit.openafs.org/2683 commit bcdd4fb476d9024de15d31da913aefe02ca3e88f Author: Matt Benjamin Date: Sat Aug 28 21:57:38 2010 -0400 FBSD, DFBSD (future) call afs_FakeOpen in the write path Call afs_FakeOpen in the write path, even though nominally it is AFS_VM_RDWR_ENV. Change-Id: I6d24c9631f80058e3dd0d6f284ca7792253ceaaa Reviewed-on: http://gerrit.openafs.org/2623 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit b727c1e748042e46f2a566725359fed0dd8a8f4f) Reviewed-on: http://gerrit.openafs.org/2682 commit 83b62c2d2b59b885b34c95b5d7e72d1bb7018fdc Author: Matt Benjamin Date: Sat Aug 28 20:43:41 2010 -0400 FBSD, DFBSD (future) vnode_pager_setsize updates Based on review of bundled filesystems on FBSD and DFBSD, call vnode_pager_setsize in three unhandled cases (getattr, setattr, and io growing a file; truncation was handled correctly already). Following up on a suggestion by Ben Kaduk. Change-Id: I05b61c26402bb8ab49ad74b71af2d02b439f959f Reviewed-on: http://gerrit.openafs.org/2621 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 8334b40376f4b820e5f08e0a1f477be7c04c5cc8) Reviewed-on: http://gerrit.openafs.org/2681 commit f15ddd746beb01c7e629d5fa1f60cd1b21753d1b Author: Matt Benjamin Date: Thu Aug 26 22:54:20 2010 -0400 FBSD restore old syscall register logic for older kernels The syscall_register code appears to depend on coordination with FreeBSD upstream, which hopefully can be completed by RELENG_9. Use the original code for installation of the AFS syscall everything older than that. Change-Id: I2954cf1a2ae3587a311e8133ec5cdc500b4e2e24 Reviewed-on: http://gerrit.openafs.org/2618 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit df4cf75b970f72810078fc788e732480dbb7996a) Reviewed-on: http://gerrit.openafs.org/2680 commit 6f088eaa2b38d867f855a780c2884cfb72d39d1c Author: Ben Kaduk Date: Wed Aug 25 23:21:30 2010 -0400 FBSD: properly register our syscall Use the provided interface, syscall_register(), instead of manually tweaking the sysent table. Starting afsd will still fail at present on FreeBSD HEAD without an additional kernel patch to syscalls.master. Change-Id: I18db7c8b74dbd114165f7617df25e462cb372e88 Reviewed-on: http://gerrit.openafs.org/2616 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 5b71bab4ff0a0f6f1e0cec2c71adfd48b3f35cca) Reviewed-on: http://gerrit.openafs.org/2679 commit fe0ba8419395bb6594c9c9d1747d8cfe59b2398a Author: Matt Benjamin Date: Wed Aug 25 16:19:18 2010 -0400 FBSD: give osi_NetReceive time to shutdown, reprise The delay logic needs to follow soshutdown, and precede soclose. The thread in osi_NetReceive is racing to do another soreceive. That thread needs to win the race and notice the socket is shut down before rx_socket is torn down. Change-Id: Id8424dcfa2498550a190d277017b7ea15fc11023 Reviewed-on: http://gerrit.openafs.org/2613 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 2ea508ea0f320ca17de6df3526aa7237b998c7be) Reviewed-on: http://gerrit.openafs.org/2678 commit 1d07d92efdaef2e3d4bd6a7bb0b42c86fd552b98 Author: Matt Benjamin Date: Wed Aug 25 03:34:35 2010 -0400 FBSD CM: don't call afs_close when recycling Don't call afs_close when handling VOP_CLOSE on a recycled vnode, since there was no matching open. This corrects the opens count, which was seen to go have gone negative in the reclaim vop. For clarity, assert if afs_vop_close is entered with a VI_DOOMED vnode and avc->opens != 0. Change-Id: I511a4f2a924c2f8e20f3ecdaa445fbe803289a47 Change-Id: I1b2307fd3318fa54e8f7fb72a5d3f843e2a38404 Reviewed-on: http://gerrit.openafs.org/2612 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 5c0aebc421ddbed099a6fe1015cdda603e20529d) Reviewed-on: http://gerrit.openafs.org/2677 commit af0f3d85e7ebf711f7a9164e7f927061fadfadd2 Author: Matt Benjamin Date: Tue Aug 24 20:48:24 2010 -0400 BSD CMs: Don't call nonexistent afs_FlushVS in afs_vop_reclaim Revert BSDs to call FlushVCache in their respective reclaim vops, afs_FlushVS no longer exists. FIXES 127955 Change-Id: I842356c2d6ee4fa3a49eaa8594f1b52188c24985 Reviewed-on: http://gerrit.openafs.org/2611 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 3f7b70a28ba7dc03f0fc973343669f0a7967de4c) Reviewed-on: http://gerrit.openafs.org/2676 commit 9fad100d1bfa69e5ae9fb3a78677fe5b359bb47a Author: Andrew Deason Date: Mon Aug 23 14:03:03 2010 -0500 venus: build cacheout Build 'cacheout' in all builds, so it does not succumb to bitrot. Change-Id: If00ce1fd9dd49e92caa183dbb54f06b2edc4ece9 Reviewed-on: http://gerrit.openafs.org/2606 Tested-by: Andrew Deason Tested-by: BuildBot Reviewed-by: Derrick Brashear (cherry picked from commit a2821cdbd05b280e3dc886cfb094e4c040d45c6c) Reviewed-on: http://gerrit.openafs.org/2675 Tested-by: Derrick Brashear commit 71bf493e0ec7baa81f78a5cacf04a9783ee9a81b Author: Andrew Deason Date: Mon Aug 23 12:55:21 2010 -0500 venus: make cacheout build again Make src/venus/cacheout buildable again, by fixing several compiler errors and warnings. Also clean up a few small things, like adding 'static' qualifiers. Change-Id: I1cd10221a5e13a59227e4915991db6042325b7de Reviewed-on: http://gerrit.openafs.org/2605 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 4b7038820c503445917087ca4034ae48c7803518) Reviewed-on: http://gerrit.openafs.org/2674 commit f820ab766e173ef708e6e5f1efb56bfb4dfd9ff3 Author: Simon Wilkinson Date: Sat Aug 21 12:05:37 2010 +0100 Don't include afsconfig.h in rxgen headers Some headers generated by rxgen are installed. We can't use afsconfig.h in installed headers, as it isn't installed (and it shouldn't be, as it contains autoconf defines which will almost certainly have namespace conflicts with other packages) Revert the portion of 972a407 that added afsconfig.h to the h_output function. This should now be safe as stds.h no longer relies on the result of autoconf tests. FIXES 127931 Change-Id: I75645620e46c4f354ca984a8daf99254650133f6 Reviewed-on: http://gerrit.openafs.org/2604 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 975b662d8ecabeb82ffd2a3a2dce0c8d6e6cc473) Reviewed-on: http://gerrit.openafs.org/2673 commit 14cc14d89b1a687d6694f2217c8b414f6c36a89c Author: Marc Dionne Date: Fri Aug 20 16:11:59 2010 -0400 s390x: only declare afs_sys_setgroups32_page where needed Variable afs_sys_setgroups32_page is only used when __NR_setgroups32 is not defined. Make the declaration depend on it as well to clear up an unused variable warning. Change-Id: I812b98d6ac4bf6ac923553ef3556c90d75d86fcb Reviewed-on: http://gerrit.openafs.org/2600 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 4129b055a6236e892e1dc2c5d2023d1947495811) Reviewed-on: http://gerrit.openafs.org/2672 commit 96d40120207e7eea31eed0bb408d2d8abfdaba59 Author: Marc Dionne Date: Fri Aug 20 16:37:56 2010 -0400 Fixes for signed char architectures "char" is unsigned on s390x, which causes a few warnings where we test for negative values. Add a signed modifier in a few cases, and in vos.c replace with an int to match a similar section of code in the same file. Mostly a warning fix, but in one case the variable could be used to return a -1 error value, so it may have caused an actual bug. Change-Id: I005fbcd7c573735df7403316ec0ced67ee81e559 Reviewed-on: http://gerrit.openafs.org/2602 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit c2be1ee1d726463590ae1272495d102111fdf75b) Reviewed-on: http://gerrit.openafs.org/2671 commit 763d3c9bdc2eea8b94122e2b8a64fee0b84d89a0 Author: Marc Dionne Date: Fri Aug 20 17:42:47 2010 -0400 Ignore old style definition warnings in generated code Older flex can generate functions that trigger the "old-style-definition" warning. Since it's generated code, just ignore it. Change-Id: If475507561498b976a2942bd0084975814ab6a76 Reviewed-on: http://gerrit.openafs.org/2603 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 850567f17285021d3133a75c1d0d3494e0faabfc) Reviewed-on: http://gerrit.openafs.org/2670 commit ac173619059525e4a40c9787ccb2910c6a46de95 Author: Marc Dionne Date: Fri Aug 20 16:27:44 2010 -0400 Prototype warning cleanup - big endian Move function definitions above their use in quad_cksum.c and remove the (incomplete) prototypes. Clears up a few warnings on big endian systems. Change-Id: Id860f904fff9fb033ee4b2032162304a4af7423a Reviewed-on: http://gerrit.openafs.org/2601 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit de341580a6003944f1ae4b01c56bf483ead857d1) Reviewed-on: http://gerrit.openafs.org/2669 commit db48e56a8b75f82e803517a86d2e72e2a56f96b5 Author: Jeffrey Altman Date: Tue Aug 17 01:24:39 2010 -0400 Windows: fix Freelance trailing dot enforcement The cm_enforceTrailingDot() function failed if there was a trailing dot followed by white space. LICENSE MIT Change-Id: Ib6a90420459a44b87995c44a5f58fcdcd5041c9f Reviewed-on: http://gerrit.openafs.org/2588 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear (cherry picked from commit a81c323fbd05cb5cb85c56dfcc0b540e0354f318) Reviewed-on: http://gerrit.openafs.org/2589 Tested-by: Derrick Brashear commit ccd13703d771e4e2a4df0483d9e5120663a1d1db Author: Jeffrey Altman Date: Tue Aug 17 02:13:31 2010 -0400 Windows: Fix remove 'register' patch The register removal patch broke the Windows build. Fix it. Change-Id: I0121da17a98e1eb35932d18c851989737d9325b5 Reviewed-on: http://gerrit.openafs.org/2571 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman (cherry picked from commit eb49bd3df0f20cf99825002387c2dbceefe9b784) Reviewed-on: http://gerrit.openafs.org/2587 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 753a316821bf23a53a7ebef9b52122c39ee88b83 Author: Marcus Watts Date: Mon Aug 16 23:52:36 2010 -0400 death to trailing whitespace if we're gonna clean up... Change-Id: I5ab03f29468577b62dacab41a67eadfd8c43f812 Reviewed-on: http://gerrit.openafs.org/2463 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4a531cb7069f3ced1aae5a1948d708a7f24539df Author: Marcus Watts Date: Wed Jul 14 23:13:20 2010 -0400 death to register in soviet compilers, compiler optimizes you. stop providing dated (and annoying for debugging) register keywords. Change-Id: Ibcac0aa3f353fe531b9be0beedca919fb947bfab Reviewed-on: http://gerrit.openafs.org/2436 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b44562f5dcda72a78fa12b47f8862f0a3c231aee Author: Derrick Brashear Date: Thu Aug 12 00:33:58 2010 -0400 openafs 1.5.76 make openafs 1.5.76 Change-Id: I56ef6618ae6ff8d0ee2e06a145aed7d61f98d682 Reviewed-on: http://gerrit.openafs.org/2537 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 523fde439847e2a32aa446ce94c65436dceeb8f8 Author: Jeffrey Altman Date: Thu Aug 12 01:47:41 2010 -0400 Windows Change Log for 1.5.76 Change-Id: Ia5004d37fceb506ed7ca894f31a903d2b8cb66cb Reviewed-on: http://gerrit.openafs.org/2540 Tested-by: BuildBot Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 67ca70bfd3dcb2b5fc9d318b0be6817188302dc3 Author: Jeffrey Altman Date: Mon Aug 16 14:27:44 2010 -0400 Windows: Return error for SetToken PIOCTL_LOGON if not LocalSystem If the PIOCTL_LOGON flag is set and the user is not LocalSystem, return Access Denied. LICENSE MIT Change-Id: I25f042353fb8b70aba4fb01ba1a5b204470416f5 Reviewed-on: http://gerrit.openafs.org/2568 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit ce2422000446eed0e4a6edf926df4fe93206508d Author: Jeffrey Altman Date: Mon Aug 16 10:09:22 2010 -0400 Windows: prevent buffer overrun in cklog The Windows version of klog.exe will overwrite the realm and password buffers if the command line input is too long. Generate an error and terminate the program instead. Change-Id: I80671adcf92e9140f14a943b2677a352d2223eee Reviewed-on: http://gerrit.openafs.org/2558 Reviewed-by: Derrick Brashear Tested-by: BuildBot Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 22f6306cc8651f08841c66cd222c27c70ec5a00f Author: Jeffrey Altman Date: Thu Aug 12 01:48:16 2010 -0400 Windows: Only Local System Account may set tokens for alternate ids Only permit tokens to be set for alternate ids from the system account. LICENSE MIT Change-Id: Ibeaf16950b0317db99dfebccb9534697a258db78 Reviewed-on: http://gerrit.openafs.org/2541 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 5e8d0a7b5fc9711551d707ce3639e080450084a3 Author: Jeffrey Altman Date: Fri Aug 13 20:58:43 2010 -0400 Windows: Parse Freelance entries and enforce trailing dot but no trailing ws Make sure that there is a trailing dot and no trailing whitespace for both Mount Point and Symlink entries read from the Freelance registry key. LICENSE MIT Change-Id: I339d1bd2a8fc3e5f44362c65e872396adf64fdf6 Reviewed-on: http://gerrit.openafs.org/2555 Tested-by: Jeffrey Altman Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit e8bb948db17d7e4f734b9785f6f1b09c7efebde9 Author: Chaz Chandler Date: Wed Aug 4 11:17:03 2010 -0700 autoconf detection of label support acinclude.m4 now has struct label support detection and sets HAVE_STRUCT_LABEL_SUPPORT in afsconfig.h. Obviates complicated ifdefs in various src/afs/ and src/rx/ files. Must run regen.sh to generate new configure and afsconfig.h.in, then configure will detect label support and set afsconfig.h appropriately. Not sure what to do for Windows, but should be a step in the right direction. Fixes issue with compilation of libuafs on IRIX and sunpro by accurately detecting label support. Change-Id: I092eda47c4cfcc2517dc39f5e48b5038c413cb01 Change-Id: I2ff8449b28db645d9cfd27796b5f89e5c328a2b2 Reviewed-on: http://gerrit.openafs.org/2516 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 90b75531add729ecbcc46f2a6fb070993b96bcec Author: Marc Dionne Date: Thu Aug 12 16:33:04 2010 -0400 Linux: avoid oops in memcpy_toiovec With ADAPT_PMTU enabled, kernel_recvmsg can be called to receive errors. The call is made with no iovec supplied (we pass a NULL pointer), but with a size of 256. In the kernel, the memcpy_toiovec function tests for size > 0, and proceeds to check iovec->iov_len, which causes an oops. Fix by setting the size to 0. Change-Id: I3c672c2e67d0aa5af2bd54d0c14aaeae3bb3c530 Reviewed-on: http://gerrit.openafs.org/2546 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 08552ad8a94f7cc5908aabe8385711e09a6418e4 Author: Marc Dionne Date: Wed Aug 11 19:28:53 2010 -0400 Linux: Rework statfs super block operations configure test The configure test to detect if the statfs super block operation needs a dentry argument is based on vfs_statfs, and assumes that its signature matches the one of the operation. In 2.6.36 this is no longer true and the test fails. Rework the test to actually test the operation we're interested in. This change is required for 2.6.36. Change-Id: I5a712fb47e48c1bcc7ea2cfbf6c53c2b27627723 Reviewed-on: http://gerrit.openafs.org/2545 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fb01fbd7cd2d396df8a4605eaad9febc52ef3b61 Author: Marc Dionne Date: Wed Aug 11 18:55:29 2010 -0400 Linux: switch to evict_inode In 2.6.36, the delete_inode and clear_inode inode operations are replaced by evict_inode. Rename our current clear_inode to evict_inode, and add a few things that were previously handled by the generic delete_inode. This is required for 2.6.36. Change-Id: I68d75830b43df710ccce173ab36f3bb39074c59e Reviewed-on: http://gerrit.openafs.org/2544 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit eaf3378f537935f6b9843886b43d8b6d38a91a92 Author: Marc Dionne Date: Wed Aug 11 18:20:59 2010 -0400 Linux: adapt to truncate sequence changes As part of changes to the truncate sequence, inode_setattr() no longer exists, and all filesystems have to define the setattr op so we can assume that it is not NULL. Introduce a compat inline function afs_inode_setattr that hides the tests and the different versions from the main code. Note that the existing test for the inode_setattr() return type will fail, but the value is no longer used in that case. This is required for 2.6.36 Change-Id: I2f5e8a0b660b48453d0152b6c4db64e57539f91a Reviewed-on: http://gerrit.openafs.org/2543 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d4018b2673e6532543984838290ffb891b970fea Author: Marc Dionne Date: Wed Aug 11 17:18:32 2010 -0400 Linux: use %pI4 if NIPQUAD is not available The definition of NIPQUAD has been removed from the kernel headers in the mainline kernel. Replace it by using the %pI4 format specifier which takes the IP address as a single argument. There should be no change in the output. This fix is required for 2.6.36. Change-Id: I269e5bd754b7aef49b005081eb6b3af1b2679293 Reviewed-on: http://gerrit.openafs.org/2542 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3121a07fbfd4bf3991a933b80a9ad8f4cda285ae Author: Derrick Brashear Date: Thu Aug 12 00:48:45 2010 -0400 disable pmtu error gathering don't enable kernel pmtu, don't collect errors. a report from Marc Dionne suggests there are still issues here Change-Id: Ib54fa522ba53efe50e8f08b27422ebfc8af7f9e5 Reviewed-on: http://gerrit.openafs.org/2538 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 03f76092bdb6c011e539a125729efe330227f8b2 Author: Jeffrey Altman Date: Thu Aug 12 00:48:44 2010 -0400 Windows: comparisons of nul strings should match When comparing nul strings in cm_strnicmp_utf8 and cm_strnicmp_utf16 the functions should return 0. LICENSE MIT Change-Id: I30c1321f42135a5e0160407467549b13cc92393f Reviewed-on: http://gerrit.openafs.org/2539 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 3daf18a3cbadd1db07839708cf45426003a2bca5 Author: Andrew Deason Date: Tue Aug 10 14:16:39 2010 -0500 viced: VNOVOL on deleted volumes When the volserver deletes a volume, the fileserver should respond to future access to that volume with VNOVOL and not VOFFLINE, since the volume doesn't exist anymore. Do this in DAFS via a new state, VOL_STATE_DELETED, and in non-DAFS by just setting specialStatus to VNOVOL. In the future we should also make sure the vp's for deleted volumes get freed after a couple of hours, but not yet. Change-Id: I6dec3e0a5e9e54f6ad09fad9f2355b513cce3bf6 Reviewed-on: http://gerrit.openafs.org/2533 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 72da1d2eb2567f9e5e1b3d5aebc73654785f99a6 Author: Andrew Deason Date: Fri Aug 6 14:32:16 2010 -0500 volser: Ignore duplicate file tags when restoring Currently, if the volserver encounters multiple file tags for a vnode when restoring a volume dump, it will create extra vnodes which are not recorded anywhere, and are leaked when the volume is removed. Instead of doing that, ignore any duplicate file tags that are encountered (which is what happens with other tags), and log a warning. Change-Id: I1ac76b0217096d013db355b899f1a53174d20eb5 Reviewed-on: http://gerrit.openafs.org/2531 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f7d298d367cc5deea00a44601f845f543993ef09 Author: Simon Wilkinson Date: Wed Aug 11 23:14:31 2010 +0100 LINUX: More flock fixes Turns out the we have two almost identical lock routines on Linux, one for POSIX locks, and one for flocks. Fix them both. Also, while we're at it, make the same fixes in the LINUX24 tree. Thanks to Andrew Deason for pointing out the oversight in the original patch (5abe706a7e237d3872db3638d947a14c935370d5) Change-Id: I59f0f1e12af36a97e490df36537ac17e8ed87303 Reviewed-on: http://gerrit.openafs.org/2535 Reviewed-by: Andrew Deason Tested-by: BuildBot Reviewed-by: Jeffrey Altman commit 5a2ae98327520a6936d8bbe6b2a9128dc45a2406 Author: Derrick Brashear Date: Wed Aug 4 09:38:10 2010 -0400 fs discon support alternate uid this is a short-term hack. macos lacks pags, and anywhere without pags won't have tokens when fs discon online is run as root unless the tokens are explicitly set for root... which can be bad mojo. instead, allow a uid to be passed in. Change-Id: I44ebf9468976fa43d449f72d392fbb9e830e44d6 Reviewed-on: http://gerrit.openafs.org/2515 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e6aa0b38e9970ca10e498e03b0149f895edf9e73 Author: Derrick Brashear Date: Mon Aug 2 14:02:37 2010 -0400 macos disconnected vnode holding fix tweak how we hold vcaches to avoid issues with the underlying vnode having an iocount underrun due to races. Change-Id: I96526ed52c11aac1124a8cf66458ba3e25e7efb2 Reviewed-on: http://gerrit.openafs.org/2501 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5abe706a7e237d3872db3638d947a14c935370d5 Author: Simon Wilkinson Date: Wed Aug 11 17:25:36 2010 +0100 LINUX: Use correct type of error in flock code The flock code gets a kernel error code from afs_posix_lock_file() but then passes this error code through afs_convert_code (which sees that it is already negative, and returns EIO). Instead, we should just return afs_posix_lock_file()'s code direct to our caller. Change-Id: I28bbc2dc8535d28a4e9e9f564392fd4cbfa76569 Reviewed-on: http://gerrit.openafs.org/2534 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bc6fe06ae5829676b84028adc2aa088c8e69574f Author: Jeffrey Altman Date: Wed Aug 11 01:10:38 2010 -0400 Windows: cm_Analyze should treat VOFFLINE like VMOVED or VNOVOL Volume package bugs in the file server can result in VOFFLINE being returned to the client instead of VNOVOL or VMOVED. As a result the Unix CM treats VOFFLINE the same as VMOVED and VNOVOL. The Windows client has not. As a result, bugs in the file server can cause the Windows client to lose if the volume has in fact been moved to another server. As part of this change, the volume location list is updated prior to the volume status being applied to the server from which the error was received. LICENSE MIT Change-Id: I01036aa9d1999d0ba6822beb1b73500d365bf0b3 Reviewed-on: http://gerrit.openafs.org/2532 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 219ab91243b8c9c5ffbfa459047968145debee9c Author: Andrew Deason Date: Tue Jul 27 16:22:47 2010 -0500 salvage: update inodes array after CopyAndSalvage CopyAndSalvage makes a copy of the directory to salvage it. So, the new directory will have a new inode. Update the array of directory inodes to reflect this. Without this, we can fail to alter the copied/salvaged directory later on, since we will try to read/write to the wrong inode. Change-Id: I2466981e8ee54c5aecf1a166a37d8146b126de24 Reviewed-on: http://gerrit.openafs.org/2530 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9903f4805e27583a3483db412479fdc604fdd0b6 Author: Andrew Deason Date: Tue Jul 27 17:22:49 2010 -0500 salvage: Remove redundant 'code' declaration 'code' is declared at the top of SalvageVolume; no need to declare it again in a lower block. Change-Id: I9b48830c17e5043e6abcda4dd4dd3cc040031d9a Reviewed-on: http://gerrit.openafs.org/2529 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 56218cab39d522cb6911620bbf34d0236bfd3052 Author: Andrew Deason Date: Wed Jul 28 12:01:01 2010 -0500 salvage: Do not look at not-found root dir If we have not found any root directory, don't even look at 'oldrootdir' or 'rootdir', since they will be uninitialized at this point. Change-Id: Ia1a7037e06a223a7e1fbc48c0bfadd3b7aaa0e4b Reviewed-on: http://gerrit.openafs.org/2528 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1c002a5b5d29532b8c12097ad717c676a3285f28 Author: Andrew Deason Date: Wed Jul 28 12:00:37 2010 -0500 salvage: Zero corrupted header In the salvager, if we read in a corrupt header (either we get a short read or the magic is mismatched), make sure we zero out the contents, so we don't read garbage further on. Change-Id: Ifb4b9fc1b25d5eab470f0950a1d3bb240f75b0d3 Reviewed-on: http://gerrit.openafs.org/2527 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9da5e4700b81be7d78e4fc54bc4dd31d582be349 Author: Andrew Deason Date: Wed Aug 4 21:33:05 2010 -0500 tviced: Fix serialize_state.o objdir At least some makes treat ./serialize_state.c as only in the current dir, ignoring VPATH. So just specify serialize_state.c. Change-Id: I250886cb4bbfb955984b39c5a7d1a1acd5d9e0c4 Reviewed-on: http://gerrit.openafs.org/2524 Tested-by: Andrew Deason Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cdbf7827ef984be8342b284c7830c40dcef1335f Author: Andrew Deason Date: Wed Aug 4 17:08:37 2010 -0500 Eliminate $< outside of pattern rules The $< variable in makefiles is not portable when used outside of pattern rules. Replace each usage with the actual name of the file we want. Change-Id: Idc9309e7d7bd3b1bd93e8225507b8b53c9433d69 Reviewed-on: http://gerrit.openafs.org/2523 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 16bad29f0301db64c38bc66cb760c04399c0c7bb Author: Andrew Deason Date: Wed Aug 4 14:49:28 2010 -0500 Fix objdir install/dest targets Many 'install' and 'dest' targets were referring to source files without a srcdir prefix. Fix them so we can 'make install' / 'make dest' with objdir. Change-Id: Id76c5e326309baf8ec3f1213ecb2e40b19aea7d4 Reviewed-on: http://gerrit.openafs.org/2522 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 17a57cdafeac2b362e4edc50370962883f7ec052 Author: Andrew Deason Date: Wed Aug 4 14:01:51 2010 -0500 tubik: Fix objdir builds - Make netutils.c include afs/dirpath.h, so we don't have to find the correct include dir for "dirpath.h" - Fix dependencies in tvlserver, tbudb, and tptserver, and refer to sources in srcdir where appropriate Change-Id: Id9c2b3eefaa9d02ccb197a61341776444b958cdc Reviewed-on: http://gerrit.openafs.org/2521 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a5ff380e891db1c9ed0ec3875ce9b34d03976a8e Author: Andrew Deason Date: Wed Aug 4 13:59:35 2010 -0500 Fix afsd.fuse for objdir builds afsd_fuse.o could not find afsd_fuse.c for objdir builds. While we're here, make the afsd_fuse.o rule more closely match the rules close by. Change-Id: I675359134e2672cb36c9eb780edefb498d498bb1 Reviewed-on: http://gerrit.openafs.org/2520 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b832cdc1c7e462ca7c87ea16abdf694bac1bc272 Author: Andrew Deason Date: Wed Aug 4 11:19:35 2010 -0500 rxgen: Error out if cpp exits with error If we call 'cpp' and it returns with an erroneous exit code, exit with an error ourselves. Otherwise we will return success and generate empty results even if the input file is unreadable, for instance, which causes confusing errors later in the build. Change-Id: Ia12dc58eee0937a6bd529dcd6b552e253dbc40c8 Reviewed-on: http://gerrit.openafs.org/2519 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a4267ef14008daad45c1a64edf5649fc6bb333f0 Author: Derrick Brashear Date: Fri Jul 23 11:27:46 2010 -0400 namei decodevolume allow low volume ids the smallest thing which can be encoded is a single character; also allow it to be decoded, such that low numbered volumes are treated as valid. Change-Id: Ia5e694f7f73e1035af741bd23c7f50805910d0c4 Reviewed-on: http://gerrit.openafs.org/2470 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit aa24d1392c31dc725a85ffe179adf6eca2fa683f Author: Jeffrey Altman Date: Thu Aug 5 15:07:47 2010 -0400 Windows: add flags field to smb_ioctlProc_t function signature Add a general framework to permit flags to be passed into the smb ioctl interface functions. This patchset does not define any such flags. LICENSE MIT Change-Id: I9a894a186c4ca455116ea79bdd6c3cc0d02a2dc3 Reviewed-on: http://gerrit.openafs.org/2525 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit ed428869276d07e8dc886a1ee02893bb9cc09e1f Author: Simon Wilkinson Date: Sat Jul 24 14:21:52 2010 +0100 Unix CM: Remove erroneous comment Despite what the comment says, shutdown_axscache does have a caller, so just remove the comment lest it confuse people. Change-Id: I0491bf4f945c372d7ddbafb7a43390821c95a0c1 Reviewed-on: http://gerrit.openafs.org/2471 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f6a91a28ccd38cdaa917cbd140c567dbd1651322 Author: Jeffrey Altman Date: Thu Aug 5 01:43:24 2010 -0400 Windows: optimize buf_FlushCleanPages If the pages to be flushed are from a readonly or backup volume they can't be dirty. In this case there is no need to stabilize the pages before they are locked and recycled. Stablilization is performed on the cm_scache_t object so do not stabilize and unstablize for each cm_buf_t object. LICENSE MIT Change-Id: I6fa86cf0a33dc9f45d77911909e799c0fc6510cf Reviewed-on: http://gerrit.openafs.org/2518 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit f08e953e62148bd2f9200040a8e34ef07b51b35d Author: Andrew Deason Date: Wed Aug 4 22:49:29 2010 -0500 Unix: docbook revision tag requires a date The docbook DTD requires a element to contain a element. So make a blank one even though we don't keep track of a date, so we can pass xmllint. Change-Id: I06e68b756d215ec3ce279561a05b5bc5fc418028 Reviewed-on: http://gerrit.openafs.org/2517 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d0080e261cda46f53b952a0e5133fb94414f17a9 Author: Andrew Deason Date: Tue Aug 3 17:32:11 2010 -0500 Add DAFS docs to the Unix Quick Start guide Modify the sections dealing with creating the 'fs' bnode to also mention how to create the 'dafs' bnode, and add an appendix explaining DAFS and the differences between DAFS and non-DAFS. Change-Id: I026405dbc3838a9a0247b85cbdc508d6be93275d Reviewed-on: http://gerrit.openafs.org/2508 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ae1ac72783dee7cfd23538e95a1ad358a17373cc Author: Andrew Deason Date: Tue Aug 3 12:01:07 2010 -0500 HPUX: Add limits.h to sysincludes xdr_mem uses INT_MAX, so we need limits.h in the kernel for HP-UX. Change-Id: I5c75f9d3cb9cfd5da78cf625f042c1dee862dcd7 Reviewed-on: http://gerrit.openafs.org/2506 Tested-by: BuildBot Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8e5d6ce1506cc9e65ad51b1c5f76e0a29616231c Author: Derrick Brashear Date: Wed Aug 4 09:22:20 2010 -0400 fix unlabelled xdr field order on sun457 kernel for now alternate to 2503 (which we will push after branching) Thanks to Andrew Deason for discovering this issue. Change-Id: I3a43bb1eab1a753f099c9d21e440f6660c706e37 Reviewed-on: http://gerrit.openafs.org/2514 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7556326e012c74a21c2459c19cdf8317b5156f2a Author: Derrick Brashear Date: Wed Aug 4 09:04:34 2010 -0400 discon remove dirty vcaches from queue when discarding the discardall loop was not dequeueing vcaches, meaning we would loop. caught by Simon Wilkinson Change-Id: I80256ef5f91d7030e0cb11e78a79f137a217a29a Reviewed-on: http://gerrit.openafs.org/2513 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6d0b97c7ac89219c0b708d1afbd4d7b8c8ec717d Author: Derrick Brashear Date: Wed Aug 4 09:02:54 2010 -0400 reorder vcache references in discondiscardallshadows reset the vcache before we (nominally, it's still under a lock) discard it. remove superfluous shadow clearing. Caught by Simon Wilkinson Change-Id: I55b91fa4f2f92a8b6fd1f8117c2448f7a7d1d98a Reviewed-on: http://gerrit.openafs.org/2512 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 85e29294eef44fcc52b0583c70debcae452e829d Author: Derrick Brashear Date: Wed Aug 4 09:00:58 2010 -0400 discon getparentvcache leak fix don't leak an unref'd vcache pointer if we are returning an error (EAGAIN). thanks to Simon Wilkinson for catching this. Change-Id: I40c5aa0fd50e1f2c76b09ba073a7109bca706d8c Reviewed-on: http://gerrit.openafs.org/2511 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9bfae6b76c4e27c77299df149a42aebb406c653e Author: Derrick Brashear Date: Wed Aug 4 08:42:16 2010 -0400 discon needs static_inline macro don't use static inline keywords in common code. Change-Id: I29cbe312e27c8fb75d2d07f720789a4a5b900fa5 Reviewed-on: http://gerrit.openafs.org/2510 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b82ac032a6ac99db18019bfedf4100c9354a140c Author: Derrick Brashear Date: Wed Aug 4 08:41:00 2010 -0400 darwin unused prototype we don't gave our own vn_rele. don't prototype it. Change-Id: I3a2d193c95a2d63c8d80054dd4600f949d1a01d2 Reviewed-on: http://gerrit.openafs.org/2509 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a5bcd61a16a3d6b0b458f4710c0d537cfee7743d Author: Andrew Deason Date: Thu Jul 29 14:47:03 2010 -0500 util: add afs_exec_alt Add the function afs_exec_alt to help programs easily execute an "alternate" version of themselves. For example, for programs that are built with/without DAFS support, or are built for 32-bit/64-bit structures, etc. Change-Id: Ibb2b7105d58476f84bd9f15987f8b7df37314b6b Reviewed-on: http://gerrit.openafs.org/2483 Tested-by: Andrew Deason Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6b6535279a558d0d25b95e4ab4038e7ac9699797 Author: Andrew Deason Date: Tue Aug 3 15:44:52 2010 -0500 tbudb: Use INSTALL_PROGRAM, not INSTALL -f "$INSTALL -f" is not portable. Use $INSTALL_PROGRAM instead. Change-Id: I5013476cc036350b0b61b6e3c01a86d303aa70b6 Reviewed-on: http://gerrit.openafs.org/2507 Reviewed-by: Derrick Brashear Tested-by: BuildBot commit ba7d8d78104d870e9c1d984ac10843918513eef1 Author: Jeffrey Altman Date: Mon Aug 2 23:28:39 2010 -0400 Windows: Reduce complexity of Freelance Callback Logic Over the years the processing of the Freelance callbacks have added functionality that behaves much more like FetchStatus checks to a file server. If the data version of the object has changed, get the new data. Given that is the case, we can remove much of the original refresh logic that is rather race prone. Say goodbye to cm_fakeGettingCallback and cm_fakeDirCallback. LICENSE MIT Change-Id: I249c84201afc16611039b2ba0801a643fcf05f28 Reviewed-on: http://gerrit.openafs.org/2505 Tested-by: Jeffrey Altman Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit a03f1960da3a68cd8453960302be0319a7bb45ae Author: Jeffrey Altman Date: Mon Aug 2 16:06:39 2010 -0400 Windows: When processing pioctl paths ensure callbacks are obtained When processing a pioctl path with either smb_ParseIoctlPath or smb_ParseIoctlParent, cm_SyncOp(CM_SCACHESYNC_NEEDCALLBACK|GETSTATUS) must be called on the cm_scache_t object to ensure that it is up to date before we permit cm_Lookup or other operations to be performed on it. Add the cm_SyncOp() call to smb_ParseIoctlPath and smb_ParseIoctlParent to ensure it is done for all pioctl operations. LICENSE MIT Change-Id: I2fe5d5ec2567693155277b40929dedb8155d9ebf Reviewed-on: http://gerrit.openafs.org/2504 Tested-by: Jeffrey Altman Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit fccd35961f1f3324df7dbdea03790ee0b525d9f1 Author: Derrick Brashear Date: Mon Aug 2 14:51:39 2010 -0400 fs disconnected remove ifdefs disconnected is always on; remove the ifdefs around it Change-Id: Iaa982f83f7619fc0ad1162a64b68231e02eae916 Reviewed-on: http://gerrit.openafs.org/2502 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit deb96d3986bedc1defc921b88abb88e4aefb55e4 Author: Jeffrey Altman Date: Mon Aug 2 13:30:30 2010 -0400 Windows: docbook revision tag requires a date Even if we can't generate a date, we must include the date tag within the revision tag in order for the docbook dtd to be applied and pass xmllint. Change-Id: Ic58995ecd7b07a1163f0965e22bcd78769d4565e Reviewed-on: http://gerrit.openafs.org/2500 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit c5ffaf7a3c179c77398e1d0a007b870a9c45e053 Author: Asanka Herath Date: Sat Jul 31 04:30:10 2010 -0400 Windows: Don't configure client when not installing client The 32-bit tools installer was displaying client configuration wizard pages. Since, the 32-bit tools share configuration with the AFS service, the 32-bit tools installer should not be attempting to change client configuration. Remove said wizard pages from the 32-bit tools installer. Change-Id: Ib52b5741d5d412b1aea1856e0304364ed928b2ba Reviewed-on: http://gerrit.openafs.org/2492 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 60878f4d2a6f5d02f067efead99d371eafe6668b Author: Asanka Herath Date: Sat Jul 31 13:07:44 2010 -0400 Windows: Fix MC options Newer versions of the Message Compiler included with Windows SDKs break when using the -s option. Remove it. Change-Id: I71bcd2d5aa000b11c44b77ce4687bc0f070699b0 Reviewed-on: http://gerrit.openafs.org/2495 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 5e946d5b6672d4dea7dd1c3ee669245b3d2ced92 Author: Andrew Deason Date: Fri Jul 30 15:32:53 2010 -0500 ptserver: Do not use cell for entry name len check Do not use the local cell name when determining if a new entry name is too long. This check assumes that foreign cells will use our local cell name (assumed to be our local Kerberos realm) in a certain way, and prevents creating users that will make those names too long. This is undesirable for several reasons. One is that the local realm name may not be the same as the local cell name (and we may have many local realms). Another is that we cannot reliably predict how foreign cells will construct foreign pt entry names, so preventing entry creation based on that may prevent names that will never cause any problems. This check also assumes that our names will be used as foreign entries in other cells, which may not be the case. So, remove the check based on the local cell name, and remove the pr_realmNameLen variable while we are at it, since this is all it is used for. Thanks to Jeffrey Altman for discussion, and for bringing this up in the first place. Change-Id: Ief4bc94d9ead61a1589797b5dc663a6473c9ed72 Reviewed-on: http://gerrit.openafs.org/2488 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 89afd3c21e816c29f497c10cf76673d009cdd919 Author: Jeffrey Altman Date: Sat Jul 31 00:21:06 2010 -0400 Windows: Do not reference cm_data.rootSCachep directly cm_data.rootSCachep is a global pointer to the cm_scache_t that represents the root.afs volume root directory. Throughout the code this cm_scache_t was being used without ensuring that a callback to the volume is in fact valid. Under most circumstances this would not be a problem. However, it is possible for a request to fail due to the lack of a callback at a critical moment. Add a new function cm_rootScachep() that attempts to ensure that a callback is present (if possible) prior to use the cm_scache_t object. LICENSE MIT Change-Id: I997dc05a2214788d32727c261947206a61cd8d32 Reviewed-on: http://gerrit.openafs.org/2491 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 78f99d4a025d3b369d3ad4939098ea868feb6cfc Author: Jeffrey Altman Date: Sat Jul 31 00:05:24 2010 -0400 Windows: Update root.afs scache dv when Freelance dir bufs are regenerated When the contents of the Freelance root directory changes the fake directory buffers are updated and a fakeDirVersion is incremented. The dataVersion of the cm_scache_t object is supposed to be updated on the next access by performing a fake get callback request. Unfortunately, this did not always occur because of a race. If another Freelance object is updated first, the root directory object would never successfully get a fake callback. This patchset ensures that the generation of the fake directory buffer content and the callback are obtained under the same set of locks thereby removing the race. LICENSE MIT Change-Id: Ic8c77fc3c652cd056f84db55ca6db32499bcb0c9 Reviewed-on: http://gerrit.openafs.org/2490 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 9ec343cf4292e178fa1e4a9757232dc983ea9ba3 Author: Jason Edgecombe Date: Sun Aug 1 21:39:56 2010 -0400 Factor out the common text in vos_addsite, vos_copy, and vos_zap Factor out some common options out of the man pages. LICENSE IPL Change-Id: Ic79e53a2d6464cc62d49987ab58d38c9898f372b Reviewed-on: http://gerrit.openafs.org/2496 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 78dcbd11d49bf9ae078639d067832fdf331daaa1 Author: Asanka Herath Date: Sat Jul 31 12:43:47 2010 -0400 Windows: Build preprocessed POD documentation Change-Id: I0b849bf52094a1b6ca0e45db5e2f92ff58b8efba Reviewed-on: http://gerrit.openafs.org/2493 Reviewed-by: Jeffrey Altman Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 39643598a216c2e892cd94ccb441180a4c4f949e Author: Andrew Deason Date: Mon Aug 2 00:44:37 2010 -0500 SOLARIS: let xlator load if amd64/nfssrv is loaded The NFS translator-enabled kernel module refuses to load if misc/nfssrv is not also loaded. We were only checking misc/nfssrv and misc/sparcv9/nfssrv, though, not misc/amd64/nfssrv. Check that, too, as it may be loaded on amd64 machines. Reported by Robert Milkowski. Change-Id: Idbb9c4136b87ffa4c72ca376738001fb6a3ca7d8 Reviewed-on: http://gerrit.openafs.org/2497 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c53513e834ab965daebb5ce433cd6b7dc88dab8e Author: Jeffrey Altman Date: Mon Aug 2 09:49:26 2010 -0400 Windows aklog: remove lstat preprocessor definition lstat is now defined globally in the build system. remove redundant definition. LICENSE MIT Change-Id: I91f90f571ffd2dfe1544ce17b50e5577acc5adbc Reviewed-on: http://gerrit.openafs.org/2499 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 571204f343014d5f84ddbcf4ad63a8ebd469f006 Author: Jeffrey Altman Date: Mon Aug 2 09:48:07 2010 -0400 Windows aklog: include afs/pterror.h pterror.h is required for initialize_PT_error_message LICENSE MIT Change-Id: Ie487c6b03ff6ca4cac30ccac9f2a67fdd89e6aaa Reviewed-on: http://gerrit.openafs.org/2498 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cf0d7fea04923b39ccae0e9083c525b91642f49d Author: Asanka Herath Date: Sat Jul 31 04:00:41 2010 -0400 Skip over 'fragments' directory when scanning for PODs The generate-html script scans the directories to compile a list of POD files. The list of candidates include the 'fragments' directory, which causes an error when the script attempts to open it as a file. Change-Id: If1208561f58f869ccba60f4a263bee5200dad1ed Reviewed-on: http://gerrit.openafs.org/2494 Reviewed-by: Jeffrey Altman Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit ebf36d27c66f18d8fa88ec8f7cacec3ef0c311d7 Author: Andrew Deason Date: Fri Jul 30 12:03:06 2010 -0500 ptserver: Allow longer foreign user names The ptserver was restricting all names to be less than PR_MAXNAMELEN - pr_realmNameLen - 1, so that the local realm and a '@' can be safely appended for foreign user registration. This check is overly restrictive for foreign users, since the local realm will never be appended to the user name (it already has the foreign realm name appended). So, just check for PR_MAXNAMELEN for foreign users. Original issue reported by Gunnar Krull. Change-Id: I34c5d908cc2c1b3abe87966115e6ada74c9a93a9 Reviewed-on: http://gerrit.openafs.org/2485 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 429feee73d977b7329ec258d5c1aa369b8f349c6 Author: Andrew Deason Date: Fri Jul 30 14:45:29 2010 -0500 Document krb.excl Change-Id: I0ac49b6d705190f877f6b09b69a3efe24b5c3d8e Reviewed-on: http://gerrit.openafs.org/2487 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b0a003fd8d3d1d34dbd6248bf1acec141954f080 Author: Ben Kaduk Date: Fri Jul 30 21:20:06 2010 -0400 FBSD: update ifa_ifwithnet usage FreeBSD 8.1 (and 9.0) now require a second parameter to ifa_ifwithnet. Fix the build by using the same macro as OBSD46. Change-Id: I22eac8722bef79b6349b9d879eb42d63450b362e Reported-by: Jan Henrik Sylvester Reviewed-on: http://gerrit.openafs.org/2489 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ea8be82b95972d46882e8e7fce91a1973c966049 Author: Andrew Deason Date: Thu Jul 29 13:02:47 2010 -0500 Document the 'vos offline' -busy and -sleep opts Change-Id: I68d374a206a398467e5980a87b3ca2ad41bf9653 Reviewed-on: http://gerrit.openafs.org/2482 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 11854c734adb7e184484c262d244401be6656eee Author: Andrew Deason Date: Thu Jul 29 12:43:25 2010 -0500 Remove bless-related options from vos manpages 'vos online' and 'vos offline' were documented as taking -bless and -unbless options, respectively. They do not actually take these options, and since adding that functionality, while useful, will require protocol changes, they are likely to take some time to appear. Change-Id: I91800e9637162e24873beac5d41f3ad456f25af8 Reviewed-on: http://gerrit.openafs.org/2481 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 56cf5a9f5f61207b449e9b62e9f926a7dc488575 Author: Andrew Deason Date: Thu Jul 29 10:36:56 2010 -0500 Install DAFS and non-DAFS fssync-debug Install the non-DAFS fssync-debug along with the DAFS dafssync-debug, since fssync-debug uses some structures that are specific to DAFS or non-DAFS. Change-Id: Ib7420857cd32f33fc3cc04f67baa1fcc90abc936 Reviewed-on: http://gerrit.openafs.org/2479 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 134f58cd8ca3d941bcea6e9f56d8fc7d0c91d7e0 Author: Derrick Brashear Date: Thu Jul 29 10:59:35 2010 -0400 macos prefs pane improved error handling NSScanner: nil string argument is a lame thing to see. so let's not. Change-Id: I972ed9ebe5a9f7ef5ae9ecbd0423a61bd5bfb5b7 Reviewed-on: http://gerrit.openafs.org/2478 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3a0efeebf63a721068165b3f55600c8eef9faab2 Author: Andrew Deason Date: Wed Jul 28 17:10:10 2010 -0500 viced: Correct unblessed attach2 errors Don't set the vp to NULL; instead just go to the general error handling code. When a volume is not blessed, we just want it to go offline, not go into an error state. Furthermore, we must free the volume header when nUsers is set to 0, so manually do so when we do not call VRequestSalvage_r. Change-Id: I3ccd61ac219e092a5c9ee52cd563d007bc20a1a1 Reviewed-on: http://gerrit.openafs.org/2476 Reviewed-by: Jeffrey Altman Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ec5f7f0e0284b38b86c32c2dfc842b08aca720ff Author: Andrew Deason Date: Wed Jul 28 17:47:21 2010 -0500 vol-bless: Detach, not put, volumes on completion vol-bless was just calling VPutVolume when it was done blessing or unblessing a volume. Instead call VDetachVolume, so we actually give the volume back to the fileserver when we are done if !nofssync. Change-Id: Idc1e0c32cf5c1c9d2c130fee4b2f1a5f61ab1c3a Reviewed-on: http://gerrit.openafs.org/2477 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit e2bce5f6c6cd8d2da40bd830640d87ebb9c0b6e9 Author: Marc Dionne Date: Mon Jul 12 19:28:24 2010 -0400 gcc 4.5: Sequence point warning fixes With gcc 4.5 the -sequence_point warning triggers some new warnings. Fix some of them by simplifying the arguments to some problematic macros. Change-Id: I6c4e2b09f3f9d07d342b7be0d6d8317673dddf34 Reviewed-on: http://gerrit.openafs.org/2474 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 43f3a074f09d34ce2da9bae2237b3a44cb4cac8b Author: Derrick Brashear Date: Mon Jul 26 16:15:46 2010 -0400 unix blacklistonce should default to fail if no fid return fail, rather than success, if no fid and thus no list of servers to resort, in BlackListOnce. will need a later change for vlservers reported by jhutz@cmu.edu Change-Id: I782781ed87a6de718a4cc3dbe2f948ef325af27c Reviewed-on: http://gerrit.openafs.org/2473 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 91eec4d85016b009a9661e98651dfbaa32618d3d Author: Andrew Deason Date: Thu Jul 22 13:43:17 2010 -0500 salvage: Zero root/readme vnodes before writing Previously we were writing out the root and readme vnodes with uninitialized 'lock' structures, when we create a new root dir for attaching orphans. Just use calloc so we ensure that everything is zeroed before writing it out. Change-Id: I3c7712254aaef8731be95ea63530af05438d96a6 Reviewed-on: http://gerrit.openafs.org/2469 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1ad26bc193f6b7693888054e4ddb96cf5fd260ee Author: Andrew Deason Date: Thu Jul 22 12:21:14 2010 -0500 autoconf: Force absolute INSTALL Force using an absolute path for install-sh. Autoconf normally prefers using a relative path, which confuses (at least) part of the libafs build system. Change-Id: I6962e61bb866362f674708e611ff22eb190a771a Reviewed-on: http://gerrit.openafs.org/2461 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit be469a890416eb139424890567037a17954a654c Author: Andrew Deason Date: Thu Jul 22 11:24:10 2010 -0500 Remove tsalvaged warning inhibition tsalvaged has no documented necessary warning inhibitions, and it appears to cause no warnings. So, remove the warning inhibition. Change-Id: Iac2f8e8657034b01ce705dddb5dab3f33c913f31 Reviewed-on: http://gerrit.openafs.org/2467 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a68abf7a4eeb0667fa067a73e4560b8666e7172a Author: Andrew Deason Date: Thu Jul 22 11:34:24 2010 -0500 AFS_INT64_FMT takes a afs_int64, not int64_t Cast to afs_int64, as int64_t can reduce to a different type than AFS_INT64_FMT's. Change-Id: I77ffe8813fbef284e6e91db25804d95d73898b54 Reviewed-on: http://gerrit.openafs.org/2466 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3d1fd051b6a5c6e3bf04663d88bc0366d7e7e854 Author: Andrew Deason Date: Wed Jul 21 17:30:39 2010 -0500 Log lex/flex detection errors in the config log When we detect if lex is flex, we run 'lex --version', which may complain to stderr if lex is not flex. Instead of printing such errors to the person running 'configure', redirect stderr to config.log along with stdout. Change-Id: I812805245a2638eda5885a41a6d70ffeff608c58 Reviewed-on: http://gerrit.openafs.org/2462 Tested-by: Andrew Deason Reviewed-by: Russ Allbery commit d64948ac30d3aefda098727a2158406144877654 Author: Derrick Brashear Date: Wed Jul 21 12:06:39 2010 -0400 vlserver - Don't overflow buffer with backup pattern based on a report from Hans-Werner Paulsen avoid adding regex anchors to a buffer which is already full when copying it to a like sized buffer. instead, leave extra space. Change-Id: I486c51779da285888fe38ed2aa5f30dd2d008a9a Reviewed-on: http://gerrit.openafs.org/2456 Reviewed-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e80bc73142188af82611f2174413091191be7818 Author: Andrew Deason Date: Wed Jul 21 12:01:57 2010 -0500 Remove an outdated inode comment block This comment is no longer true, and its existence now is just confusing. Change-Id: I3954bd82f11c5f48e3e9491a885087067b3d9d34 Reviewed-on: http://gerrit.openafs.org/2458 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e75eb34b9a38127b2f166a702e5a641847448823 Author: Andrew Deason Date: Wed Jul 21 12:17:33 2010 -0500 SOLARIS: do not ignore libafs build failures Change-Id: Ic5bc6cefd616736d81807bf6ac6d0226fcdb3df2 Reviewed-on: http://gerrit.openafs.org/2459 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 41d321e900ccb99120a49980c24d44f206075f17 Author: Russ Allbery Date: Wed Jul 21 10:36:21 2010 -0700 Don't cd around invocations of install-man install-man is a config.status-generated script, so Autoconf will substitute in the path to our install-sh script, but Autoconf prefers relative paths that are only valid in the directory in which install-man is generated. We therefore must avoid changing directories before calling install-man. Instead of cd, use relative paths including the directory and adjust the installation path accordingly. Change-Id: I8666257b9d74fa80cf7f136bd0ee6ff895897066 Reviewed-on: http://gerrit.openafs.org/2460 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f0a52e168c0f3495c7b168a63c149116219e3c1b Author: Andrew Deason Date: Wed Jul 21 11:34:39 2010 -0500 libafs: fix IOPEN for amd64 solaris Solaris afs_syscall_iopen was returning the fd in r_val2 for 64-bit architectures (for 5.7 and beyond). If we are little-endian, though, we want the return value in r_val1; otherwise we just always return fd 0. So, put the fd in r_val1 if we are little-endian. Change-Id: I8553c338625e9c50f846f4676b53ea8f054b7a73 Reviewed-on: http://gerrit.openafs.org/2457 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b3c16324edf9e26ef4eea63d214d9d18ecaba30b Author: Andrew Deason Date: Tue Jul 20 12:46:00 2010 -0500 ubik: Make ugen_ClientInit honor noAuthFlag ugen_ClientInit was still trying to use tokens to make an authenticated connection, even if noAuthFlag was set. Make it so we do not attempt authenticated connections with noAuthFlag, and suppress the "Could not get afs tokens" message if noAuthFlag was set. Change-Id: I1a0afbb8507307f09a3555e6a7ce0c197ddcc6ef Reviewed-on: http://gerrit.openafs.org/2454 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e46f10a0a0a930f318833a8a86b10c19744160c1 Author: Andrew Deason Date: Tue Jul 20 12:32:10 2010 -0500 bos: Do not assume DAFS just if DAFS bnode exists For salvaging purposes, we were assuming that if a DAFS bnode existed, we should perform a DAFS salvage. Since it is possible to have a disabled DAFS bnode alongside an enabled non-DAFS fs bnode, we should perform a regular non-DAFS salvage if the DAFS bnode is disabled. Do that. Change-Id: If4e6fa3b733e2e9684cd9942be56368d60bf6dee Reviewed-on: http://gerrit.openafs.org/2453 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit b0f16e6a564f305bb7751e946d85a4e70fa50625 Author: Andrew Deason Date: Tue Jul 20 12:06:57 2010 -0500 bozo: Clean up bnode parms for each bnode bosserver was remembering the parms for past bnodes, and just overwriting parms for new bnodes. This is a problem if we have a 'dafs' bnode followed by an 'fs' bnode, since the 'fs' bnode will get the 'dasalvager' parm, and bosserver will think it is its scanner program. So instead keep track of a separate array of the parms that we actually pass to bnode_Create, so we only pass parms that we saw for this specific bnode. Change-Id: Ic609e2156cfd8ecf5b83b3815c5dff235010aa00 Reviewed-on: http://gerrit.openafs.org/2452 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 901423b1e566a91b0c10ecb1da1a9886e0877adf Author: Jeffrey Altman Date: Tue Jul 20 00:05:18 2010 -0400 Windows: Build Demand Attach File Service This patchset permits the building of demand attach file server and volume server. Change-Id: I7ee81c69924cde5e8aec2067d73b51cba7e4423e Reviewed-on: http://gerrit.openafs.org/2450 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 939382c5c1622750665a9f543168bd3b8044583f Author: Derrick Brashear Date: Mon Jul 19 14:17:21 2010 -0400 vol AttachByName should mimic other volpkg errors if later callers will deem a volume offline, note it at attach time. additionally, log the cause. Change-Id: I4870e8f3bfd8d7e69e448d3a445be81435407f0f Reviewed-on: http://gerrit.openafs.org/2448 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit eb6914dbb30b211653d6e66f23c31e81d410c9ae Author: Derrick Brashear Date: Mon Jul 19 16:56:58 2010 -0400 ShakeLooseVCaches needs to avoid CVInit vcaches the code refactoring missed this case. sadly, it means we can panic under heavy vcache contention. FIXES 127645 Change-Id: I41929df066b8e3d447ba72e77be6777a306b8bf8 Reviewed-on: http://gerrit.openafs.org/2449 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9c9b4bb8279f62bfd0888a8d7d081ba53ace3c4c Author: Derrick Brashear Date: Fri Jul 16 13:48:05 2010 -0400 document dasalvager split dasalvager and salvager documentation. refer both ways between docs. Change-Id: I33480cae671c3f50d47a5a4f8407a07f268164a1 Reviewed-on: http://gerrit.openafs.org/2442 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6f29ed951fca8f843e0a607fae97dd107f44d21c Author: Derrick Brashear Date: Fri Jul 16 13:39:22 2010 -0400 document davolserver split davolserver and volserver documentation. refer both ways between docs. Change-Id: Iac70ac8e1fb8bfcb7ebfdbed8e9d7870a2e69fee Reviewed-on: http://gerrit.openafs.org/2441 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 214f8ea022ad57d9f99346f4d24ed3c7409d8054 Author: Derrick Brashear Date: Sun Jul 18 11:45:06 2010 -0400 dafileserver synopsis missed this before, needed for dafs man page Change-Id: Ie9a309995638ea315198ea204cbc16e2cdc3fbe7 Reviewed-on: http://gerrit.openafs.org/2447 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c15a8c65ad232349b202fcf67a4f5037aaec02c8 Author: Derrick Brashear Date: Fri Jul 16 13:21:57 2010 -0400 document dafileserver split dafileserver and fileserver documentation. remove dafs-only switches from fileserver doc. refer both ways between docs. Change-Id: Ibcac8ed3f294c18436978f3cd4e52de305130198 Reviewed-on: http://gerrit.openafs.org/2425 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5142922d6ff019fc30d78c4a5eab29fa5fc1db30 Author: Andrew Deason Date: Tue Jul 6 12:42:40 2010 -0500 vos status: report human-readable last*Time Make 'vos status' print the lastReceiveTime and lastSendTime in a human-readable format, instead of just printing the number of seconds since the epoch as an integer. As suggested by Jeffrey Altman. Change-Id: I1348a45078e49ff631cb46323767f1c384a72084 Reviewed-on: http://gerrit.openafs.org/2338 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 48758397aecb98672783d8d5960e638d76e5e19c Author: Andrew Deason Date: Tue Jul 6 12:38:21 2010 -0500 vos status: add lastActiveTime field Add a field in the 'vos status' output to report the last time a transaction was touched by a volser RPC. Change-Id: Ibfe11e16fc3d7f00134d840ec3ab9fb9263fbea1 Reviewed-on: http://gerrit.openafs.org/2337 Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 36af430c29bdbfc1b4b5c1ad7568cbffab04899f Author: Andrew Deason Date: Tue Jul 6 12:36:27 2010 -0500 vos status: actually show created time The 'created' field in 'vos status' output was being reported as something else. Make 'vos status' actually report the time the transaction was created in that field. Change-Id: Ib890256f4b9f67cf0a37910dc3b3585eafdba4fc Reviewed-on: http://gerrit.openafs.org/2336 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dd3e0d0371608b0348435e94cc3c6c8f20d92b83 Author: Simon Wilkinson Date: Sat Jul 17 18:23:30 2010 +0100 dir: Add printf format checks to log salvage.c uses the Log() function defined by vol/common.c. At the moment, this isn't defined in a way that we can easily grab its prototype, so the code has an extern definition at the beginning. For now, just add format checks to this definition. Fix all of the fallout from this - we were casting to intptr, and printing with %x - use AFS_PTR_FMT as nature intended. Change-Id: I2110ebddbe207c307fcad00ab89e5818824a644d Reviewed-on: http://gerrit.openafs.org/2446 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8b5bf6ed9eb8404f8b9576c440d82a7691bcb77a Author: Simon Wilkinson Date: Sat Jul 17 18:06:39 2010 +0100 budb: Add printf format checks to logging fns Add format checking to the Log, LogError and LogDebug functions. Fix the resulting type errors. One of these in particular is a signficant bug, where we would try to print a hash table pointer as a string. Change-Id: I02d7bcd7ce63583d24dda4da40288af51a516583 Reviewed-on: http://gerrit.openafs.org/2445 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 52c91be7ca3c834c470fc739696dffe5fd01c0fe Author: Simon Wilkinson Date: Fri Jul 16 23:20:27 2010 +0100 vol: Fix logging functions Fix the Log, Abort and Quit functions used by the vol package so that they are all defined in a common header file, rather than prototyped in each file which uses them. Use the appropriate macros to flag those functions which never return, and mark them all as taking printf style input. Fix all of the callers which had mismatched format strings and arguments. Change-Id: I78194f623360e13f055f8f37b3558c08a70acd1f Reviewed-on: http://gerrit.openafs.org/2444 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a495e0ff6b7f3ee07b77363fa513d24024199f38 Author: Simon Wilkinson Date: Fri Jul 16 21:58:33 2010 +0100 Linux: Load exportfs first The changes to use the exportfs interface to access cache files require that the exportfs module is loaded before our module. In 'normal' operation depmod, and modprobe, would take care of this for us, however our legacy installation format where we ship the kernel module outside of /lib/modules stops modprobe from working, and our init script uses insmod. So, explicitly load exportfs first. Note: I'm aware of just how much this sucks, and the fact that we really should just tidy up all of the packaging and init scripts around our kernel module - but this close to 1.6 branch is probably not the time for those kinds of changes. Change-Id: Icdc11482f4eb05419a806a2cd55852eaa5999638 Reviewed-on: http://gerrit.openafs.org/2443 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ce109a8538e16090ee7960991ed1260aac54137a Author: Russ Allbery Date: Thu Jul 15 10:18:03 2010 -0700 Rename configure.in to configure.ac Rename configure.in and configure-libafs.in to use the *.ac extension instead, which is preferred by current Autoconf versions for input files to Autoconf. *.in can then be more consistently used for files that are input into config.status. Change-Id: I4d352560200e4dbb1a2dda3d5ab7c7c9a38b565f Reviewed-on: http://gerrit.openafs.org/2437 Reviewed-by: Derrick Brashear Tested-by: Russ Allbery commit a792acdadc8fe6e7354be4c23e60c795b3b4f109 Author: Russ Allbery Date: Thu Jul 15 17:21:26 2010 -0700 Add include method for POD documentation Add a preprocessor for POD documentation that handles a custom =include directive. Demonstrate how to use the preprocessor by factoring out all the standard PTS options into a separate POD fragment and including that fragment in all the PTS commands that take the standard options instead of including that documentation in each separate file. Change-Id: If5255efc6d3fc670b38a9898b3d7d3c60af04fcf Reviewed-on: http://gerrit.openafs.org/2440 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3e2c3c9a56fbffd0dc63183dcb053f942b6a2bf6 Author: Russ Allbery Date: Thu Jul 15 17:18:12 2010 -0700 Fix unterminated B<> sequence in bos addhost man page Change-Id: Ied06fbf8c0a9cc064b257daf6272cd5a5bd2e816 Reviewed-on: http://gerrit.openafs.org/2439 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b4411d37b43b0a934028af39fe8594bbd82e1733 Author: Russ Allbery Date: Thu Jul 15 16:29:27 2010 -0700 Flesh out the configuration documentation Remove obsolete configure options and document all remaining options other than some provided by Autoconf and some that are currently not very interesting. Document that, on modern Linux systems, configure can find the kernel build system and headers by itself and doesn't need the flag. Include some more information in README about changing the default installation paths, and mention that the da* versions of the file server and volserver also aren't stripped. Remove the generic GNU installation instructions, which aren't useful for OpenAFS. Change-Id: I56d0003ff0173749e9a5e04f1d0ed4d004787dfd Reviewed-on: http://gerrit.openafs.org/2438 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ce0ba0e33581cb5f89902d342f56ceef09f1b78a Author: Russ Allbery Date: Wed Jul 14 17:32:35 2010 -0700 Add new demand-attach binaries to .gitignore Change-Id: I822153d890e736c2422f6bc0c0b29bb7c4240f9b Reviewed-on: http://gerrit.openafs.org/2434 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 674ec768828994b90dc14bf8487e04de5bdf7295 Author: Russ Allbery Date: Wed Jul 14 17:30:11 2010 -0700 Fix .version generation for make libafs_tree The first argument to the git-version script should be the root directory of the tree, not the .version file in that directory. Change-Id: I145d360dc79132fc1474e94893c999b35774d874 Reviewed-on: http://gerrit.openafs.org/2433 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 01afbb03cc1b853d0909101e5145d0333669c344 Author: Russ Allbery Date: Wed Jul 14 17:29:34 2010 -0700 Move build support files into build-tools Now that we have a build-tools directory, move the various support files used by Autoconf and Automake into it as well to reduce clutter at the top level. Change-Id: Ieae317524d5354e3a6168507c569378f7913b05f Reviewed-on: http://gerrit.openafs.org/2432 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit aeba16157ef8127aa0f0866d699972ef7efe7a0c Author: Marc Dionne Date: Wed Jul 14 22:43:01 2010 -0400 afspag version of rx_knet.o in order to correctly generate KBUILD_MODNAME, each object file needs to be built only once. in this case it matters because the pr_debug macro, called as a result of including errqueue.h, needs it and things which depend on it, and when it's built into 2 .kos, the wrong thing happens. Change-Id: I85be7a3322fd179ef75fe14a90c9e7592e542ed1 Reviewed-on: http://gerrit.openafs.org/2435 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ed71f147c709c96c1edd77a06b019a40896967be Author: Russ Allbery Date: Wed Jul 14 12:46:04 2010 -0700 Debian: Install the demand-attach versions of the binaries This will need more comprehensive packaging work later, but in the meantime, install the binaries so that make dpkg will complete successfully. Change-Id: Ic82feb92c05a3638365593c4e321ef5e45916ee2 Reviewed-on: http://gerrit.openafs.org/2429 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 624e827f8fe31dfd22230a2689496328224d6bf1 Author: Russ Allbery Date: Wed Jul 14 12:33:40 2010 -0700 Use the full version number for Debian packages Debian packaging can deal with the full version number that we generate using git-version, so base the version we put into src/packaging/Debian/changelog on that version instead of the LINUX_PKGVER that we use for other packaging. Change-Id: Ibf50854748b2b588c2f971d6bdadd4f66f648c5b Reviewed-on: http://gerrit.openafs.org/2428 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 03080af8cee0e2d74c3dadf7a07e3b42f658e263 Author: Russ Allbery Date: Wed Jul 14 12:27:30 2010 -0700 make dpkg should only build binary packages The source package we would get by running dpkg-buildpackage in the source tree without further preparation is basically useless, since it's a native source package for a non-native package and will contain any random dirty cruft in the current source tree. Since the purpose of make dpkg is to provide quick Debian packages for testing purposes, only build the *.deb files and don't bother to build the source package. Change-Id: Ia2643c7e8936b15e3447df589ed0236438b8341e Reviewed-on: http://gerrit.openafs.org/2427 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4323e2ea3307baa6f4c21ae359713cabae0216b4 Author: Russ Allbery Date: Wed Jul 14 12:25:55 2010 -0700 Update Debian packaging to 1.5.75-2 Fixes the duplicate run of make install during the package build process and updates the changelog to the current Debian packages. Change-Id: I20fa4cc24e17c3944de2b08e265e277ff5d5564f Reviewed-on: http://gerrit.openafs.org/2426 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a658736af649bd52a7710cbb428a804588b2fda5 Author: Michael Meffie Date: Wed Jul 7 14:25:46 2010 -0400 man: document bos addhost -clone Add the missing -clone option to the bos addhost man page. Change-Id: I0ead9acfd25d573b907f2617845c25c8c11df53c Reviewed-on: http://gerrit.openafs.org/2349 Tested-by: Russ Allbery Reviewed-by: Russ Allbery commit a1351d48410383090befd63b34407caf55b8f654 Author: Russ Allbery Date: Wed Jul 14 10:02:08 2010 -0700 Fix ktime test on 64-bit systems 0xffffffff is a bad representation for -1 when the size of the data type may vary. Rather than forcing everything to 32 bits and losing later on platforms with 64-bit time_t, change the table to use time_t and try to add a cast that will do the right thing. Change-Id: Id532c9b7a1fc215dc9fd532592fecb2ea45597a0 Reviewed-on: http://gerrit.openafs.org/2420 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1d8bb99db9ae66554760a5927268631916be5adf Author: Andrew Deason Date: Thu Jul 8 15:59:58 2010 -0500 RX: ignore all local 127/8 IFF_LOOPBACK interfaces Currently RX lists all non-127.0.0.1 interfaces in the interface list, even those that are specified as IFF_LOOPBACK, to accomodate certain special cases where IFF_LOOPBACK interfaces should be advertised. However, this makes us advertise e.g. a 127.0.0.2 lo interface. So instead, skip all interfaces that are both in 127/8 and claim they are IFF_LOOPBACK, as this will skip a stray 127.0.0.2, but should not confuse the special cases. Change-Id: I60a4ed5330252078e2f58894195f9b68ec70dcfa Reviewed-on: http://gerrit.openafs.org/2376 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4b7d224d17e5d11b4ea50a8dece763aaedf21d17 Author: Andrew Deason Date: Thu Jul 8 10:56:28 2010 -0500 Treat all 127.0/16 addresses as loopback Many places treat loopback addresses specially; they are skipped over when traversing local interface lists, and they are sometimes replaced with the public IP of the local hostname when interpreting user arguments. However, we only treated 127.0.0.1 as 'loopback'. Many systems can have more than one loopback interface, such as having an interface with the address 127.0.0.2. So, to catch these, treat everything in 127.0/16 as a loopback address or otherwise 'invalid' address. We still do not treat the rest of 127/8 like this, to still allow some 127.* addresses to not be treated as loopback if someone really wants to. Change-Id: I64724cc1ee366e5ef80a8d6e3008e30a7077a4b2 Reviewed-on: http://gerrit.openafs.org/2367 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ca352e0f922e28f3d66a1d2e7d165e4dc846e5b8 Author: Russ Allbery Date: Wed Jul 14 09:28:47 2010 -0700 Rewrite FUSE macro to skip FUSE if not found unless --enabled If no configure flags are given, build the FUSE afsd iff FUSE is found. If --enable-fuse-client is explicitly given, always try to build the FUSE client and abort if FUSE libraries could not be found. Change-Id: Icc0d5bbb03239470ad856d87bca600304f030591 Reviewed-on: http://gerrit.openafs.org/2419 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 260ae1b845a82501f957f3fb40f63b0e0f6d5e93 Author: Marc Dionne Date: Wed Jul 14 09:52:03 2010 -0400 Linux: use an int pointer for the size argument to getsockopt getsockopt expects an int pointer as the size parameter, both in the kernel version and our replacement compat inline function, which causes warnings because we give it a size_t pointer. Use an int variable instead. Change-Id: Ide77ac01610c2f32f87d833c0d130c79007a1a33 Reviewed-on: http://gerrit.openafs.org/2417 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a8b64dba013d5aa899d5ce29370bf1a52fb3fca9 Author: Jeffrey Hutzelman Date: Wed Jul 14 01:20:22 2010 -0400 Don't overflow a buffer on the server's stack at startup The servers like to log the command line it was invoked with. It does this by concatenating its arguments, separated by spaces, into a 150-character buffer on the stack of main(). That's just wrong. Use a dynamically-allocated buffer instead. Change-Id: Ibe398e5f449eec176f11f301090a1b68ef13e94b Reviewed-on: http://gerrit.openafs.org/2275 Tested-by: Derrick Brashear Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear commit 8802b78040b37bad652b448dbc40af7745c16400 Author: Marc Dionne Date: Wed Jul 14 09:29:49 2010 -0400 rx_user.c: Remove unused variable There's an unused variable in the pmtu code in rx_user.c. Remove the "offender". Change-Id: I869b317d7e31b0f70b71f3e9ea2a0e0209709fcb Reviewed-on: http://gerrit.openafs.org/2415 Reviewed-by: Rod Widdowson Tested-by: Rod Widdowson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e503fc8b4ab1a37c447f78adcde92b6d84dd8658 Author: Derrick Brashear Date: Wed Jul 14 02:00:32 2010 -0400 linux rx pmtu fixes failed to get committed in earlier round of pmtu revamping. oops. Change-Id: Ie4b0e2e3c343b62abf9871fd41018d25b09d30d4 Reviewed-on: http://gerrit.openafs.org/2414 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 37994e573f14fb4cb1a1bbe74543fa297a4b2226 Author: Derrick Brashear Date: Wed Jul 14 00:44:11 2010 -0400 simple fuse enable change just turn on fuse by default. don't move anything Change-Id: I533aeda117159ed4bf37c550906b580125f7f729 Reviewed-on: http://gerrit.openafs.org/2413 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit eae0fe48b9eb32412d5b5872a9a57aa0205057fb Author: Andrew Deason Date: Fri Jun 25 17:02:54 2010 -0500 Add -unsafe-nosalvage fileserver option Provide a runtime flag to the DAFS fileserver to allow for fast-restart-like behavior for DAFS. Call the flag -unsafe-nosalvage, and document it, warning against its use. Change-Id: I342c58745b7e2e1d1a2066b4fb08941b02c660f9 Reviewed-on: http://gerrit.openafs.org/2277 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c3fc948e34ad6c44df88e77e5a00e7d3119f627e Author: Simon Wilkinson Date: Tue Jul 13 21:53:22 2010 +0100 Check for crypt in external library Check to see if we need to explicitly include a library in order to get the crypt() function Change-Id: I9bd1d70e420d4d1656bd86cd3215525102fa6259 Reviewed-on: http://gerrit.openafs.org/2404 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c6f7bb80ee01f477743a3496507e082fb5760884 Author: Russ Allbery Date: Tue Jul 13 15:39:29 2010 -0700 Update Debian packaging to 1.5.75-1 This update now builds shared library packages for the libafsauthent and libafsrpc shared libraries. It should also fix problems with make dpkg due to debian/changelog being deleted on make distclean. Change-Id: I14ce0633edc1f0cc9e081eb7383b2f1e7bfc729f Reviewed-on: http://gerrit.openafs.org/2405 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 95f51b8670b08526c6a3395ffc0ec169932f2cc7 Author: Derrick Brashear Date: Tue Jul 13 15:14:00 2010 -0400 enable pmtu in configure by default if we can get a socket error to let us get pmtu discovery info, use it. Change-Id: I7756c1a00e6cb018146a5b0545bed828446e5483 Reviewed-on: http://gerrit.openafs.org/2400 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3610ba191fd058b485db62ed5a3eb64f882a850f Author: Derrick Brashear Date: Tue Jul 13 16:47:39 2010 -0400 demand attach build always always build demand attach. includes doubtless-broken windows support. installs dafileserver, dasalvager, davolserver. salvageserver keeps its (unique) name. Change-Id: Ia272dd2b0f72789b9e0f2a7712f9c206bb922095 Reviewed-on: http://gerrit.openafs.org/2403 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit aa97bf5dd4c07be452e2473ffe0adbe680f73bd7 Author: Derrick Brashear Date: Tue Jul 13 23:51:52 2010 -0400 afs sunpro not always c99 old enough sunpro c won't be c99, and doesn't define a macro when it is c99. since there's no way to tell, be safe. Change-Id: Ib60ead7b702fe3ab203de83456d0f126afecc1ec Reviewed-on: http://gerrit.openafs.org/2411 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f5b6ce170757066ee5387d936efd51c11e18b2cf Author: Derrick Brashear Date: Tue Jul 13 23:36:30 2010 -0400 xdr sunpro not always c99 old enough sunpro c won't be c99, and doesn't define a macro when it is c99. since there's no way to tell, be safe. Change-Id: I1709827872b03c5365d9bb26b0ce9d86f038d882 Reviewed-on: http://gerrit.openafs.org/2410 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ad1b79547be5a2ae37619e8b583838e6744ff664 Author: Russ Allbery Date: Tue Jul 13 15:57:25 2010 -0700 make dpkg should not depend on dest It's pointless to have make dpkg build the tree before running the Debian build rules, since the Debian build rules are just going to build the tree again. Change-Id: I2481b20a5ca23f8cb067ba609d4d3acd58738cc4 Reviewed-on: http://gerrit.openafs.org/2406 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b666166b6d81b5a8079030e66d527bd708afeede Author: Derrick Brashear Date: Tue Jul 13 14:31:41 2010 -0400 simple is-lex-flex autoconf test if we're flex, we may need to be lex-compatible. engage it if we're flex Change-Id: If9a39ca0bce3f4a68b742d1e8f0c679d3f79896e Change-Id: I7f245d579bcc46fdd0aa7202bbd45f3f9f647ebc Reviewed-on: http://gerrit.openafs.org/2399 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a0113e0f1272b8f2c57fa339dcaef0bd4770143f Author: Russ Allbery Date: Tue Jul 13 13:42:01 2010 -0700 Link libafsauthent with -lresolv if required libafsauthent includes auth/cellconfig.c, which uses res_search, so it requires -lresolv even if it isn't needed for gethostbyname. Add LIB_AFSDB to the link line for libafsauthent. Change-Id: Id83ceb8b261b8c7fb176e24cc138276282608513 Reviewed-on: http://gerrit.openafs.org/2408 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 57d727da233252477c16a34cf628f6764534b8bc Author: Russ Allbery Date: Tue Jul 13 13:42:01 2010 -0700 Link libafsauthent with -lresolv if required libafsauthent includes auth/cellconfig.c, which uses res_search, so it requires -lresolv even if it isn't needed for gethostbyname. Add LIB_AFSDB to the link line for libafsauthent. Change-Id: I4dafdf83db9a00e4e30bff7c59357c13bf7af961 Reviewed-on: http://gerrit.openafs.org/2402 Tested-by: Derrick Brashear Tested-by: Jason Edgecombe Reviewed-by: Derrick Brashear commit d815833f9db0f91511390251932cfe0a83189a23 Author: Derrick Brashear Date: Tue Jul 13 15:47:41 2010 -0400 disconnected fix prototype warning supporting disconnected in ukernel uncovered this warning from lack of a prototype Change-Id: I81d287a8e4466270906fe67f8a1f2f6406fec430 Reviewed-on: http://gerrit.openafs.org/2401 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 52fe3b27489f113c0f7488c5b78fd95a18d44831 Author: Derrick Brashear Date: Tue Jul 13 14:29:38 2010 -0400 64bit macos new config.guess support new config.sub/config.guess call 64 bit macos something new. update our handling so we deal. Change-Id: Ieadd71b66e879ff58bf2c7f77173284c570e4252 Reviewed-on: http://gerrit.openafs.org/2398 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d29643b0553011cbe60dd127fd31c1847fe02ddb Author: Derrick Brashear Date: Tue Jul 13 13:06:02 2010 -0400 unix disconnected mode always per 1.6 release plan, enable disconnected always. eject ifdefs (and a stray printf that was hidden in one) Change-Id: I6a68cb8506878c28502e1742a48858f2e84958f5 Reviewed-on: http://gerrit.openafs.org/2397 Tested-by: Jason Edgecombe Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 27d415d2b82c7ddceb3f9ec779a65b4e2c5a8141 Author: Derrick Brashear Date: Tue Jul 13 12:41:15 2010 -0400 linux cache bypass by default can't eject the ifdef yet as this is not fully portable now. however, just enable it always. Change-Id: Ia7a49a10377f308740ebd42027ac9748b073016e Reviewed-on: http://gerrit.openafs.org/2396 Tested-by: Jason Edgecombe Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 191dbb439d4b54d485a50c2670daaaacab5b2369 Author: Jeffrey Altman Date: Mon Jul 12 14:42:12 2010 -0400 DAFS: variable declarations in C must be a top of block Two instances of variable declarations not being present at the top of a code block in src/vol/volume.c when building with AFS_DEMAND_ATTACH_FS. Fix them. Change-Id: Ic6b9c5a6bbbd8355a144fea38a6ca1dd2a2c747d Reviewed-on: http://gerrit.openafs.org/2388 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 2cab6a75207d67e2fbbbf4418f46bf46277e3825 Author: Jeffrey Altman Date: Mon Jul 12 23:35:05 2010 -0400 Windows: Generate a valid block using mkvers.c The tag requires not only a but a . Change-Id: I3c5b7691d18381b1bf71bbd3d726bd284bf90919 Reviewed-on: http://gerrit.openafs.org/2390 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 2b85b8c31d96b0ac558acb1bf95fb7b21c66cb3c Author: Jeffrey Altman Date: Mon Jul 12 23:36:56 2010 -0400 Windows: Permit docbook validation using xmllint Add a "check" rule to each of the docbook directories that uses xmllint.exe (from Cygwin) to validate the docbook source against the DTD. Validation failures will halt the build. Change-Id: Ifcfcab11d5077381bfe7fa5e3767070a8d55cb21 Reviewed-on: http://gerrit.openafs.org/2391 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit d4440319c3f954432056044fb55b2630594a46b7 Author: Jeffrey Altman Date: Mon Jul 12 23:40:01 2010 -0400 Commit DTD validation errors in the Windows Release Notes Correct errors detected using xmllint Change-Id: I75c936084f116addbb7918856fe958b596e91b03 Reviewed-on: http://gerrit.openafs.org/2393 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 6c78ce796262d62ad1641f5b28ea1bdbe78222cf Author: Jeffrey Altman Date: Mon Jul 12 23:40:52 2010 -0400 Correct DTD validation errors in the UserGuide Correct errors detected using xmllint Change-Id: Idd9e91ef463679cb58bdb622fd600e4020224e81 Reviewed-on: http://gerrit.openafs.org/2394 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Jason Edgecombe Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit fb285880dad219a9992bd9bc29fd5bbb0ee34c8c Author: Jeffrey Altman Date: Mon Jul 12 23:38:56 2010 -0400 Correct DTD validation errors in the AdminGuide Correct DTD validation errors detected using xmllint. Change-Id: Ia255ac319a81966e63b702dd2b672ff3d6d8958a Reviewed-on: http://gerrit.openafs.org/2392 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 73716de680b336df1ca51fe60ce9526d9f43f2e7 Author: Simon Wilkinson Date: Mon Jul 12 12:04:20 2010 +0100 Linux: Use inode lock compat function We've now got a compatibilty function for locking and unlocking an inode. Use that in osi_file, rather than a local set of #ifdefs Change-Id: Ie64f0b758df0b90d0df2033d57729c8b09652c39 Reviewed-on: http://gerrit.openafs.org/2389 Tested-by: Jason Edgecombe Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cdef1c67aeaedffadf41069f46e0144f5f1b3a29 Author: Ken Hornstein Date: Tue May 4 14:04:59 2010 -0400 fix dumptool on macos make dumptool in test suite compile on macos again Change-Id: Id60f625ce53bc9695673b68c733fa653521a8122 Reviewed-on: http://gerrit.openafs.org/2387 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 78e4c7561b8092103da8c991b7d1c996b7eee194 Author: Derrick Brashear Date: Mon Jul 12 15:04:44 2010 -0400 rx getaddr loopback change fallout failed to git add, and so failed to push this back. Change-Id: Ic538ac13f3099cfb3b8a5561e332750421ddd093 Reviewed-on: http://gerrit.openafs.org/2386 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c44f640df369c74aac3a26b7001c257f4ad4e536 Author: Michael Meffie Date: Tue May 11 17:26:36 2010 -0400 xstat: fix large integer output Do not print large positive integers as negative. Change-Id: Ia7f96e64ee6ad0c58de0d03779b230623d60b114 Reviewed-on: http://gerrit.openafs.org/1949 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5cc6293c2cfc7b0a8746942fd048127bb7cbf10f Author: Andrew Deason Date: Wed Jun 23 16:08:13 2010 -0500 Provide man pages for more fssync-debug commands Provide man pages for the fssync-debug commands vgcadd, vgcdel, vgcquery, vgcscan, vgcscanall, vnode, and volop. Change-Id: If456a4cdfedbf5f2776c276bc20178319638c26a Reviewed-on: http://gerrit.openafs.org/2239 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6f75caf8e58521dc15ca793ec4767e5529516b43 Author: Michael Meffie Date: Mon Apr 19 10:00:52 2010 -0400 viced: host hash address collisions Attempt to resolve collisions when adding a host to the address hash table and another host with the same address:port is already present in the hash table. Retrieve the uuid for the host at that address and if the uuid matches the new host and not the old, remove the address from the old host and install the new host into the address hash. Change-Id: Id182f907f63be556c61ffb91777edd35f0aa950d Reviewed-on: http://gerrit.openafs.org/1786 Reviewed-by: Andrew Deason Tested-by: Michael Meffie Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 421cdc04de9716f994f3bdba17ad4d69494868a5 Author: Andrew Deason Date: Thu Jul 8 15:37:48 2010 -0500 Consolidate loopback address tests Many different places were testing if an address is a loopback address. Consolidate these into one function to make it easier to alter. Change-Id: I9c4465f3bdc4e840c83d69456504caaac1c544e7 Reviewed-on: http://gerrit.openafs.org/2375 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2e66c828b1224fb651ba66e7d7ec59da469f7993 Author: Andrew Deason Date: Thu Jul 8 16:40:07 2010 -0500 GetInodeSummary: free inode info In the salvager, GetInodeSummary stores some information about the relevant inodes into a file. Free the memory for that information after it's been written out, since we don't reference that memory again. Change-Id: I9578f941d2ea13240dd22d9b6e7a1f32217263c9 Reviewed-on: http://gerrit.openafs.org/2370 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 262a678d9b7b79f5261af2a8b36588f684e547ef Author: Matt Benjamin Date: Thu Jun 24 09:07:36 2010 -0400 An RPC test dispatch library for vice A library framework for remote testing against file servers, with the ability to establish multiple call/callback channel pairs within a single test process and dispatch requests arbitrarily on each. Thanks to Derrick for design and debugging help. Additional callback processing intelligence will follow in a future changeset. This version builds on Windows NT (but might need further adjustment). Change-Id: Ibea39e912b2a23ebf58e9e0931114572eccf6e78 Reviewed-on: http://gerrit.openafs.org/2229 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1701535fae6a78b72a2b637365a0bf2d77803b5b Author: Simon Wilkinson Date: Sat Jul 10 20:30:31 2010 +0100 Linux: Actually use freezer compatibility func We were calling try_to_sleep, rather than afs_try_to_sleep. Whilst try_to_sleep is present in all modern Linux kernels, on some older systems we need to fall back to our own implementation, which is what the afs_try_to_sleep function should do, but it can only do so if we call it. Change-Id: I900e50cf2754535e676d582bd3da82f1833bde52 Reviewed-on: http://gerrit.openafs.org/2384 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2aa16fba58c6d14c1bb3dd5dc2187338d89a2149 Author: Simon Wilkinson Date: Sat Jul 10 20:17:56 2010 +0100 Linux: Use freezer compatibility macros in RX Commit eef18466d920985c37ed8d22a6557b609c6225a6 introduced some compatibility macros for the refridgerator functionality. Use these in the Linux kernel RX code, rather than rolling our own. Change-Id: I4279e0b3ee92337cb992ff46895712630f681b7b Reviewed-on: http://gerrit.openafs.org/2383 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit af3292a06dbe2b4ecafb2cac5e76f23da697d93c Author: Russ Allbery Date: Fri Jul 9 16:46:21 2010 -0700 Update config.guess and config.sub to 2009-12-30 and 2010-01-22 Update to the latest versions provided by the Debian autotools-dev package. Change-Id: I503ed6bd4316af40f9d36be6010708cb4fef42e1 Reviewed-on: http://gerrit.openafs.org/2378 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4e02b143d2e632c8b515d83cc853d43e22a12617 Author: Russ Allbery Date: Fri Jul 9 16:42:26 2010 -0700 Make config.sub executable Autoconf apparently doesn't care because it runs it explicitly under a shell, but it's sometimes useful to run it manually to check something. Plus, executable shell scripts should be executable on general principles. Change-Id: I0663d91da643f7c0a77fe758ca63f1cc14e81180 Reviewed-on: http://gerrit.openafs.org/2377 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 839ea46465d9bf63fb69b561b1ffff940fd1044f Author: Russ Allbery Date: Fri Jul 9 18:09:32 2010 -0700 Terminate the DARWIN80 #if in afs_osidnlc.c The #if defined(AFS_DARWIN80_ENV) in src/afs/afs_osidnlc.c was never terminated, leading to build failures. Add an #endif. Change-Id: Ie2f324668becef8294b86cadec5cf5547731d2ad Reviewed-on: http://gerrit.openafs.org/2381 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 9e2aba99124f777a209d30ea57cbe92e19130b1f Author: Russ Allbery Date: Fri Jul 9 18:06:47 2010 -0700 Fix ktime test for errors The variable passed into ktime_DateToLong must be initialized to 0 or, on error, we get the previous value and the tests fail. Change-Id: I5528a830981a85fb6737bb8cb5931ab95faffb13 Reviewed-on: http://gerrit.openafs.org/2379 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ad470b2ed25cdf99f0388947913e392c2d8b67a9 Author: Russ Allbery Date: Fri Jul 9 18:08:12 2010 -0700 Include linux/freezer.h in rx_kmutex.c rx_kmutex.c calls refrigerator(), which is prototyped in linux/freezer.h, but was not including it, causing build failures on Linux 2.6.32-5 (Debian). Change-Id: I3867be6e7b8478d6fab8b97a4c923f979029517e Reviewed-on: http://gerrit.openafs.org/2380 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c62466ecabffbb8a8af7e18d1a0e8152685f859b Author: Andrew Deason Date: Wed Jul 7 15:43:26 2010 -0500 Use afs_sfsize_t for *_SIZE results Callers of FDH_SIZE and OS_SIZE should be storing the results in an afs_sfsize_t. Some were using regular 'int's and other things, which can screw up if the file is sufficiently large. Change-Id: Ibbc2067ed3b90edcbdd46cfa43da559fd6419f0b Reviewed-on: http://gerrit.openafs.org/2357 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c658bfaf884973aa47c8ce3072b96e6b7d8439c6 Author: Ben Kaduk Date: Fri Jul 9 00:38:16 2010 -0400 Remove incorrect critical section use in dnlc_lookup Critical sections may not be used with (non-spin) locks. As such, this code was wrong, and led to a panic. We don't see why there what synchronization they may have been providing, so just remove them and do not replace them. Change-Id: I5d81595a7059a91b9aad46ab0a634fa684f67325 Reviewed-on: http://gerrit.openafs.org/2373 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3ad8760f243998a78770e88f5c738c08df535201 Author: Michael Meffie Date: Sat Jul 3 18:54:15 2010 -0400 wiki url changed Update the various places we reference the project wiki. Change-Id: I56bcf038553eec02695667d737e0cd51e653b881 Reviewed-on: http://gerrit.openafs.org/2374 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dbcd822a484a0193539be2a96e4db39a003cc9e6 Author: Michael Meffie Date: Thu Jul 8 14:45:22 2010 -0400 build fix on older linux The commit d0abe56aa47d4561ba57527d53a2b0db2ea613c2 added a duplicate inclusion of freezer.h. Older versions of linux (circa 2.6.20) are missing include guards on freezer.h. Change-Id: I12c47cded7d06a3514a520b554bbcbd3328f0d2b Reviewed-on: http://gerrit.openafs.org/2369 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d0a9585f9305ae0ebdf958a30e4581e3c24e0de1 Author: Alexander Redinger Date: Fri Jul 2 15:43:42 2010 -0400 SOURCE-MAP updates SOURCE-MAP now reflects state of current code tree, reformatted for readability and easier updating. Change-Id: I858156692c1e4c60ba4d5a75b684db2a079e2dba Reviewed-on: http://gerrit.openafs.org/2348 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5852a3f06a759cbb9e9d2a455c277ec2a44ba498 Author: sanket Date: Thu Jul 1 23:05:24 2010 +0100 vos: Don't call SubEnumerate twice Set a flag to say when we've called SubEnumerate, so that we don't end up calling it twice when in -format mode (Simon Wilkinson extracted this from a larger patch by sanket) FIXES 41031 Change-Id: I2cadd536cb6c9f389330d64ffbf35a16d673d2de Reviewed-on: http://gerrit.openafs.org/2320 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 887de6605150ccd0f0cd56b80d826b04dc7d1339 Author: Jonathan Billings Date: Thu Jul 8 09:23:28 2010 -0400 Update the Red Hat spec file to include fssync-debug man pages Include the new man pages in the base 'openafs' package. The package build process fails with unpackaged files without this update. Change-Id: Ie7a80a283bb95b492b56be0133c1bd811953c57e Reviewed-on: http://gerrit.openafs.org/2364 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c72cd42364206f4fe237d26e582cef86351f75a8 Author: Andrew Deason Date: Fri Jul 2 14:28:29 2010 -0500 Fix VPrintDiskStats_r logging VPrintDiskStats_r tried to log some information using separate Log() statements on the same line. This looks very odd when logged, since we add a timestamp to every Log() call these days. Fix it to print the line as one call to Log(). Change-Id: I19a5365c24208229201ba54ff04e793b5e50eee5 Reviewed-on: http://gerrit.openafs.org/2359 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9408bcaa62ae77b2f5a20b962fec2dbec460c1fe Author: Andrew Deason Date: Mon Jun 28 14:55:18 2010 -0500 viced: Remove stray \r The "File Server has started at" log message contains a trailing '\r' for some reason. Remove it (ctime will give us a trailing '\n'). Change-Id: I8f280abff9a7548f376f007021d74d3a21ac45cf Reviewed-on: http://gerrit.openafs.org/2358 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c790e7d0ca9f76749f761792234da91078eb573d Author: Russ Allbery Date: Wed Jul 7 14:04:37 2010 -0700 Remove a few erroneous NEWS entries for 1.5.75 FUSE was already in 1.5.74, and DAFS fast-restart was not in 1.5.75. Change-Id: I2e1b765c61ce4670800787dbcfd13c2c2af63f79 Reviewed-on: http://gerrit.openafs.org/2356 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4e87cb5c9260c7ddfa2ab22d9596c814817fc69c Author: Ben Kaduk Date: Wed Jul 7 22:10:44 2010 -0400 Fix build Previous commit to this file was not as tested as we thought. This one actually builds (well, except for the part where flex doesn't like et_lex.lex.l at the moment). Change-Id: I11d918adc50bb387c022d90cb0877a6a667e8252 Reviewed-on: http://gerrit.openafs.org/2362 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2c7a19b092c8b71fa142a6612a9a7a530c7c3d37 Author: Ben Kaduk Date: Wed Jul 7 20:47:55 2010 -0400 FBSD: sync with NFS for *pages vnops We've had per-cpu counter variables for a while, use the proper macros to adjust them. FBSD90 has had the page queue locks pushed down a level, so we don't need to lock them and should lock individual pages instead. This fixes mmap() on FreeBSD HEAD. Change-Id: I95d16097aaa65c1c99b4a686c05ac84fe9c11584 Reviewed-on: http://gerrit.openafs.org/2360 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bbce05150cae04b7cb2ab943308cdbf0d8dfdffa Author: Russ Allbery Date: Wed Jul 7 12:50:37 2010 -0700 Add NEWS entries for 1.5.75 Change-Id: I3510b03b6821ce266ebcf217b4bf7d6065a8aaa5 Reviewed-on: http://gerrit.openafs.org/2355 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a064446cf6987744ef614cbf37f43231bc207c7e Author: Andrew Deason Date: Wed Jul 7 12:52:10 2010 -0500 klog: refactor klog_prompter The ifdefs in klog_prompter were getting a bit confusing. Split out some logic into a separate "is this prompt a password prompt" function. As a result, we can build without KRB5_PROMPT_TYPE_PASSWORD defined, which happens to be the case on hp_ux11i. Change-Id: I1d5f794bfc33017f699478e367cde91a3e77d33c Reviewed-on: http://gerrit.openafs.org/2353 Tested-by: Andrew Deason Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ad2bc4a35d003a0a9fd0d116199f9ad5998ad112 Author: Andrew Deason Date: Wed Jul 7 11:40:20 2010 -0500 Fix shlibafsrpc des.c hp-ux special case '$$@ -I../des', not '-I../des $$@'. Change-Id: I322963b8f6ab31cfa76a91095be665ca59a3c9c3 Reviewed-on: http://gerrit.openafs.org/2352 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8492619f23024eeb1ad42294f055218ddc57aa0d Author: Andrew Deason Date: Wed Jul 7 10:23:27 2010 -0500 HPUX: correct PostPopulateVCache vfsp set Setting AFSTOV(avc)->v_mount is the linux/BSD way. avc->v.v_vfsp is the HP-UX (et al) way. Change-Id: If2cd1c1e74fcd0ca5ad981497abe7968d97cf0ed Reviewed-on: http://gerrit.openafs.org/2351 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0a8b1864d604353a980d1370d97546e12973b462 Author: Andrew Deason Date: Wed Jul 7 09:51:45 2010 -0500 HPUX: include proc_iface.h for proc_t We use proc_t in a typedef, and we need proc_iface to get proc_t. So, include it. Change-Id: I515abe43ae1d3b4a2c54ebe1b7192a91ed441117 Reviewed-on: http://gerrit.openafs.org/2350 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d154ea157b9c32b5cb421f12796ede733e091f4d Author: Andrew Deason Date: Tue Jul 6 14:02:56 2010 -0500 UINT_MAX requires limits.h We need to include limits.h to use UINT_MAX on some platforms, so include it in src/rxkad/v5der.c. Change-Id: I79343011e72080e58f07d53195488808d9e29121 Reviewed-on: http://gerrit.openafs.org/2339 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 16efa8e8c368df67efd91314fc81e38682d367eb Author: Derrick Brashear Date: Wed Jul 7 10:43:48 2010 -0400 kernel InitPeerParams has bogus branching and dup code several of the mtu configuration cases for the kernel version of InitPeerParams were bogus. clean up the function. (a forthcoming change reworks this anyway, but..) Change-Id: Ia4449d5cecc80cddae7d0f611186f48614b908ee Reviewed-on: http://gerrit.openafs.org/2343 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 84c52e1db63999988d8405d223cb28f2063004c3 Author: Andrew Deason Date: Tue Jul 6 14:41:13 2010 -0500 HPUX: make osi_procname a stub It is not immediately clear how to obtain the current process name on HPUX, and the current osi_procname definition breaks the build, so just make osi_procname a stub for HPUX. Change-Id: I8c825d53d7f25b1500b41629ba73f2fe1f48f00a Reviewed-on: http://gerrit.openafs.org/2341 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4a022e9e5954f76900f1ca0fdb92c2f12b0036fb Author: Andrew Deason Date: Tue Jul 6 14:10:35 2010 -0500 Fix stray static inline 'static inline' should be 'static_inline'; keep the hp-ux compiler happy. Change-Id: Ibfb819571c608b9ca7c1437fde6898b405bccc4c Reviewed-on: http://gerrit.openafs.org/2340 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 262715d1d3fb672914fbe011663504a69fcf6046 Author: Derrick Brashear Date: Tue Jul 6 11:11:25 2010 -0400 fix newline conventions we had some CRLF files hanging out. fix them. Change-Id: Ie2aa707813967192f202aabc3b28808ae8f80da6 Reviewed-on: http://gerrit.openafs.org/2335 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit af5c302f0da739a70777980fd4ab7f9490ae51c3 Author: Derrick Brashear Date: Tue Jul 6 09:36:27 2010 -0400 rxkad heimdal cleanup don't assume every system have uint16_t and uint32_t; instead massage for use of native afs types. Change-Id: I8943f37ecf6dd5d1565ed295b6e6a2ca9eea5b6d Reviewed-on: http://gerrit.openafs.org/2334 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4ca1b0102542aec73ed5d06583f302eead94ba22 Author: Jeffrey Altman Date: Tue Jul 6 00:30:06 2010 -0400 Windows: update release notes for 1.5.75 Add: * better description of Win7 netbios name lookup bug * "fs newcell" changes * IdleDeadTimeout registry value * NatPingInterval registry value * ReadOnlyVolumeVersioning registry value Change-Id: Ibf5ff8145be94ab8a7a48a1a9bd87c7d60e8549b Reviewed-on: http://gerrit.openafs.org/2333 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit e6a8d4ab2c8bc37c958a12f74d8b2c6074aff025 Author: Jeffrey Altman Date: Fri Jul 2 13:55:05 2010 -0400 Windows: ChangeLog for 1.5.75 Change-Id: Iff322bf65d9d8b5af58d6f4b53630256504999cb Reviewed-on: http://gerrit.openafs.org/2332 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit b2a404ffd94de936a073dc5836230bffc52b0729 Author: Derrick Brashear Date: Fri Jul 2 17:53:50 2010 -0400 make openafs 1.5.75 version number updates for 1.5.75 Change-Id: I05cf66281e497c3eff473a350abe480e6fcfd928 Reviewed-on: http://gerrit.openafs.org/2328 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4c0d47de22e1cb0258151e266f15d4a5bf239f33 Author: Ben Kaduk Date: Sun Jul 4 02:28:02 2010 -0400 FBSD: always close the rx socket when shutting down The soclose(rx_socket) call is needed in order to restart AFS. (Otherwise sobind() fails with EADDRINUSE.) While here, use the defined constant SHUT_RDWR instead of hardcoding '2' for soshutdown's second argument. Change-Id: Iba7cac3aec79764783628da28b12253d496a7680 Reviewed-on: http://gerrit.openafs.org/2331 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bf8746dc43567a0a8f1d4075402eb9d2f741ec04 Author: Ben Kaduk Date: Sat Jul 3 22:58:39 2010 -0400 Do not recurse on the glock in rxk_NewSocketHost If sobind() failed, we would lock the glock before going to bad, which proceeded to lock the glock, panic()ing on the recursion attempt. Remove the unneeded first call. Change-Id: Ifa793735ebe64bde98156caa610c06612bdb92bd Reviewed-on: http://gerrit.openafs.org/2330 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit b54c7ceefe884b57db76c929940afdfee86472e8 Author: Jonathan Billings Date: Wed Jun 30 15:09:39 2010 -0400 Removed kpasswd from openafs-file-list The executable %{_bindir}/kpasswd was included in the the 'openafs' base package. This change removes the kpasswd executable from the base package. It is still built and is installed in the 'openafs-kpasswd' package. I believe this was the original intent of the 'openafs-kpasswd' package. Change-Id: Idf49747d8a703bb959cdf758d489d640045f285f Reviewed-on: http://gerrit.openafs.org/2305 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d8cde43ed0fcdb1168deae2179e638667bab37ad Author: Derrick Brashear Date: Fri Jul 2 17:42:13 2010 -0400 update VAllocVnode logging move the log message i added to the correct place and put one where it came from. oops Change-Id: Ieb78d8cc076dbc2279922b0909546878b9ee005e Reviewed-on: http://gerrit.openafs.org/2327 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c8ce42242873e3b21443ad7a5d1e1bb5e7b28e60 Author: Andrew Deason Date: Tue Jun 29 13:19:11 2010 -0500 DAFS: Salvage VG on volume creation error When trying to create a volume (either an entirely new volume or a clone), request a demand-salvage on that volume group if we hit an unexpected error. This can allow some situations to automatically rectify themselves if, for example, a volume is missing its .vol header, but still otherwise exists and causes an error during a clone. Change-Id: I22b3e9028685395a8e621962138dee9f5f2ec822 Reviewed-on: http://gerrit.openafs.org/2286 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6b041b7cb0d29815495b2559f24f4ff4979eb129 Author: Andrew Deason Date: Tue Jun 29 14:44:31 2010 -0500 DAFS: Allow FSSYNC salvages on unknown volumes Allow salvage requests over FSSYNC (FORCE_ERROR with the FSYNC_SALVAGE reason code) that are requested on volumes that we do not know to exist. This can be helpful if a salvage is requested on a volume that someone attempted to create but failed, indicating that a partially-created volume may be in the way. Log an additional message when we do this, as it should not be a normal occurrence. Change-Id: I6e1bbe35111a41c489fe85cad36e6a8a6f323a5a Reviewed-on: http://gerrit.openafs.org/2285 Reviewed-by: Tom Keiser Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ff072a08b5c5204a27d3807ad592db84e87c697d Author: Marc Dionne Date: Fri Jul 2 09:13:50 2010 -0400 Linux: cache bypass: fix FCSBypass tests Add some parentheses around the tests for FCSBypass. Without them, the test will not always give the intended result. Change-Id: I94cb2b2c95c702981fce9cff066b620bce652ee1 Reviewed-on: http://gerrit.openafs.org/2324 Reviewed-by: Matt Benjamin Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b23d86e430d9a077d94c6bc768216eb75bfb1faf Author: Marc Dionne Date: Fri Jul 2 09:10:06 2010 -0400 Linux: cache bypass: warning fix in afs_bypasscache.c Cast the printf argument to int to match the format specifier. Change-Id: I4300c8a407c99c40e116a6e166a76112fb92d254 Reviewed-on: http://gerrit.openafs.org/2323 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c66ba55bd882de677e425a9b9f7f29215a05b647 Author: matt@linuxbox.com Date: Fri Jun 18 14:27:07 2010 -0400 cache-bypass explicitly reference pages involved in background i/o Formerly, we assumed that any page eligible for background i/o could be effectively pinned by lock_page. Persuant to concern expressed by Simon that such pages might be eligible to be released by the kernel after readpages returns, call get_page to increment the refcount on each page before dispatching a background read (and matching put_page when the i/o is completed). Change-Id: Ib3a63e56e6b902b4eb5deb769847e7f17ce2c9ff Reviewed-on: http://gerrit.openafs.org/2215 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 63304d6b2b895404e3a1a194232f3a48e448e75d Author: Andrew Deason Date: Tue Jun 29 12:30:10 2010 -0500 DAFS: Log attempted salvage requests Log in FileLog (or VolserLog, or the log of any program that requests salvages) when we request a demand-salvage to occur. Change-Id: I2444480287a1647c2d3e25039467167e28e17f38 Reviewed-on: http://gerrit.openafs.org/2284 Reviewed-by: Derrick Brashear Reviewed-by: Tom Keiser Tested-by: Derrick Brashear commit febd69f74b96638a696292624f797a0ef46622da Author: Simon Wilkinson Date: Thu Jul 1 20:18:33 2010 +0100 Build: Let configure pick our lex and yacc Let the autoconf magic pick our lex and yacc implementations, rather than hardcoding possibly wrong values in osconf.m4 FIXES 1394 Change-Id: I692eb8568780c78cfe6ba2e5b0fddca6fe6c142c Reviewed-on: http://gerrit.openafs.org/2316 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 417d2c8f9585c5e3ce17512a1ae8ca596a676c03 Author: Simon Wilkinson Date: Tue Jun 29 21:45:36 2010 +0100 Build: Rework git version detection Rework the git version detection script to handle some issues that have been pointed out. 1/ Make it work properly with objdir builds 2/ Don't try to work out if the tree is dirty if git describe failed 3/ Use the configured VERSION as a fallback if we can't obtain proper version information during a make Change-Id: I39494e1c18cf4eacbb55386334da7128fbe96310 Reviewed-on: http://gerrit.openafs.org/2283 Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a155d71914791702762d8abd947cf609e1b4bea0 Author: Andrew Deason Date: Fri Jun 25 16:22:28 2010 -0500 vol: Move destroyMe check outside of inUse check The destroyMe conditional does not depend on the result of VShouldCheckInUse(), so move it outside of that block. Change-Id: Ieb4c97ae9f76b4369680629f18eecd1dfc06682f Reviewed-on: http://gerrit.openafs.org/2276 Reviewed-by: Derrick Brashear Reviewed-by: Tom Keiser Tested-by: Derrick Brashear commit d730f7ceb586ac12d5f04dc5ab294f5d4f449334 Author: Derrick Brashear Date: Tue Jun 29 20:49:41 2010 -0400 VAllocVnode error handling avoid growing a volume index too large. handle errors other than just by dropping a core Change-Id: Id1bf7a1a40672b6b960cc0d7a1cd54f48ab0b50a Reviewed-on: http://gerrit.openafs.org/2291 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a309e274632993c5aeec04c6e090f5ac95837a40 Author: Rainer Toebbicke Date: Wed Jun 23 13:08:47 2010 +0200 Do not call afs_FlushVCBs with afs_xvcache held In afs_AllocCBR, use dynamically created afs_cbr structures when running out of preformatted ones, rather than calling afs_FlushVCBs under, potentially, the afs_xvcache lock (which would be held across the RPC, difficult to drop and re-acquire under the current hierarchy). Modest modernization of the number preformatted afs_cbr structures, rule-of-thumb, not pretending any research. Change-Id: I9427427d5dab7d4639822c370bdded0418f67d9e Reviewed-on: http://gerrit.openafs.org/2243 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bdf6192509ca79baacda8ddf79112647bd3c0791 Author: Derrick Brashear Date: Fri May 14 16:03:32 2010 -0400 bosserver force corefiles override system resource limits so we get corefiles Change-Id: I50f228d709090c8275bed2fc2958653c43a0a026 Change-Id: I5b5e8c6a5e02ed0b28610949eb81f6345357969e Reviewed-on: http://gerrit.openafs.org/1959 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 4516e3777413f795ab09440bf300681750ed92fa Author: Marc Dionne Date: Fri Jul 2 09:28:05 2010 -0400 Linux: cache bypass: remove warning print before panic This warning printf has some issues - it prints out pointers as ints with %d (which causes warnings), and if the intention was to print the referenced values, they wouldn't be set yet at that point in the function. Since the purpose is not clear and it has issues, just remove it. Change-Id: Ied69c390818f9dff235bdaa31af42996aaa39af3 Reviewed-on: http://gerrit.openafs.org/2325 Reviewed-by: Matt Benjamin Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 95a814a26fae63e75fac99e2c8d586bd4725f204 Author: Marc Dionne Date: Fri Jul 2 08:55:44 2010 -0400 Linux: cache bypass: warning fixes in afs_pioctl.c Fix two minor warnings in afs_pioctl.c: - gcc complains that threshold may get used uninitialized. the warning looks bogus, but initialize it to keep gcc happy. - PSetCachingBlkSize is declared but never defined. Change-Id: I3ac84d665f60ba51fef2d52f2bd8d90e0a7bc3b3 Reviewed-on: http://gerrit.openafs.org/2322 Reviewed-by: Matt Benjamin Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bd6b25049331c07ccdeb806d82f73d71221b78f1 Author: Marc Dionne Date: Thu Jul 1 16:07:40 2010 -0400 Linux: cache bypass: deal with the afs_serverHasNo64Bit case Deal correctly with the case of a server with no 64-bit fetch support. In that case, the code needs to fallback to the standard FetchData call, similar to what happens in afs_fetchstore.c. Move existing check out of 64-bit-only branch so servers already known to be non-64-bit and not merely those newly discovered so execute the non-64-bit FetchData. Change-Id: I505ce6d88072bc3ee5208863717395a78f8562fa Reviewed-on: http://gerrit.openafs.org/2319 Reviewed-by: Matt Benjamin Tested-by: Marc Dionne Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear commit b0ed5a7facb1951f2f4ef8ed3da29a6a80cb7d49 Author: Rainer Toebbicke Date: Wed Jun 23 15:10:46 2010 +0200 Protect truncate_inode_pages when called from osi_VM_FlushPages truncate_inode_pages requires the mapping to be protected using i_mutex / i_sem, which is not held whereever osi_FlushPages is called. Change-Id: I2ca59cf75633368efb7f6a17fd01c7c517a8f609 Reviewed-on: http://gerrit.openafs.org/2244 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 202ca802c30bfa6779fae0bd686da0ca96fc224d Author: Marc Dionne Date: Thu Jul 1 15:22:47 2010 -0400 Linux: cache bypass: avoid unused variable warnings Some variables are only used for AFS_64BIT_CLIENT code, so make their declaration conditional as well. Also, initialize 'code' while we're at it. The compiler has a legitimate complaint that it could be used before it's set, for instance if we have AFS_64BIT_CLIENT but afs_serverHasNo64Bit is true. Change-Id: Ic04b07fffa9668123a9029bb42415a7c701c2339 Reviewed-on: http://gerrit.openafs.org/2317 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f004a5c7ecd35e5b26cafd62c322e3184e811e64 Author: Marc Dionne Date: Thu Jul 1 15:38:32 2010 -0400 Linux: cache bypass: warning cleanup in afs_daemons.c Remove unnecessary warning for the UKERNEL case. This file will always get compiled with UKERNEL. Remove an "if 1" ifdef that was probably used while debugging to make the function non static. Change-Id: I5ba5bbb4bd2b782c605699028cf3ad2c7e8cd41f Reviewed-on: http://gerrit.openafs.org/2318 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 232024676d396ab771d6d228158d606240114bb0 Author: Simon Wilkinson Date: Wed Jun 30 08:29:28 2010 +0100 Linux: Fix pagevec use in cache-bypass Cache-bypass was still using the old style pagevec manipulation functions, and so won't build on newer kernels. Update it to use the same pagevec functions as the generic readpages code. FIXES 127505 Change-Id: I9d8acaf3165bbdf24068bd9145a2369cd0c87e4d Reviewed-on: http://gerrit.openafs.org/2298 Reviewed-by: Matt Benjamin Tested-by: Marc Dionne Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear commit 368c44b537d6940482ceefe2ef8e1fd7fd099783 Author: Andrew Deason Date: Thu Jul 1 11:57:59 2010 -0500 Document fs -human Document the new -human switch for 'fs diskfree' and 'fs listquota'. Change-Id: Ic4b4f9d7492c887085ab6da4c802cfc75fd4d08e Reviewed-on: http://gerrit.openafs.org/2314 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5fe4161270f774c8f7938c432ac84a5edcaf4c33 Author: Ben Kaduk Date: Thu Jul 1 12:47:55 2010 -0400 FBSD: do not recurse on the afs_xvcache write lock afs_ShakeLooseVcaches grabs the write lock before calling osi_TryEvictVCache. The latter calls vgone(l), which sometimes calls into VOP_CLOSE, which again trys to acquire the write lock, leading to deadlock. Drop the write lock and reaquire it in TryEvictVCache as a fix. While here, set *slept to 1 since we drop the glock. This churn was enough that the gcc no longer cached the value of AFSTOV(avc), which gets set to 0 in VOP_RECLAIM, so the subsequent VOP_UNLOCK dereferenced a null pointer. Cache the vnode pointer in a local variable for the entire function instead of using AFSTOV() everywhere. Change-Id: Ic826e7888cb400c19857c58cb6ed88b9bdd0dddc Reviewed-on: http://gerrit.openafs.org/2315 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b126561c8decdd306b37063c16d06364fc9f928b Author: Andrew Deason Date: Thu Jul 1 11:52:21 2010 -0500 fs diskfree displays 'total' not 'kbytes' Correct the fs manpage to show that 'fs diskfree' shows a header called 'total' to represent the total disk space, not 'kbytes'. Change-Id: Id827ec81dcfd79ab28eed3bc392524a378f0069d Reviewed-on: http://gerrit.openafs.org/2313 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c29f03efab46fac2f89f69cad66b114f42398ba6 Author: Andrew Deason Date: Thu Jul 1 11:22:13 2010 -0500 fs: Correct human-readable output alignment 'fs lq' output separates its space values by whitespace, but 'fs df' does not, which was causing the human-readable output for 'fs' to not be properly aligned with the output headers. Modify HumanPrintSpace to take up exactly 10 characters (9 for the value, 1 for the exponent), and have the callers print out an extra space if appropriate. Change-Id: Ied81e73e1e84df34e63fdf0c80ad86341bea0cd4 Reviewed-on: http://gerrit.openafs.org/2311 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1c92f7cc8da20b3e7f0e7564e69b06a3f4930b7a Author: Tom Keiser Date: Thu Jul 1 02:07:54 2010 -0400 nuke configure options from AIX param files Remove antisocial behavior whereby the AIX param files silently turn on the FAST_RESTART and BITMAP_LATER config options. Change-Id: Ic7f77bd6c7aefe0f17b6d8796ce204cc8a5ad4c2 Reviewed-on: http://gerrit.openafs.org/2309 Reviewed-by: Simon Wilkinson Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 582878a75858a341f674f833609f08b6d3bf839a Author: Derrick Brashear Date: Wed Jun 30 15:35:38 2010 -0400 update ticket5 from heimdal includes updated instructions for updating. note that gen_glue.c in lib/asn1 has a bug which omits a needed newline in the "const struct units * asn1_%s_units(void);", line. FIXES 127554 Change-Id: Ibc880bf51419d51de40b33d8c43122e592971b0b Reviewed-on: http://gerrit.openafs.org/2306 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e61800b992b5d54edb3656925a884753f02fc686 Author: Andrew Deason Date: Mon Jun 28 13:48:00 2010 -0500 Remove --enable-fast-restart configure option FIXES 127526 Change-Id: I80a18fe083a0d52dad9d4e2d5b14bf667c44630b Reviewed-on: http://gerrit.openafs.org/2278 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3330b9d17b2767318eef6222aceabdee47bbc703 Author: Tom Keiser Date: Wed Jun 30 18:40:20 2010 -0400 DAFS: fix VOL_HDR_IN_LRU state bit tracking For the case where the cached vp->header can be re-used by GetVolumeHeader(), we have not been re-setting the VOL_HDR_IN_LRU state bit. Although this has not affected correctness (this bit is merely used to aid in debugging), we should be resetting it in all relevant cases... Change-Id: I2ad2b8c5070470beb067efdcda6f76f6b72c006c Reviewed-on: http://gerrit.openafs.org/2308 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d8072a846cbce75fb17b0865523923722254ca56 Author: Andrew Deason Date: Wed Jun 30 12:59:24 2010 -0500 fs: HumanPrintSpace is void HumanPrintSpace never returns anything; declare it void. Change-Id: I336deb991e298b5132667a9bd7311b521fc082c3 Reviewed-on: http://gerrit.openafs.org/2304 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e10e29bc5bf53cb6fa30fa8580d8b25d00b5aed7 Author: Andrew Deason Date: Wed Jun 30 12:53:13 2010 -0500 vlclient: Remove incorrect whitespace fix Commit e59a0ff9934f8ea44ecb02e9fdaa81a29bd04b61 generated a warning since we try to assign NULL into a character. Just remove this code, since removing trailing whitespace was already handled by commit df18c9e895e75e77ed466dea3b06ef2a0a07260a. Change-Id: I915c0678a2f6893e09cf049bf71c519be554369f Reviewed-on: http://gerrit.openafs.org/2303 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3f5144b3edfca5187ce417da8929eea86c930ef0 Author: Ben Kaduk Date: Wed Jun 30 00:40:09 2010 -0400 Disable red zones for amd64 FBSD kernel code The kernel has been compiled with -mno-red-zone since at least FreeBSD 5.0; when we compile libafs.ko with red zones enabled and interact with the red-zone-less kernel, we get occasional stack corruption, which manifests itself in a variety of unpleasant ways. The flags we pass to gcc for our module build currently differ substantially from those used during a kernel build (or modules built with the kernel); I hope to transition to a module build process involving bsd.kmod.mk in the relatively near future. Change-Id: I406e264c1f96e1d893b9d12b561f48a3cbfdf57c Reviewed-on: http://gerrit.openafs.org/2297 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cf34a3e896c940813a05fe663764389a88715a70 Author: Evan Broder Date: Wed Jun 30 09:52:15 2010 +0100 Add human-readable printout to fs df This patch adds a -human option to fs df, which causes it to printout all of its values in "human-readable" form (i.e. rounded to roughly the nearest power of 1024). FIXES 124529 Change-Id: I98e4c872abec5784c6ec600d5d977c36f4a8b0ac Reviewed-on: http://gerrit.openafs.org/2301 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e59a0ff9934f8ea44ecb02e9fdaa81a29bd04b61 Author: Max Cohan Date: Wed Jun 30 09:30:49 2010 +0100 fix & enhance vlclient command-line handling Corrects an EOL bug in vlclient and adds a more user-friendly handling of request for help (i.e., '-help' now works) FIXES 125036 Change-Id: I70f6523d538e34a02536e482f99916293a195df5 Reviewed-on: http://gerrit.openafs.org/2300 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1fdce07cd9b6763ebd3c3b4327fc2c3831802533 Author: Steven Jenkins Date: Wed Jun 30 09:06:29 2010 +0100 Fix VLog so that actual levels are used Fix VLog() so that it actually uses the loglevels and does not set all log messages to level 5. FIXES 125035 Change-Id: Ia9f42a814be182215cedadb6a4837347ace32f41 Reviewed-on: http://gerrit.openafs.org/2299 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b1566e42a69935467a5869391ed20860d416fcdd Author: Ben Kaduk Date: Wed Jun 30 00:29:41 2010 -0400 FBSD: in reclaim, print the failed vnode If we fail to flush a vnode, in addition to printing a diagnostic message, also print information about the vnode; fs getfid can frequently confirm which vnode(s) are problematic, which may be useful in debugging the failure. Change-Id: Ia6e93f436f9dcd2d634c46856ede5effbf79e9cb Reviewed-on: http://gerrit.openafs.org/2296 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e8da9bf95460042ca6f91dc60008c5256e03de0f Author: Ben Kaduk Date: Wed Jun 30 00:27:11 2010 -0400 Actually invalidate the buffer in FBSD's FlushPages Chaskiel added a commented-out call to vinvalbuf() in revision bd707fb7e6 back in 2002; adding in what the current call should be does not seem to cause any problems for me. Change-Id: I2450fbaaa51b5baf2781e8a6572065e5f69b44ed Reviewed-on: http://gerrit.openafs.org/2295 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 46727481ec5c47c2d3402acb572bf0d6167690ec Author: Ben Kaduk Date: Wed Jun 30 00:21:10 2010 -0400 FBSD TryToSmush locking fixup We need to hold the interlock when we check v_flags, so do so. TryToSmush is sometimes called with the vnode already locked, as the current code appears to hold the vnode lock for the current working directory (which is probably a bug). Check if the lock is already held (panic if someone else has it!), and unlock as appropriate when we're done. Change-Id: Id09ef1e10632c7f63b590271a6339a069176deac Reviewed-on: http://gerrit.openafs.org/2294 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3688073993b57c4cd13f257294acd192e82012cf Author: Ben Kaduk Date: Wed Jun 30 00:12:59 2010 -0400 Correct whitespace in FBSD/osi_vm.c I'm about to touch this, and the whitespace was bothering me. Change the six-space indentations to match the rest of the code. Change-Id: I35a12c82f8b2b4644e58cf1f19f021282e43dc77 Reviewed-on: http://gerrit.openafs.org/2293 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 659959bea90181a08ed8e76a120b44cec3ff0b8d Author: Ben Kaduk Date: Sun Jun 20 18:49:58 2010 -0400 Correct FBSD-version conditionals for VFS locking The locking around some interfaces has changed with time. Make our preprocessor checks match the reality of when the changes were made. Change-Id: If933dd636bb908af27852897e9c77ed600759674 Reviewed-on: http://gerrit.openafs.org/2292 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c772142111d7c6554ff8de3ee00e7618b20e55fa Author: Derrick Brashear Date: Tue Jun 29 14:33:06 2010 -0400 stop abusing OPTMZ in aklog instead, abuse XCFLAGS less. sigh Change-Id: Ieda727bf62704f31ba4c1aebe3c5b8aa62c2dfed Reviewed-on: http://gerrit.openafs.org/2282 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 7b1bfb4caa800de398c7955cc75adda2a64fdd99 Author: Derrick Brashear Date: Tue Jun 29 14:32:38 2010 -0400 klog warning fix fix warning-found uninitialized variable in klog.krb5 Change-Id: Id4c78e2ceef82fcc7fbb6cdae7b6d07d74495547 Reviewed-on: http://gerrit.openafs.org/2281 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d6f5e5e64b3f1b00560bbfeb6fa8dd85814b5b03 Author: Rod Widdowson Date: Tue Jun 29 18:30:39 2010 +0100 Fix checked build of vldb_check Checkin http://gerrit.openafs.org/#change,2027 appears to have caused issues with the checked build for vldb_check. This fixed is by reflecting the structure change into vldb_check Change-Id: I12343be8a3a31cb2f6474115a8d9137dadd4ae2d Reviewed-on: http://gerrit.openafs.org/2280 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5158766dce97570e51fc3abb2c8b3405fe7c299e Author: Simon Wilkinson Date: Sat Jun 26 19:35:18 2010 +0100 Use git describe to determine build version This patch makes the configure and build system use the output from 'git describe' to determine the version of the software being built. This means that all that is necessary to create a new release is to tag the repository - removing the double sources of version information. There are a couple of fallbacks for systems which do not have git available for builds. Firstly, if a file called '.version' exists in the top level of the repository, then the version information is pulled from this file. The intention is that those packaging up git checkouts for onwards distribution will use 'git describe > .version' before producing their tarballs. Secondly, if we cannot find any version information then the version will default to 'UNKNOWN' This all mirrors the way that many others have integrated git with automake and friends - although the implementation is independent. Change-Id: I7fa4605e52181d60657ad794ca8efdb5a9fb1449 Reviewed-on: http://gerrit.openafs.org/1824 Tested-by: Derrick Brashear Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery commit 020c2284250cd26eb3b45fdbd7b96a84c0c58f5f Author: Andrew Deason Date: Mon Jun 28 11:03:28 2010 -0500 LINUX24: crfree typo crfree, not crfee. Change-Id: I4a2d4bd4e37e409b62d587b22c36f4a6d02e9c32 Reviewed-on: http://gerrit.openafs.org/2272 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 15b8e32c177ce286237a3049a6f8f4f0dd7399dc Author: Andrew Deason Date: Mon Jun 28 10:43:55 2010 -0500 LINUX24: remove pagecopy and other 2.6-only code The client background readahead code and 'readpages' implementation were only written for 2.6 kernels and used 2.6-specific constructs. Remove them, along with references to the 'pagecopy' code, and some other 2.6-only cruft in osi_vnodeops.c. Change-Id: I2e939e98bd72cd7b275b0f7a389607ee5dc94efa Reviewed-on: http://gerrit.openafs.org/2271 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5539e2b55d7413ca86e7ea26f45c796506e6a553 Author: Andrew Deason Date: Mon Jun 28 11:24:04 2010 -0500 LINUX: Remove LINUX26 conditional in proc2cred afs_osi_proc2cred contained a 2.4 implementation; remove it, since we can assume at least 2.6. Change-Id: I605856e920508cf49a975e5375ade87e00598763 Reviewed-on: http://gerrit.openafs.org/2274 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8143e99a2c6ec137313cb9405670c7791b21962a Author: Andrew Deason Date: Mon Jun 28 11:17:50 2010 -0500 LINUX24: Remove BDI references afs_backing_dev_info was still referenced in a couple of places in the LINUX24 code. Although they are properly ifdef-guarded, these lines were never getting built, so remove them. Change-Id: I55ffca5dad99124b9d451925c9fcf15b7060bb9b Reviewed-on: http://gerrit.openafs.org/2273 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cdf8e7de1658aaafe2958c28b7e1fd9bf92f4499 Author: Andrew Deason Date: Mon Jun 28 10:46:22 2010 -0500 LINUX24: NEED_IOCTL32 fixup The NEED_IOCTL32 symbol needs to protect the entire if block, not just the conditionals. Change-Id: Ie33860b1d5677cec19ed19aa1ccc1ce0a26824ff Reviewed-on: http://gerrit.openafs.org/2270 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 26cd8a302c0f91ed9cafd377e1f8dcc473a48917 Author: Andrew Deason Date: Mon Jun 28 10:42:05 2010 -0500 LINUX24: cr_ref is a regular int cr_ref is a regular integer, not an atomic_t, so we need to just assign '1' to it directly. Change-Id: I3533c79a67f7be35724cc81553d24bfecb7b81d3 Reviewed-on: http://gerrit.openafs.org/2269 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 773b4968e450601910c838232e2b281b1db176a6 Author: Andrew Deason Date: Mon Jun 28 10:33:38 2010 -0500 LINUX24: Remove group_info macros/functions The LINUX24 code has a macro and a function abstracting 'struct group_info' access. But 'struct group_info' does not exist in 2.4, and nothing calls these, so get rid of them. Change-Id: Ic38f5be27d55da9fdf6ce7889d4df6afd1464c0f Reviewed-on: http://gerrit.openafs.org/2268 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 16f19e79d1a6a13a3e07ae9be3aab50f28c06045 Author: Rod Widdowson Date: Wed May 26 16:18:26 2010 +0100 Make file offsets in vldb layout unsigned ints vlserver.h has a few cases where links through the vldb are being stored as afs_int32s. These are file offsets and should be unsigned. This commit fixes just these declarations. The code still compiles (because they are silently cast all over the shop), but it starts the tidy effort. Change-Id: Iba14bd28cb43a6ca6401be4252bb45135d8b3a55 Reviewed-on: http://gerrit.openafs.org/2027 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 233253809e978b7487956e9bd56957a848459821 Author: Simon Wilkinson Date: Sun Jun 27 15:15:33 2010 +0100 Make make_libafs_tree.pl use strict and warnings Turn on the perl use strict and use warnings options in the make_libafs_tree script to better catch programming bugs. Change-Id: Ide358d40eda3cde9dd0261af11993560da71143a Reviewed-on: http://gerrit.openafs.org/2266 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b59af55f80b2339a93ba985d496b2e9052f29b60 Author: Marc Dionne Date: Fri Jun 25 20:06:08 2010 -0400 Linux: Use filehandles for all 2.6 kernels This generalizes the use of the exportfs API and file handles to open disk cache files for all 2.6 kernels. Code outside of src/afs/LINUX (ex: afsd) can assume that file handles are used for all 2.6 kernels and can use AFS_LINUX26_ENV to check. Within src/afs/LINUX/osi_file.c, NEW_EXPORT_OPS can be used to determine if the old exportfs API (pre 2.6.24) or the new one applies. All traces of the LINUX_USE_FH define are removed. FIXES 127530 Change-Id: I6803101c56981f9f674cef581f7299656723fdf3 Reviewed-on: http://gerrit.openafs.org/2260 Tested-by: Marc Dionne Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit e7b59fb0255f5823ddf4252008281d09d7418bdb Author: Matt Benjamin Date: Sun Jun 27 20:00:37 2010 -0400 linux trivially track host signedness in afs_prototypes.h track host signedness in definition of afs_nfsclient_reqhandler, which changed in 7d1bbee02a80f045a6ae4e30410798f4785906a8. Change-Id: If85cbbb36c138fbe6ded93ba7c1c2af31825f5bb Reviewed-on: http://gerrit.openafs.org/2267 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7005aec9a4a187065048985756f618043d7ec1ed Author: Andrew Deason Date: Fri Jun 25 15:03:23 2010 -0500 libafs: correct export_reqhandler prototype The export_reqhandler function pointer takes an afs_int32*, not an afs_int32 as the fourth argument. Change-Id: I89ef9cfd23a5b673cbbb29fc710236cfe1e3c7cf Reviewed-on: http://gerrit.openafs.org/2257 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7d1bbee02a80f045a6ae4e30410798f4785906a8 Author: Andrew Deason Date: Fri Jun 25 14:17:49 2010 -0500 Use unsigned addresses in the NFS exporter Use unsigned IP addresses in the NFS exporter code in libafs. This modifies the distributed headers exporter.h and nfsclient.h. Change-Id: Ieaddf21e487ae416d7b003223566c999c64279aa Reviewed-on: http://gerrit.openafs.org/2256 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0265d5c1eb04eeb354d89d638758b84fd458b267 Author: Andrew Deason Date: Fri Jun 25 13:52:16 2010 -0500 Use unsigned IP addresses in bu* Use unsigned IP addresss in bubasics, bucoord, and butc code. This alters the public tcdata.p.h, but stays away from wire RPCs or variables used directly with those RPCs. Change-Id: Ica96172399cafbc2c347f725a966cf1db7ff1128 Reviewed-on: http://gerrit.openafs.org/2255 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 38db9afbe9b2201b97f08b3068577a1270071cb9 Author: Andrew Deason Date: Fri Jun 25 12:43:50 2010 -0500 vlserver: Use unsigned addresses Use unsigned IP addresses in vlserver code. This alters some structures in the public cnvldb.h header. Change-Id: I62725ad98d2c4e8bfe610ae9a6132fd0f54cc4aa Reviewed-on: http://gerrit.openafs.org/2254 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b65b462c58858f513f872a500d18ebe3706d5682 Author: Marc Dionne Date: Fri Jun 25 19:33:51 2010 -0400 Linux: remove some 2.6 specific code from 2.4 Remove some code that will never be compiled or used in the afs/LINUX24 directory. This includes code depending on AFS_LINUX26_ENV, and on LINUX_USE_FH which is never set in 2.4 and is going away soon anyway. Change-Id: I972262b45d3518d996756b5dc9f6e6c01450e5cc Reviewed-on: http://gerrit.openafs.org/2259 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ce2162ec99b5ac1a262b99bad3b71c51ee82faff Author: Simon Wilkinson Date: Sat Jun 26 17:39:20 2010 +0100 Autoconf: Update AC_INIT macro use Update the way that we use the AC_INIT macro to match current autoconf conventions Change-Id: Ib1ce2acd879683ff8ff178cfbd9776277ba7460f Reviewed-on: http://gerrit.openafs.org/2265 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ff959f4a2e28a4c44f4962f5077da1148748d28b Author: Simon Wilkinson Date: Sat Jun 26 15:59:21 2010 +0100 RPM Packaging: Make file types clear Make it clear that makesrpm.pl takes the bz2, rather than gzip'd, versions of the OpenAFS distribution. Change-Id: Ifb99448df5c7060186da1f13ee9c38ba95373376 Reviewed-on: http://gerrit.openafs.org/2264 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b64031310d740c9173bacd04f1a6202a2bd5cf65 Author: Simon Wilkinson Date: Sat Jun 26 15:55:29 2010 +0100 RPM Packaging: All debug kernels are bad We can't build against any of the recent Fedora debug kernels, because they have options enabled that make criticial symbols GPL-only. Just skip all debug kernel variants, rather than having to explicitly list each new Fedora release as it comes out. Change-Id: I8ed4c04b10facc79fd5a68888ddb10b368b49bef Reviewed-on: http://gerrit.openafs.org/2263 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 33872fbe570a4b86adb0ea2d5e407ca1ec9cf00e Author: Simon Wilkinson Date: Sat Jun 26 15:54:05 2010 +0100 RPM Packaging: Add support for Fedora 12 and Fedora 13 Add support for building for Fedora 12 and 13, both i386 and x86_64 Change-Id: I2bb6e86ac81eeae720b8dbf185927f6e55be826c Reviewed-on: http://gerrit.openafs.org/2262 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 370872207820e08eb58f497b4a0a49c28b18077d Author: Simon Wilkinson Date: Sat Jun 26 15:35:07 2010 +0100 RPM Packaging: Skip comments in configure.in Skip comments in the configure.in file, so we don't end up using the commented out version information. Change-Id: I14bef1d448b77c915aa04b3fe555b270ce20ac67 Reviewed-on: http://gerrit.openafs.org/2261 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fc76d416bb4f37bf55bd088f4b9893f52e097990 Author: Andrew Deason Date: Mon Jun 14 11:01:06 2010 -0500 Remove semicolon from AFS_NORETURN AFS_NORETURN had a trailing semicolon, which will confuse potential future additional attribute markers, if used after AFS_NORETURN. Remove it. Change-Id: I21fd6b874728b8ca74d0e8abd783cd5015f63e97 Reviewed-on: http://gerrit.openafs.org/2258 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 19531fb40013bce9584e1f4873724d4fa1aa6bf4 Author: Andrew Deason Date: Fri Jun 25 11:38:37 2010 -0500 ptserver: Remove IP_WILDCARDS symbol ptserver defined the symbol IP_WILDCARDS to enable the use of wildcarding in machine entries. It is always enabled, so just remove the symbol and always use the wildcard code. Change-Id: I7d45de5ef1bb0d2c95f1e1ea86fd4418cf3ddd62 Reviewed-on: http://gerrit.openafs.org/2253 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9796686c19152f8e3ccfd6b2d41a46976a3a271b Author: Andrew Deason Date: Fri Jun 25 11:30:15 2010 -0500 ptserver: Use unsigned addresses Use unsigned IP addresses in ptserver code. This alters some prototypes in the public ptuser.h header. Change-Id: Id121f32cb0b6acd575822d37bbd814636023e9ae Reviewed-on: http://gerrit.openafs.org/2252 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fbe5c7f7073324fc80ee0a80ca97e8c1980a3c95 Author: Andrew Deason Date: Fri Jun 25 09:48:38 2010 -0500 rx: Use unsigned addresses RX sometimes uses afs_int32 to represent IP addresses; make it use afs_uint32. This alters some structures in rx.h and some prototypes in rx_prototypes.h. Change-Id: I97df8a5de8f5e0355ab2056825de68bb7122e439 Reviewed-on: http://gerrit.openafs.org/2251 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3bff5ca0b69a23c709123338400e53bb3c00d9e8 Author: Andrew Deason Date: Thu Jun 24 10:19:21 2010 -0500 volser: Use unsigned addresses and volume IDs Fix code and header files in src/volser that use afs_int32 for server IP addresses instead of afs_uint32 (the worst offenders being UV_* functions). Also fix an instance of afs_int32 being used for a volume ID, and remove 'struct volser_dest' instead of fixing it, since it is completely unused. Change-Id: I1008ed158855c2a22b4605b5a037f5e68731529e Reviewed-on: http://gerrit.openafs.org/2249 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f91925aa06757c93f3b2061492f25740390296c4 Author: Matt Benjamin Date: Thu Jun 24 08:51:06 2010 -0400 windows add rx_Get/SetServiceSpecific to libafsrpc module exports Add rx_GetServiceSpecific and rx_SetServiceSpecific to afsrpc.def using the next available ordinals (267 and 268). Change-Id: I31af43e9706b922ef765a51f50f583f492ce375a Reviewed-on: http://gerrit.openafs.org/2245 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit f9c9b78a2c3e7167f22af6af813a3902af4e5e3d Author: Simon Wilkinson Date: Thu Jun 24 16:00:22 2010 +0100 Linux: Check return code from VerifyVCache in mmap afs_linux_mmap wasn't doing anything with the return code from afs_linux_VerifyVCache. Change the code so that it matches the other callers of afs_linux_VerifyVCache Change-Id: I83b949bf3b9579e5dd2e20b487862566c1d7c730 Reviewed-on: http://gerrit.openafs.org/2247 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4c89b6417fc488552ca319a895046118cc1f679c Author: Andrew Deason Date: Wed Jun 23 17:42:30 2010 -0500 Remove stale warning suppressions butc/dump.c and ubik/beacon.c have had their warnings fixed and their suppressions removed. Remove the warning suppression for tbutc/dump.c and tubik/beacon.c, as well. Change-Id: Ie3cae93932797ef5a55403f3548518af6da267f0 Reviewed-on: http://gerrit.openafs.org/2242 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 24e1c7e30fe25d80ec362d887b52b0f3f50ac8b0 Author: Jeffrey Altman Date: Wed Jun 23 12:56:17 2010 -0400 Windows: Cleanup of src/config/NTMakefile src/config/NTMakefile had the following issues: * duplicate entries for headers in $(INCFILES) * no clean: rule for $(INCFILES) * no clean: rule for $(DESTDIR)\util_cr.exe * $(INCTOOLS) dependent upon $(INCFILES) but the order is reversed in the install: rule Change-Id: I2707009d60b303ab897ed25d9245d893fa342a8e Reviewed-on: http://gerrit.openafs.org/2238 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Matt Benjamin Tested-by: Matt Benjamin commit a4b6ac7a4a51c5655d91b971e4cb7d69f7ffc2b7 Author: Matt Benjamin Date: Wed Jun 23 10:26:12 2010 -0400 windows don't include assert.h (and afs support headers) in util_cr.c Don't include afsconfig.h and afs/param.h in util_cr.c, nor assert.h. The assert was included but was in fact not used in the file, and can be ommitted, per jaltman. The OpenAFS includes are then not needed. An incorrect cast is also changed, due to jaltman. Change-Id: I3e1ad7a1d24473d6ad3ce2e401133b25b0a4c795 Reviewed-on: http://gerrit.openafs.org/2234 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 5e4c33f5634b85464945524f3b1c7022c3e921ed Author: Andrew Deason Date: Wed Jun 23 17:47:43 2010 -0500 Indicate that fssync unix sockets are the default Using unix domain sockets for FSSYNC has been the default for some time now; make it clear from the configure help output that this is the case. Change-Id: Ibe8b41361242d6cea035b7710910d7d693f60a85 Reviewed-on: http://gerrit.openafs.org/2241 Tested-by: Andrew Deason Reviewed-by: Russ Allbery commit 3a82ec0f8383446da2f15512895b280339602190 Author: Andrew Deason Date: Wed Jun 23 16:23:15 2010 -0500 ubik: Remove api for reading during write locks This reverts commit eaeff661c26b0f5a504a547952ea1d0f0241b539. The code using this API will not be in 1.6. Remove this interface for the 1.6 branch, as it is known to have issues. FIXES 127520 Change-Id: I3dfef084282b0ca8ec968872b433e60f615a9c44 Reviewed-on: http://gerrit.openafs.org/2240 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 53febebc8a69c3231fb2c7094294f59b747a6ec9 Author: Ben Kaduk Date: Fri Jun 18 00:05:14 2010 -0400 Try to flush vnodes in FBSD's unmount, bailing if necessary vflush() actually returns something! Check if we get EBUSY, and don't continue if so. Also, actually call vflush on FBSD80_ENV. Note that we currently leak refs on our root vnode, so this means umount will fail unless it uses -f, for now. Change-Id: I8f02ebfa127409f0e8567f3efa7eccf491147cbd Change-Id: Iaa4666f1004b49b69a82c778a3de60633fac880f Reviewed-on: http://gerrit.openafs.org/2214 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 73a3990f44b9aefe9281fae6ab69523a069b4adb Author: Derrick Brashear Date: Tue Apr 27 13:22:37 2010 -0400 mariner log messages for creating and removing files give a hint to event listeners that files are being created and removed Change-Id: I6202184424607e97b7d103a6e7033f950c203cce Reviewed-on: http://gerrit.openafs.org/1852 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c39aee89c0649561041e7d955dd3db40629f2570 Author: Rainer Toebbicke Date: Mon Jun 21 12:02:46 2010 +0200 Don't hold on to the afs_xvcache lock while creating a symlink Holding the afs_xvcache lock over the RPC while creating a symlink is a severe blow to performance as look-ups from other tasks likely require the lock. Drop the lock and rely solely on the fileserver to detect a clash with a same entry created simultaneously. Change-Id: Ia6de353bd9dc003addf5f3be7a8f3e769247a513 Reviewed-on: http://gerrit.openafs.org/2233 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit bd3f8adfe02aa09eedeec3cff824745eb749e473 Author: Andrew Deason Date: Wed Jun 23 10:13:39 2010 -0500 vldb_check: Interpret VLOP_* vlentry flags The flags for each vldb entry can have various VLOP_* bits set to show that the entry is locked, and for what reason. In vldb_check, output these bits symbolically instead of mentioning them in "errorflags". Change-Id: Iee7797bc701742e778391c07936eb771139bc8e9 Reviewed-on: http://gerrit.openafs.org/2236 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ee3d62becab62e2ec083ebe4d1834f232270a525 Author: Andrew Deason Date: Wed Jun 23 09:58:38 2010 -0500 vos: Interpret VLOP_* lock flags When a volume is locked in the VLDB, we are given flags for the reason why the lock was set. Make vos interpret and output this reason. This adds output to any vos command that previously printed that a volume was LOCKED. It now outputs, for example, Volume is currently LOCKED Volume is locked for a delete/misc operation Change-Id: Ie3a6f804a3e3a551840975c3689b24d3916891df Reviewed-on: http://gerrit.openafs.org/2235 Tested-by: Andrew Deason Reviewed-by: Jason Edgecombe Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9c0d9cf1e411265c56a74d76dd418bc533afdde8 Author: Rainer Toebbicke Date: Tue May 4 12:06:55 2010 +0200 patch cbd_printCBcrash - harden callback debugging Create callbackup dumps with updates locked out and add bounds checking and loop detection to the cbd program. Change-Id: I927937aef33dca261877b8f2605239f3d4763a8a Reviewed-on: http://gerrit.openafs.org/1902 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e489c44328b12637162f0a62f92f1f9b95279428 Author: Rainer Toebbicke Date: Tue May 4 14:11:30 2010 +0200 Do not corrupt volume linktable when special file already exists Upon volume creation, when a special file unexpectedly exists, e.g. due to a failed cleanup, do not blindly assume that it is the link table. Otherwise the latter's magic will get silently overwritten. Change-Id: Iba05ae771e04272a3dab5534fcfc24cda5ee7df5 Reviewed-on: http://gerrit.openafs.org/1903 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 95636c6fac3c67d0c14dfb5f53c594f942aa9b78 Author: Andrew Deason Date: Fri Nov 27 17:56:19 2009 -0500 Make ubik use unsigned addresses The ubik code currently treats IPv4 addresses as both signed and unsigned 32-bit ints. Make some instances use unsigned ints to make ubik more consistent and squash a couple of warnings. Note that this slightly alters the signatures of the public ubik functions ubeacon_InitServerListByInfo, ubeacon_InitServerList, ubik_ServerInitByInfo, ubik_ServerInit, ubik_ParseClientList, and ubik_ParseServerList, to use unsigned addresses. Change-Id: I27b6170d4de0080bf66d51a6b5332e65685ddef8 Reviewed-on: http://gerrit.openafs.org/875 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8db0c3823590e0bb7b41a9d0f48ed333067bab7e Author: Andrew Deason Date: Mon May 17 15:44:50 2010 -0500 Mention that -fakestat fakes local cellular mounts The afsd man page says that -fakestat only fakes stat information for cross-cell mount points. Technically it fakes stat information for all cellular mount points, local or foreign. Most people shouldn't care, but note the difference, since some places do have local cellular mount points. Change-Id: I9bc61a0284b7d04439578a4fc5a6adf791217463 Reviewed-on: http://gerrit.openafs.org/1979 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 8c633162b98f4aebd3449684574f8a35c9e0fa58 Author: Davor Ocelic Date: Sun Jun 20 15:38:14 2010 +0200 Provide manpage for fssync-debug and most subcmds This is another patch in the series to provide manpages for dafs-related commands. Most (if not all) documentation is coming from source documentation and DAFS articles/presentations. The primary motivation behind this is to comply with Debian guidelines requiring all binaries to have respective manpages. This patch has been sitting here for months, so it's good time to finally submit it. Note that fssync-debug also supports some vcg* commands, for which I was not able to find any documentation I could use. So, they are still left to be documented. Change-Id: I9d067766e2a90b26646edc87f15a4f533c5c8d44 Reviewed-on: http://gerrit.openafs.org/2220 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 20bf8feacddea0000578bacf5789e288d99596c5 Author: Derrick Brashear Date: Tue Apr 27 23:48:36 2010 -0400 no fs sa /afs in dynroot mode change the quick start guide so people stop asking why they can't set the ACL on /afs. Change-Id: Iffc6c95564e99c01cef1b2b54d6b35e9bd01f38c Reviewed-on: http://gerrit.openafs.org/1872 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 52ac633da7735c297fa8c43bf9098a6fe0f5beb2 Author: Andrew Deason Date: Fri Jun 11 17:40:18 2010 -0500 vol: break callbacks when needsCallback is set The needsCallback vol header field indicates that a volume has been altered by a non-fileserver program somehow, and that callbacks for the volume should be broken. So, when we attach a volume that has this flag set, break callbacks if we can. If we are not the fileserver, tell the fileserver over FSSYNC to break callbacks if we can. Change-Id: I1b1a4042f0381e8291a407b54ce9478877dacdca Reviewed-on: http://gerrit.openafs.org/2211 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 899e0385efb0d0ed9d126bdfc0db2602b225db8b Author: Derrick Brashear Date: Tue Jun 22 11:52:48 2010 -0400 rx mtu ping timing tweaks avoid potentially sending pings too often. if we aren't desperate, push out grow mtu pings to just inside call timeouts. Change-Id: Ieb28700fd02894f3308123c8f64a1ec5ae7989d9 Change-Id: I3a3557680f5486474165567786f9a2da58f34519 Reviewed-on: http://gerrit.openafs.org/2228 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6ed90d5c2d8ebce40aa9d623d9875b0aecf4d986 Author: Marc Dionne Date: Tue Jun 22 17:37:15 2010 -0400 Fix CHush test The compiler flagged this with a warning, and depending on the flags that are set, the test may not give the expected result. Use parentheses to get the intended precedence. Change-Id: If0311aae70d6e71b69e247e5b66e0dd558c2c958 Reviewed-on: http://gerrit.openafs.org/2232 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d8237165f73fec8eb51a96417c4cb5e9fbc09d65 Author: Derrick Brashear Date: Sat Jun 19 11:26:49 2010 -0400 afsd -dynroot-sparse mode for hushed cells if an admin specifies -dynroot-sparse (instead of dynroot) come up with just local cell and cell aliases showing. cell list is configured as normal. fs newcell works as normal. document it. Change-Id: Ie644ed0f9923a85da5451eafaa114ddf36daa671 Reviewed-on: http://gerrit.openafs.org/2217 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 19869b100cc144422f2e5e845773d92082a32e40 Author: Derrick Brashear Date: Mon Jun 21 01:06:38 2010 -0400 test suite warning safety make test suite compile without warning Change-Id: I4e4b63d6ce2ae73e5458913aa81308b2691044a9 Reviewed-on: http://gerrit.openafs.org/2223 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9bb0274398a0e9f6aff7714014e3eefbd77df827 Author: Andrew Deason Date: Fri Jun 11 17:39:32 2010 -0500 salvaged: Break volume callbacks on vol change The salvager code can change a volume in many ways as it fixes errors. We should break callbacks on the volume whenever we change it, as clients may have callbacks on whatever we changed. So, for the salvageserver, send an FSSYNC command to the fileserver to tell it to break callbacks for that volume. FIXES 127030 Change-Id: I1cd869371167df7d4e55ac14400865fb0a9c5154 Reviewed-on: http://gerrit.openafs.org/2210 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1f2b84f1b64625af449070eccb64639d6a8f0a12 Author: Ben Kaduk Date: Sun Jun 20 18:54:26 2010 -0400 Simplify preprocessor logic in afs_pioctl We had identical code in two branches of an if/elif/else path. Merge them together. This allows two DARWIN80_ENV blocks to be coalesced; reindent them correctly while we're here. Change-Id: Icaa047994ec970ee8187a7811ee69de2f36a0503 Reviewed-on: http://gerrit.openafs.org/2222 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit df38462c64c244d97a56e9bbd0902173adb091a1 Author: Andrew Deason Date: Fri Jun 11 17:18:07 2010 -0500 Set VolumeChanged when we create a new root dir Set the VolumeChanged flag when we create a new root directory in a volume when salvaging, since doing so changes the volume. Change-Id: Ic6cd0b0d6f9b52f2006a114269321a38d312ab9b Reviewed-on: http://gerrit.openafs.org/2212 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 591f9b6de9ab3dc5c17ad41af0241527f7f04b31 Author: Andrew Deason Date: Mon Jun 21 17:28:10 2010 -0500 vldb_check: ntohs ubik header size The 'size' field in the ubik header is only 16-bits wide. So, we must use ntohs to convert it, not ntohl. Without this, vldb_check would emit false-positive "Ubik header size is 0" warnings. Change-Id: Iaa06b6dc58b7812b359d6096c112e1f3897c60e2 Reviewed-on: http://gerrit.openafs.org/2226 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4a1efd664b08c96952d987ab8d7b5fd42c0a5526 Author: Andrew Deason Date: Mon Jun 21 15:47:06 2010 -0500 ubik: Do not hide ReplayLog errors For some reason, the ReplayLog code was printing encountered errors in the replay log as debug messages. Print them out as regular log messages instead, since these are errors that at least warrant visibility, if not more action. Change-Id: Ifba22278e2f5f33010b87eebfc484ccd3745f916 Reviewed-on: http://gerrit.openafs.org/2225 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit eec0d94f519b3e27f255b9b7a637df043951424e Author: Andrew Deason Date: Fri Jun 18 17:20:22 2010 -0500 ubik: ntohl on reading the replay log When attempting to read the replay log, ubik was not ntohl'ing all integers that were read in from the log, causing the log to appear invalid on little-endian systems. Fix it. This problem manifests as apparent corruption in the database on top of ubik when a commit is occurring when we are shut down, or a disk error is encountered during a commit. Change-Id: I82e04c59d0f55aa2105b02feb6ee332ea85eb4f3 Reviewed-on: http://gerrit.openafs.org/2224 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5f66bed5eb46b992600b7b8e3ae108d0570ac220 Author: Davor Ocelic Date: Sun Jun 20 15:27:06 2010 +0200 Update manpage links, fix doc typo in fssync-debug Change-Id: I93a4fc4c998e489c6bdc736f0f4172c752d9f030 Reviewed-on: http://gerrit.openafs.org/2219 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 307fb143617e0ad59220275c83dc4ea84e495852 Author: Derrick Brashear Date: Sat Jun 19 13:08:43 2010 -0400 update macos readmes no more APSL source is used. also, reboots are not required. Change-Id: I61217b557c6193c922bc1b72b41e076e81db49e5 Reviewed-on: http://gerrit.openafs.org/2218 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f8981f18dfdd5ae9efd03b9d247238dd83f46506 Author: Ben Kaduk Date: Thu Jun 17 00:27:51 2010 -0400 Fix aklog segfault In auth_to_cell(), we only strdup() into the linkedcell argument if there is a linkedCell in the current cellconf. However, in main(), we free linkedcell if it is non-NULL, but it is allocated on the stack and could contain garbage. free() chokes on such garbage, causing aklog to abort(). If we copy nothing into linkedcell, set it to NULL so that we do not attempt to free the bogus pointer. Change-Id: I92905a5f17021ce1bc41909f5ceb1b0344456d93 Reviewed-on: http://gerrit.openafs.org/2213 Reviewed-by: Jeffrey Altman Reviewed-by: Russ Allbery Tested-by: Benjamin Kaduk Reviewed-by: Derrick Brashear commit 196d2c7f9e3250008bf6aed2e172ec6d54e4ffb7 Author: Simon Wilkinson Date: Fri Apr 23 18:39:14 2010 +0100 Linux: Remove the BKL Recent investigations suggest that we no long require the BKL on Linux. As an experiment, remove it. Change-Id: I764fe1f6e9761ada5a0a86ba59450c0615bb1e78 Reviewed-on: http://gerrit.openafs.org/1823 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 77ebaaf639c325a8a51afdc70832ea7ed73d02a8 Author: Russ Allbery Date: Tue Jun 15 18:59:22 2010 -0700 Remove configure remnants of Digital UNIX / Tru64 client Remove the configure flag to specify the location of the Digital UNIX kernel headers and some setup for the kernel module build. Note in README that Digital UNIX / Tru64 is supported for servers only. Change-Id: I983f74068b1a1ae76d9a2b2549a8a141dba4e075 Reviewed-on: http://gerrit.openafs.org/2207 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b1a50290e6e43f2eef323cfaffdfa3fc54bfdf5c Author: Chaz Chandler Date: Mon Jun 14 00:21:50 2010 -0400 IRIX: Implement makesname() makesname() make a semaphore name for use in -type routines on IRIX. It takes as input a pointer to an allocated string buffer (sname) of size METER_NAMSZ, a string prefix (prefix), and a vnode number (v_number). When complete, sname is returned, pointing to the beginning of a NULL-terminated string containing the new name, with a maximum of (METER_NAMSZ-1) characters plus the NULL. The name is a concatenation of the string at 'prefix' and the ASCII representation of the number in 'v_number'. Note: Due to IRIX's use of uint64 to represent vnumber_t and a maximum semaphore name length of 15 (METER_NAMSZ-1), this function cannot be guaranteed to produce a name which uniquely describes a vnode. makesname() is already called from afs_vcache.c but not (or no longer) available / implemented elsewhere. Change-Id: I4331c161b68b39a4c067691c97363b637d13ff15 Change-Id: Ia0a615426dc05e01a98e53e89ec3bae3726cac34 Reviewed-on: http://gerrit.openafs.org/2155 Reviewed-by: Chaz Chandler Tested-by: Chaz Chandler Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear commit 7759e837953fdaf4027474190b865cacb4d1b0fb Author: Chaz Chandler Date: Mon Jun 14 00:18:29 2010 -0400 IRIX code cleanup Fixes a few small errors in IRIX-specific code sections Change-Id: I83e0ca1510eb2d122b9b001f5793f63dabc6ddf1 Reviewed-on: http://gerrit.openafs.org/2154 Reviewed-by: Derrick Brashear Reviewed-by: Chaz Chandler Tested-by: Chaz Chandler commit 10ada52c26ac3aa13112a91ad201dd3203bb70f8 Author: Andrew Deason Date: Tue Jun 15 12:19:25 2010 -0500 Do not assume non-valid addrs in addr hash table As part of host state verification, we were calling h_stateVerifyAddrHash to verify that all addresses for a host were in the address hash table. The problem with this is that interface addresses that are not marked as 'valid' are intentionally not in the addr hash table. So, any time there was a non-'valid' interface address in the host state, we stood a very good chance to fail to verify the state. Instead, if we have a non-'valid' address, try to verify that it is _not_ in the addr hash table (or at least, is not pointing at the host with the non-'valid' interface addr), since they're not supposed to be in there. Change-Id: I02fb0f516fa3ef384471d19bb1b970cfd8aff874 Reviewed-on: http://gerrit.openafs.org/2205 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4481a22dc7fa48c7a057f27828da44ab0b4dbf26 Author: Andrew Deason Date: Tue Jun 15 10:58:58 2010 -0500 Make h_stateVerifyAddrHash log port on errors When h_stateVerifyAddrHash logs that an error in state verification occurs, it was only logging the address of the host causing the problem. Log the port, too, since there could be multiple hosts with the same address. Change-Id: Ideee34f075948a0cb7cc1014920be5e120bdc6ef Reviewed-on: http://gerrit.openafs.org/2204 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6dc50767f88795858783fe9dbbdf90901f1fd684 Author: Russ Allbery Date: Thu Jun 3 19:50:14 2010 -0700 Fix aklog warnings when building with Heimdal Fix various warnings in the aklog and klog code when building with Heimdal. Use krb5_get_init_creds_opt_alloc if it's available rather than allocating the struct off the stack, since the _opt_init function is deprecated. Change-Id: Ieff986121de9078e9402b0a51a8855655330caba Reviewed-on: http://gerrit.openafs.org/2082 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9784847fedee9540a210f272e3c38862ba1903ea Author: Russ Allbery Date: Tue May 25 22:19:14 2010 -0500 Rework the Kerberos Autoconf probes Previously, building with Kerberos support required either passing a flag to configure giving the location of a krb5-config script, or manually setting variables specifying the Kerberos libraries and header path. Replace that code with code that checks for Kerberos libraries automatically and builds the Kerberos code if any were found, with support for doing direct library probing if there is no krb5-config script. Add several platform-specific overrides directly into the configure support, so we should be able to build out of the box on Mac OS X 10.3, HP-UX, and AIX Kerberos with the new probes. The Kerberos Autoconf macros are now the versions that come with rra-c-util and are tested with multiple other packages, so both OpenAFS and those packages will be able to benefit from further portability improvements. Update README for the new building instructions, documenting how to configure the Kerberos probes if they can't automatically figure out the location and flags for Kerberos on your system. Change-Id: Ia35bb0dbc6b94c6b4dfe8165388447dbfcb31a29 Reviewed-on: http://gerrit.openafs.org/2026 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 581aafaa698e395bfcfb7b82b595fbdef4b11279 Author: Andrew Deason Date: Tue Jun 8 17:28:39 2010 -0500 GetVolume: do not wait for offlining volumes In non-DAFS GetVolume, previously we waited for a volume with vp->goingOffline set to go offline before we return. However, the fileserver afsfileprocs.c case can treat the "going offline" case and the "is offline" case identically, so there is no reason to wait. So make the fileserver call a new GetVolume variant that does not wait. Without this, all of the threads in the fileserver can potentially be tied up by waiting for a volume to go offline, if the volume is taking a long time to go offline due to an offline request following a client slowly accessing the volume. Change-Id: I58ae11e585852130154389d8df0567432cd0c2df Reviewed-on: http://gerrit.openafs.org/2124 Reviewed-by: Derrick Brashear Reviewed-by: Tom Keiser Tested-by: Derrick Brashear commit d7c79cec8295dd34fb97e6f22bfcc69dccb9f4c4 Author: Andrew Deason Date: Tue Jun 15 12:33:48 2010 -0500 afscp: Correctly advertise local addresses afscp was reporting its local address list in net-byte order, and then giving that list as a response to RXAFSCB_WhoAreYou. Instead, convert the addresses to host-byte order, since XDR takes care of endianness foo. Change-Id: I5d7d57f811ccaeada235e694ec5f343c1ac535b7 Reviewed-on: http://gerrit.openafs.org/2206 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0b958626014b9fabb7bd4c4b925838462dc09d82 Author: Jeffrey Altman Date: Tue Jun 15 07:32:11 2010 -0400 mkvers.c - remove afsconfig.h, afs/param.h and assert.h assert() is not used within mkvers.c. afsconfig.h and afs/param.h have dependency problems in src/config/ Change-Id: I2012a01c87cbd993a70df76ee3384b43ff037b29 Reviewed-on: http://gerrit.openafs.org/2203 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit c3d55face7e3a2e1d0f6253e686cc9b1e84d4dfc Author: Andrew Deason Date: Mon Jun 14 13:28:37 2010 -0500 Fix tptserver and tvlserver install rules Commit 00c37e8634b97dba3431804cea467a046be525d5 introduced a few usages of 'ifeq' in cross-platform Makefiles, breaking the build when not using GNU make. Fix this by making the tptserver and tvlserver 'install' and 'dest' targets behave more like the 'ptserver' and 'vlserver' ones, and correct the ptserver 'install' target while we are here. Change-Id: Ia3fd9149c0f18a96a9899a5dfde41e53a45102b7 Reviewed-on: http://gerrit.openafs.org/2160 Tested-by: Andrew Deason Tested-by: Benjamin Kaduk Reviewed-by: Benjamin Kaduk Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7620e48414e7826f50a5dba86c5544512ac8a879 Author: Andrew Deason Date: Tue Jun 8 17:19:46 2010 -0500 Cleanup and doxygen-ify the comments for GetVolume Change-Id: I54788acd83779b986e78575bde11347952293be6 Reviewed-on: http://gerrit.openafs.org/2123 Reviewed-by: Tom Keiser Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a62de618552bd3a3ccb5d1988fd3b5b82cb5124f Author: Russ Allbery Date: Mon Jun 14 15:28:20 2010 -0700 Build util tests properly with make check If one runs make check without previously running make at the top level first, it didn't build the util test programs properly. Recurse into subdirectories for make check as well, and add the check, test, and tests targets to tests/util/Makefile.in Change-Id: Idc2caf4cf83a48da350e724aba2ac1228795085d Reviewed-on: http://gerrit.openafs.org/2162 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9316f209eda47362d7b96464b1fff4bd5b086da7 Author: Jeffrey Altman Date: Mon Jun 14 14:13:11 2010 -0400 Windows: ensure that afsconfig.h and afs/param.h are included The recent addition of AFS_NORETURN broke the Windows build because afsconfig.h and afs/param.h were not included everywhere. Make sure that they are. Change-Id: I5962fe1178f73273f5b3c1d269b1a125fba2d2c6 Reviewed-on: http://gerrit.openafs.org/2159 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 9579d09533d4f94c38bb4755c6df90552483b7b6 Author: Jeffrey Altman Date: Mon Jun 14 13:36:32 2010 -0400 Windows: fix definition of lstat() macro The lstat() macro definition has to take into account the version of the compiler and the size of time_t. Change-Id: Id7ad8c3956bba9832cc028db628cfabe58a1d8d9 Reviewed-on: http://gerrit.openafs.org/2158 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 9b1f0e90bf0b7bb6c2d018bb9a65986f4039e4ef Author: Jeffrey Altman Date: Mon Jun 14 13:35:12 2010 -0400 Windows: define errno_t on compilers older than 1400 Visual Studio older than 1400 (VS8) does not define errno_t. LICENSE MIT Change-Id: I27c0892d8ba4a371417f635b0d6e5677fa655422 Reviewed-on: http://gerrit.openafs.org/2157 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit eaeff661c26b0f5a504a547952ea1d0f0241b539 Author: Andrew Deason Date: Thu May 20 15:22:11 2010 -0500 ubik: add interface for reading during write locks Add ubik_BeginTransReadAnyWrite, which allows for reading from the database, even while there is a conflicting ubik write lock. Reads are still blocked while the local database is updating due to a write transaction commit. Change-Id: I5604fa3cc8a334606f5e3535aed6f6cedcb5f167 Reviewed-on: http://gerrit.openafs.org/2103 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b8177960d4e376011adf379b87d8b8ba051c0fd0 Author: Derrick Brashear Date: Sun Jun 13 22:05:27 2010 -0400 arm darwin port make things buildable on arm darwin Change-Id: I88af2b82e9ed356fd57aa8f05dfee71d7fa6cd8a Reviewed-on: http://gerrit.openafs.org/2153 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f790747143372e307dd285b08c270650dd9c5c12 Author: Derrick Brashear Date: Sun Jun 13 11:03:25 2010 -0400 ktc newpag stub when environ is not supported on macos systems where we can't get the environment, just return from ktc_newpag Change-Id: I9a169d0bf035c40d727a386bb3d2070eea225ed4 Reviewed-on: http://gerrit.openafs.org/2150 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8af23688c0a2250f64e6a7b8794fde77ae9394b4 Author: Derrick Brashear Date: Sun Jun 13 10:57:38 2010 -0400 darwin afsd include cleanup remove mach port stuff from non-kernel version (it's for DiskArb) remove sysconf, iokit, corefoundation, dns_sd from kernel version. Change-Id: Ibdf9d8a71f5f0fee659d0c05eea4811617c2b34f Reviewed-on: http://gerrit.openafs.org/2149 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cc9d358cd83c0e542b57ac6c25cb27824b638c32 Author: Marc Dionne Date: Sat Jun 12 19:43:05 2010 -0400 Linux: Fix RCU_READ_LOCK test The names of some configure defines changed with the recent autoconf cleanups. This one was missed and was left with the old value. Change-Id: Ibce5e36b8ae6becdfa61bf6e9c440b3d9a6fa272 Reviewed-on: http://gerrit.openafs.org/2130 Reviewed-by: Derrick Brashear Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear commit 1486563b2b6dc3b7d1f598aa963bd4e0f84bdb52 Author: Derrick Brashear Date: Sun Jun 13 10:54:50 2010 -0400 afsd mill dup sys/mount.h include we include sys/mount.h twice. don't. Change-Id: Ifc872488086a00d32b564d60a5f9a8b374e8f752 Reviewed-on: http://gerrit.openafs.org/2148 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3514c22d061171a1557509a728bc1fd523c9b956 Author: Derrick Brashear Date: Sun Jun 13 09:49:32 2010 -0400 generated file target in order to cross compile, allow a way to generate generated files on the host Change-Id: I9639f350b179dbeb3d45802e8685da88a3b06c83 Reviewed-on: http://gerrit.openafs.org/2147 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit de75d9d8aa490935ec65947fc6d82a19f936b119 Author: Derrick Brashear Date: Sun Jun 13 01:51:30 2010 -0400 buildtools target if you wish to cross compile, you want these things. arrange to be able to build just them Change-Id: I6bee40b61a16722c402832bba39d2e88dcabec25 Reviewed-on: http://gerrit.openafs.org/2145 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d26f5e158cffa313d0f504e7ba3afc1743b5d1ef Author: Derrick Brashear Date: Thu Jun 10 14:47:24 2010 -0400 unix cm activate mtu pings set an error code so idle dead time is enforced on sending. needed in order that MTU pings be activated. Change-Id: I8cf1ca81e6519b440fc679e85f327f338400c29a Reviewed-on: http://gerrit.openafs.org/2116 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c7f9307c35c0c89f7ec8ada315c81ebc47517f86 Author: Derrick Brashear Date: Thu Jun 10 14:37:39 2010 -0400 rx mtu ping handling engage mtu pings. only occur while a call is active but results are cached per-peer. requires idle dead time to be in use, or does not activate. (needed to time out the call, otherwise, keepalives will succeed and the call will thus not hit regular "down server" timeout) Change-Id: Ic29b1b5713fb6debde14f4adfd5019ee80cc9e3c Reviewed-on: http://gerrit.openafs.org/2115 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c62cb89abb494630c12994f702d6986de2a38fe5 Author: Derrick Brashear Date: Thu Jun 10 11:41:23 2010 -0400 path mtu don't track nonsequenced packets for the purpose of mtu discovery, we need a sequence number to correlate if a large packet is acked. don't track sequence number 0 packets. a later change adds the mechanics needed for MTU pings Change-Id: I83d4466115bbd45acdc2777bfbef0ff393dd5a3f Reviewed-on: http://gerrit.openafs.org/2114 Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit be035b08248fa3e1f31f6911e9dc877eb5d53f82 Author: Derrick Brashear Date: Thu Jun 10 11:37:35 2010 -0400 rx checkcall kill extra indirection on call for conn we already set a local variable, conn, to call->conn. use it instead of dereferencing call->conn repeatedly Change-Id: I5d38edc1d3507a717598140393094b1ba22ced46 Reviewed-on: http://gerrit.openafs.org/2113 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear commit 658d2f47281306dfd46c5eddcecaeadc3e3e7fa9 Author: Derrick Brashear Date: Thu Jun 10 11:34:39 2010 -0400 idle dead time track less retransmits don't count as sends for idle "send time" purposes. neither do ping acks. disallow both in computations. Change-Id: I599bb1111189efd21580d357c31c043f2315f910 Reviewed-on: http://gerrit.openafs.org/2112 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear commit ab45d1adc11c756f426baa076ab423b4e969b5d5 Author: Derrick Brashear Date: Thu Jun 10 11:24:09 2010 -0400 unix cm log path mtu warning when retrying if RX_MSGSIZE is analyzed and we'd retry, so indicate to our users Change-Id: I77aba5dffd4280e0ee43383cadb34aca4042cbd6 Reviewed-on: http://gerrit.openafs.org/2117 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f2f3c24b2c374e4c7e2b53cacc4959f592b8310b Author: Matt Benjamin Date: Sun Jun 13 18:16:37 2010 -0400 mcas fix gc_get_tag return type The return type from gc_get_tag is char * LICENSE BSD Change-Id: If15259858b84f71d969f1e7713371f3de4e0c3a5 Reviewed-on: http://gerrit.openafs.org/2151 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 77684b64dbf721a9a5d41aa1c70fd175fd27b329 Author: Matt Benjamin Date: Sun Jun 13 18:24:48 2010 -0400 mcas cleanup inc/dec macros fix type of intermediate value used in CAS operations, and reformat slightly. LICENSE BSD Change-Id: If49be8e020e0f735d67290440b1a74caccf90bf0 Reviewed-on: http://gerrit.openafs.org/2152 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9baec50e7bfa0d900bc33d91a277f24e72889e40 Author: Simon Wilkinson Date: Sat Jun 12 10:42:43 2010 +0100 libadmin: Don't dereference NULL pointer in cmd If DoBosHostList ends up being called without the -server argument in its command structure, then a printf will attempt to dereference a NULL pointer to the -server field. Caught by clang-analyzer Change-Id: I1114406d03b265f4d780efd8e84fea53013cb51c Reviewed-on: http://gerrit.openafs.org/2143 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 904c9fbebab97b760dd853fa393e1c576c7db00c Author: Simon Wilkinson Date: Sat Jun 12 10:35:34 2010 +0100 fs: Can't use store behind data if pioctl errored If the call to a pioctl returns an error, it's possible to reach the end of the storebehind function and try and print an old, or bogus, value from the pioctl data block. Caught by clang-analyzer Change-Id: I1209c0c24730273510fbad98a75a429917836605 Reviewed-on: http://gerrit.openafs.org/2142 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6dd07af215e2cc75cb7c902b5a06920a5ee5235c Author: Simon Wilkinson Date: Sat Jun 12 10:26:09 2010 +0100 viced: CopyOnWrite2 shouldn't return undefined val Unless CopyOnWrite2 encounters the condition where (rdlen != length) || (wrlen !=length) it will never set a value for the 'rc' return code, and so return with an undefined value. Looking at the code, it looks like rc should be 0 in all other situations, so this patch provides a default value. Caught by clang-analyzer Change-Id: If3e528f3d66abb3dde6da2304084f7698c05b863 Reviewed-on: http://gerrit.openafs.org/2141 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0deaa4d58cdd0af2b402e06df1edd0cf4d49074c Author: Simon Wilkinson Date: Sat Jun 12 10:25:07 2010 +0100 Formatting fixes Reformat the CopyOnWrite2 function to match our current coding style Change-Id: I9483c2d391932d675c6c76d6edbb2b8f519b2568 Reviewed-on: http://gerrit.openafs.org/2140 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e35e0b732db1132de4b5f9af050cf6939792ef8e Author: Simon Wilkinson Date: Sat Jun 12 00:23:22 2010 +0100 vol: open() needs mode if called with O_CREAT If open() is called with a the O_CREAT flag, then it requires a 3rd argument, containing the mode with which to create the file. On DARWIN (when we always use O_CREAT), and on other platforms where the first call to open returned E_NOENT, we weren't doing this, and so were presumably getting a random mode of whatever garbage was on the stack. Caught by clang-analyzer Change-Id: Ic173e582e0d46f6d4cf8801dc7a6b4b393db5063 Reviewed-on: http://gerrit.openafs.org/2139 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c880fe7740864daca59b93d35055c1973d9382a9 Author: Simon Wilkinson Date: Sat Jun 12 00:16:11 2010 +0100 audit: result is only used on AIX The 'result' variable is only used on AIX - only bother assigning it when we're building there. Caught by clang-analyzer Change-Id: I06848837282ff3f318474f55f2ee013255ad37c8 Reviewed-on: http://gerrit.openafs.org/2138 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 713b65adaa756b5a66ccb0620d5f2bc50642f2f1 Author: Russ Allbery Date: Sat Jun 12 16:07:52 2010 -0700 Avoid off-by-one error when saving the password in klog When klog saved the password entered by the user to allow attempts at multiple AFS principals without reprompting, it copied the whole buffer according to the declared reply length into local storage. This was done without regard to the local allocated storage size, and was then nul-terminated without regard to the allocated storage size. Both klog and Heimdal use a size of BUFSIZ for the reply buffer by default, which meant that klog on Heimdal was writing past the end of the allocated structure when nul-terminating the password. Store our allocated buffer size in the struct and only copy at most one fewer than that many characters, and then nul-terminate accordingly. (The assumption that BUFSIZ is always long enough is still bogus, but that's larger surgery.) Change-Id: Ic8d4357aad2f8dfa0fffe9849d2546a88ecd246a Reviewed-on: http://gerrit.openafs.org/2129 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bc8f2bfb1cc78458729ca29c6623adff80237018 Author: Marc Dionne Date: Sat Jun 12 20:43:25 2010 -0400 Linux s390x: replace AFS_64BIT_KERNEL with AFS_LINUX_64BIT_KERNEL The s390x param.h file defines AFS_64BIT_KERNEL, but this looks to be AIX specific, and some Linux headers expect AFS_LINUX_64BIT_KERNEL. This causes many errors because we end up trying to use struct flock64 instead of struct flock. Change-Id: I39a4a94fa895143172c1ee75ff71c2015232156f Reviewed-on: http://gerrit.openafs.org/2131 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0efea8e2b1162ef88ef27daeffa1acb69c850566 Author: Simon Wilkinson Date: Sun Jun 13 01:44:27 2010 +0100 bucoord: Use mkstemp properly Use mkstemp wherever we have it available, to silence warnings about mktemp's safety. When we do use mkstemp, use it properly. It doesn't return void, it returns an open filehandle. Convert this filehandle into a FILE *, rather than throwing it away, and leaking an open file descriptor. Caught by clang-analyzer Change-Id: Ib5864f684c6d5a8686e0a872364a645c90a29390 Reviewed-on: http://gerrit.openafs.org/2144 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ad3aa5205b8c4f645881276e4a9b7ce9066c3e96 Author: Simon Wilkinson Date: Fri Jun 11 23:59:49 2010 +0100 comerr: Don't leak CFStringRef If str is NULL on entry to _intlize, than it will leak the CFStringRef that it constructed a few lines earlier. Fix this. Caught with clang-analyzer Change-Id: I6d62e7792918da95e4fed1c676d14ad9124d93fa Reviewed-on: http://gerrit.openafs.org/2137 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5388e1425d361a52728ce113fb31fb27f7e5539c Author: Simon Wilkinson Date: Fri Jun 11 23:50:29 2010 +0100 libadmin: Don't use undefined value If IsValidCellHandle returns false, then we can jump to fail_pts_GroupMemberRemove, and end up using a value for ids.idlist_val which hasn't been defined. Fix this. Caught by clang-analyzer. Change-Id: I030d155f9ad2481250e84c31d4d7d26cb39a9c61 Reviewed-on: http://gerrit.openafs.org/2136 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6c645092eeb9c44d45d5ceab264a360eef7f2536 Author: Simon Wilkinson Date: Fri Jun 11 23:49:34 2010 +0100 Add support for clang compiler attributes Rearrange the way that we define compiler attributes so that we can define them for clang, too. Don't assume that clang will support all of the attributes that gcc does, so split them up into separate sections. Change-Id: Ic6233f5c63a07b3ef99a85ae3be9e45e28387127 Reviewed-on: http://gerrit.openafs.org/2135 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8faceb4ba4c66069a03fc03a57d8b0af03dfbefc Author: Simon Wilkinson Date: Fri Jun 11 23:46:29 2010 +0100 Add AFS_NORETURN macro and use it Add the AFS_NORETURN macro which can be used with gcc compatible compilers to indicate that a particular funciton prototype will not return control to the caller. This both improves code quality, and helps with static analysis. Use this to flag afsmon_Exit, db_panic, osi_Panic, Abort, Exit and the error handlers for osi_Assert and our local assert fn all as being noreturn. Change-Id: Ic6c4ae319af3d6f7665c9ee5072b556c01850982 Reviewed-on: http://gerrit.openafs.org/2134 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 07bd99c9d52712b0282d709d294d33d382dcbe81 Author: Simon Wilkinson Date: Fri Jun 11 23:33:07 2010 +0100 rxgen: Remove inlist from autogenerated code The 'inlist' variable is only used by code that is #if 0, and never emitted by the rxgen source. Remove the definition, and assignment, to this variable. Caught by clang-analyzer Change-Id: Ife162d392a47c48e1eebd75fe2c0af9524cd758a Reviewed-on: http://gerrit.openafs.org/2133 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 09e17c245220203b7fc14cb5908f8475d79a0707 Author: Simon Wilkinson Date: Fri Jun 11 22:25:35 2010 +0100 Changes to build with clang on Mac OS 10.5 clang defines __x86_64__ and doesn't define __i386__ when building on a 64bit Leopard machine. Change the defines in param.h so we can build on this platform. Change-Id: Icfc16ca83162e8148d4261207c05d90d12cbabc2 Reviewed-on: http://gerrit.openafs.org/2132 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 084a7f1beb9925372d3d4e0af1a2e3f388bc4a53 Author: Russ Allbery Date: Thu May 27 17:17:43 2010 -0500 Document vos listaddrs -host and -uuid Document the -host and -uuid flags to vos listaddrs. They were mentioned in the SYNOPSIS, but not in the OPTIONS section of the manual page. Change-Id: I96e6b67b7239d9455060fd0c76b8d44f41a010a2 Reviewed-on: http://gerrit.openafs.org/2083 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 2af0cca23b79da3961618640f9b0b2cccbd80bc9 Author: Simon Wilkinson Date: Sat Jun 12 22:59:23 2010 +0100 Linux: Fix set_cr_group_info and cr_group_info Commit dc85abca renamed set_cr_group_info to afs_set_cr_group_info and cr_group_info to afs_cr_group_info, but didn't catch all call sites. In particular, those in the NFS translator, in non-keyring code paths, and in the 2.4 code, were missed. Thanks to Adam Megacz for the bug report on openafs-info. Change-Id: I71f8cc27d499c98d164d05e02f7d5b2c5d4c1933 Reviewed-on: http://gerrit.openafs.org/2127 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dcd3e1fa111d3b6dfeb5965a487285119619f362 Author: Andrew Deason Date: Thu Jun 10 11:51:57 2010 -0500 Do not set inUse for non-fileserver non-DAFS Setting inUse in a volume header to anything besides 1 is a DAFS-specific change. For non-DAFS, non-fileserver programs do not touch inUse. Since inUse is not cleared for non-fileserver non-DAFS, make sure not to set it for non-fileserver non-DAFS. Change-Id: I4d50299d4dc4fd8757906ba493d182b386dd9b1b Reviewed-on: http://gerrit.openafs.org/2122 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit df18c9e895e75e77ed466dea3b06ef2a0a07260a Author: Andrew Deason Date: Fri Jun 11 16:51:02 2010 -0500 vlclient: work with non-space whitespace Make vlclient work with non-space whitespace separating arguments. This also makes it cope with a trailing newline that fgets() gives us, making this more intuitive to use. Change-Id: Ida4da9f997ac073a5afa6c95e1b3cec180c18e1a Reviewed-on: http://gerrit.openafs.org/2126 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 6bc2b1af64a12a0cd3b3792803b71e92099425af Author: Derrick Brashear Date: Fri Jun 11 15:06:24 2010 -0400 dafs state analyzer shouldn't require trailing spaces in commands the tokenizer didn't null out \n, but the strcmps for commands didn't deal, so this basically works badly interactively. all commands not recognized. Change-Id: Ifa7f8c0204a83d27f8876af8de94cb338499cdc0 Reviewed-on: http://gerrit.openafs.org/2125 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f4fb6cd4bf4bbfffef4cd3a9a36b3f5c23d447a9 Author: Andrew Deason Date: Thu Jun 10 10:29:39 2010 -0500 Remove afsio warnings and errors Fix a few warnings and errors in afsio, so it can compile: - inlcude rx/rx_prototypes.h, not rx_prototypes.h - only declare 'code' in SRXAFSCB_TellMeAboutYourself, and the global rx_mtu in AFS_NT40_ENV, since they're only used on NT40 - remove declarations of the unused variables 'host' in HandleLocalAuth, 'i' in readFile, and 'i' in writeFile Change-Id: If39420cca791669200ccb4d3f46aa5ac7eb89c7d Reviewed-on: http://gerrit.openafs.org/2121 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 48d3fd9eedc122dec2c7b76f97078c56a77af89b Author: Matt Benjamin Date: Thu May 27 19:14:20 2010 -0400 windows cm_BeginDirOp add flags (nobuildtree) Add a flags argument to cm_BeginDirOp, and define a flag CM_DIROP_FLAG_NOBUILDTREE which asserts that the operation being synchronized does not require scp->dirPlus to be constructed. Change-Id: Ibc4345574da3c1e7717c83b64a83260f70a3b06c Reviewed-on: http://gerrit.openafs.org/2053 Reviewed-by: Jeffrey Altman Reviewed-by: Asanka Herath Tested-by: Jeffrey Altman commit 60e5d85fd089af9b1efff6ac5b8577c14a04e021 Author: Simon Wilkinson Date: Fri Jun 11 10:48:37 2010 +0100 RX: Can't assert a void result We can't assert(MUTEX_DESTROY(blah) == 0) when the MUTEX_DESTROY macro already returns void (and asserts), as it does in the pthread case. This fixes the build failure introduced by 53c9258cd7300c03be3f3e50003cad3dfc59baf3 Change-Id: I0b7a30e785de3437f0c1e264b4a63c87f63b6783 Reviewed-on: http://gerrit.openafs.org/2120 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 53c9258cd7300c03be3f3e50003cad3dfc59baf3 Author: Matt Benjamin Date: Tue Jun 8 18:29:13 2010 -0400 rx service specific data Adds rx_GetServiceSpecific and rx_SetServiceSpecific to the rx_service interface, conforming to the equivalent calls in the rx_connection interface. For consistency, the implementation strategy is the same. The intended use is to more cleanly support server multiplexing within an RPC-based test dispatch library. Change-Id: I6a8968484efe2c858857008321996e67328bb75c Reviewed-on: http://gerrit.openafs.org/2097 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 157a274b8b1f6c39751d876354e1d8453d66b864 Author: Andrew Deason Date: Wed Oct 21 22:16:38 2009 -0500 Break origin's callback for RXAFS_Rename target When we RXAFS_Rename something, the status of the renamed FID can sometimes change, and thus we break callbacks on it. Currently, however, we do not break the callback for the originating client, even though the status of the target changes and we do not return an AFSFetchStatus to the caller. Since the callback is not always broken for the target, it may not be immediately obvious to client implementations to implicitly break the target's callback. Since we do not have an explicit protocol specification saying that the callback is implicitly broken, break the callback for the origin client as well, to be safe. Change-Id: I97d90518a240f852013d1d63fccef663c8b0e998 Reviewed-on: http://gerrit.openafs.org/709 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 92d67bee7aae20498eefb77c06b0a085c5d069ce Author: Andrew Deason Date: Wed Sep 9 15:56:26 2009 -0500 Avoid unnecessarily updating .. in SAFSS_Rename Currently the .. entry for a directory is always recreated on a Rename operation, even if the parent directory does not change. Now, avoid altering the directory at all (including no COW nor DV bump nor vnode modify time update) when we don't need to. Change-Id: I53478ec05e2fc6362836043476ff67e2c41b7feb Reviewed-on: http://gerrit.openafs.org/436 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b9ef2051c5affe597995df530a386baaa9807a9e Author: Jeffrey Altman Date: Wed Jun 9 13:55:14 2010 -0400 Windows: Revise SMB QuerySecurityInfo for MS10-020 MS10-020 (http://support.microsoft.com/kb/980232) has caused many problems for implementors of SMB 1.0 servers and applications that call GetFileSecurity() without checking the return code to determine if the call succeeded. The gist of the vulnerability was that the SMB redirector would pass any buffer it received to the application regardless of whether or not it was valid. MS10-020 protects the applications by strictly validating the SMB response data structure and the data in the security descriptor that is returned. The problem for SMB 1.0 server implementors is that there have been at least three different protocol descriptions for NT_TRANSACT_QUERY_SECURITY_DESC published over the last decade and all of them are incomplete. Therefore, just about no one but Microsoft has an SMB 1.0 server implementation that produces the exact out that they are expecting to validate. The end result is that in an attempt to protect applications from crashing due to invalid input being passed in directly caused dozens of applications to crash by not returning any security descriptor data at all. Even when the applications didn't crash they might not have been able to save their data. Cisco WAAS and NetApp DataOnTap systems were most adversely affected and they have had CIFS protocol licenses for many many years. To fix OpenAFS here is what needed to be done: 1. Instead of returning a security descriptor that gives ownership to the NUL SID, give it to the Everyone SID and set the flag that states that everyone has full access. 2. Validate the input parameters. In particular, check to ensure that the SMB file descriptor is valid and the file has not been deleted. 3. Enforce the maximum output data and parameter counts. 4. Handle buffer overflow and buffertoosmall conditions in the manner that Microsoft expects them to be handled. In particular, note that the parameter data which is returned in the SMB Data Region is not counted in the Data Count. Even if MaxData is 0, we can still return parameters values as long as MaxParm is large enough. LICENSE MIT Change-Id: I95034bc6f24a282decc507edcffb93bc58b986be Reviewed-on: http://gerrit.openafs.org/2110 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Asanka Herath Reviewed-by: Jeffrey Altman commit 368ba0478c79d3ab00b0440ca763babd7583b30e Author: Derrick Brashear Date: Mon Jun 7 00:29:06 2010 -0400 further constrict nat pings one more constrainment of nat pings on unix Change-Id: I8b3db989b0e16a79cd63795147145c5e0ab55e6e Reviewed-on: http://gerrit.openafs.org/2091 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 52ffc6a152fea98c5a4232c9345e7bd89b1c00b7 Author: Russ Allbery Date: Wed Jun 9 14:12:49 2010 -0700 Add additional documentation for the new test suite Add a copy of docs/writing-tests from C TAP Harness as HOWTO and add a README with some additional explanations more specific to OpenAFS. Change-Id: Ic5b04805db6b00bcb82862ad8d2ebe466f2c266b Reviewed-on: http://gerrit.openafs.org/2109 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 00c37e8634b97dba3431804cea467a046be525d5 Author: Andrew Deason Date: Fri May 21 11:47:42 2010 -0500 Install pthreaded ptserver and vlserver When --enable-pthreaded-ubik is specified, install the pthreaded versions of ptserver and vlserver instead of the non-pthreaded versions. Previously, the pthreaded versions were getting built but not installed with 'make dest' or 'make install'. Change-Id: If2f08342df4c94c1cce3001614d9e050222bf0f6 Reviewed-on: http://gerrit.openafs.org/2102 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d159cd955f4639334a963d92d82cd90318be5999 Author: Andrew Deason Date: Fri May 21 11:19:53 2010 -0500 Move FreeBlock prototype to vlserver_internal.h FreeBlock is only used in internal vlserver code and should not be called by anything else; it should not be prototyped in a public header. Move its prototype to go along with the other vlserver internal prototypes. Change-Id: Id66f046c76a9d4c454bbd6fd6e65c75dbeccf68e Reviewed-on: http://gerrit.openafs.org/2101 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7912910fd85ed28fdda8a034225ea041f554fea9 Author: Andrew Deason Date: Wed Jun 2 15:06:51 2010 -0500 Define updateUbikNetworkAddress static updateUbikNetworkAddress is static, and its prototype says so. The actual implementation of the function lacks 'static', though. Add it. Change-Id: Ida8e54cecabfffb2adbeb5f12d233668897893f8 Reviewed-on: http://gerrit.openafs.org/2100 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6ee6125f7178d9d2f93a8cb10532412bf0e295fc Author: Russ Allbery Date: Tue Jun 8 18:51:16 2010 -0700 Fix the trailing #endif comment in tests/tap/basic.h Change-Id: I3a7dbda8d2792229365df4266ca43cbb4bc815bf Reviewed-on: http://gerrit.openafs.org/2099 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 74a332e7ee69256c232e4f583f7c10e238cd3ac5 Author: Russ Allbery Date: Tue Jun 8 18:40:11 2010 -0700 Add okv function to the TAP test library Add an okv() varient of the ok() function that takes the arguments as a va_list instead of as a variable argument list. This makes it easier to reuse ok() when writing other tests. Change-Id: Icaeaaf9d6bd9d54bfd886a75961d98367ee0fb9a Reviewed-on: http://gerrit.openafs.org/2098 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 53304359a77442cf3dd3f9f2dc8543a1d16af668 Author: Jeffrey Altman Date: Mon Jun 7 18:18:39 2010 -0400 Windows: Detect if AFSCache is memory mapped to a new address The Windows AFSCache paging file contains pointer addresses that are only valid if the file is memory mapped at a specific memory address. If the file is mapped at a new address, the pointer values will be invalid and the service will crash with an invalid memory access. Check for address consistency and force the cache to be rebuilt if the consistency is lost. LICENSE MIT Change-Id: Ie7fb64659f808f09279445f47c2f1385be0a53f0 Reviewed-on: http://gerrit.openafs.org/2095 Reviewed-by: Rod Widdowson Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 8d18d4773a256b5bb567752e7f923b7713107cb0 Author: Andrew Deason Date: Tue Jun 8 10:38:07 2010 -0500 Solaris: lookup "" like "." At least on some versions of solaris, we can get passed an empty string to afs_lookup, if the root directory is in AFS (e.g. after a chroot). Interpret this as the same as looking up the "." entry; otherwise we return ENOENT, implying that the "/" directory does not exist, even if its subdirectories do. FIXES 127356 Change-Id: I84283e78fbf33b946afaf3c80ef4a1a679e8fc93 Reviewed-on: http://gerrit.openafs.org/2096 Tested-by: Andrew Deason Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b89a9e4fa001b453a3ef5f041ac7978ba696b8e3 Author: Andrew Deason Date: Tue May 18 11:39:21 2010 -0500 libafs: consistently hold vnode refs Make all common libafs code call AFS_FAST_HOLD to hold an afs vnode reference, instead of sometimes calling VN_HOLD(AFSTOV(tvc)) directly. Make AFS_FAST_HOLD always call osi_vnhold, and have each platform define osi_vnhold for their platform-specific quirks (as it was doing before). This way, if a platform has an osi_vnhold that is special somehow (on solaris, we bump a VFS refcount if the vnode refcount goes from 0->1), it will always be called on vnode references. Change-Id: I7bb2b5ac116c8e86f6c6c0d40f414523870275a3 Reviewed-on: http://gerrit.openafs.org/1987 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit eee8bc9cf9fa53488abd973249b8b61bc3f61956 Author: Andrew Deason Date: Mon Jun 7 11:42:02 2010 -0500 AIX: make osi_procname a stub 'curproc', 'curthread', or other such conveniences do not exist on AIX, so the current osi_procname implementation breaks the build. Determining the current process name on AIX is, while possible, difficult and error-prone. Since we only need the process name for informational messages to users, don't bother trying to determine it, and just return the empty string so we can build. Change-Id: I452a9786d809c3dee3da519cd3d6ca053f8d7ab8 Reviewed-on: http://gerrit.openafs.org/2094 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 54fbf60cdd62469cff724b445d01c15ba756e3df Author: Andrew Deason Date: Mon Jun 7 12:18:53 2010 -0500 Make lib/afs.exp in sys_depinstall The AIX libafs uses lib/afs.exp to build, and libafs depends on sys_depinstall. So, make lib/afs.exp in addition to include/afs/afs.exp in sys_depinstall. Change-Id: I8788a49cd4a5e7545f0f1f45572cdfb0f014c3db Reviewed-on: http://gerrit.openafs.org/2093 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a4bca7737682d23577c1f50c053438c657e85018 Author: Andrew Deason Date: Mon Jun 7 12:13:11 2010 -0500 AIX: declare code in osi_TryEvictVCache osi_TryEvictVCache was missing 'code's declaration. Declare 'code'. Change-Id: Ife5b9bfaea4d6a88bcbd82b862e26afcee1c149f Reviewed-on: http://gerrit.openafs.org/2092 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 85997ac89fd44e6658291adcd1a064ff77235566 Author: Jeffrey Altman Date: Sat Jun 5 19:34:29 2010 -0400 Windows: remove src/NTMakefile NTMakefile was moved from src to the top level. A second copy in src just gets out of sync. Change-Id: I9474fab56cee46c3acb1758aee62729c1cfadd7b Reviewed-on: http://gerrit.openafs.org/2088 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 24ff8eb0dd64d2fe948899a7273293b0eb79600c Author: Jeffrey Altman Date: Sat Jun 5 19:29:59 2010 -0400 Windows: Cleanup .exp .res .manifest and others Fix the cleanup procedure to work when the tree has not previously been built. Delete .exp, .res, and .manifest files from the $(OBJ) tree. Perform cleanup on all language directories. Change-Id: I2a24c69293066f012cb869fe67dbacb5ffdc2d43 Reviewed-on: http://gerrit.openafs.org/2087 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 380f9a46a3feda44621cfe94d93a9c70d3e9ff7f Author: Jeffrey Altman Date: Thu Jun 3 12:04:15 2010 -0400 Windows: Update fs newcell and add VIOCNEWCELL2 The Windows version of "fs newcell" did not accept any parameters and behaved quite differently from the Unix version. Instead of permitting new cell information to be added, the Windows version simply forced the existing cell information to be reacquired. This update adds a new pioctl, VIOCNEWCELL2, to support the implementation of a Unix-style "fs newcell". The functionality added here differs from the Unix version in the following ways: 1. "fs newcell" with no arguments is still accepted in order to maintain compatibility with prior Windows behavior. 2. "fs newcell -cell -dns" instructs the cache manager to add the new cell but obtain the vldb server info from DNS. 3. "fs newcell -cell ... -registry" instructs the cache manager to add the new cell and also save the cell configuration data in the registry for use the next time the service restarts. 4. The -vlport and -fsport options are accepted although the -fsport value is currently unsupported by the cache manager. LICENSE MIT Change-Id: If62cc8e1c6cc8ba2defb4cd72dae8a87b4d915e0 Reviewed-on: http://gerrit.openafs.org/2080 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman commit 82e999bf847ef88d357d86015a90cedb47eeb8ac Author: Jeffrey Altman Date: Thu Jun 3 11:59:45 2010 -0400 Windows: Freelance Import CellServDB Add a new registry option that permits automatic generation of Freelance mountpoints for every cell listed in the CellServDB info (file and registry). "FreelanceImportCellServDB". This functionality is only triggered when the afsd_service is started. The operation is performed in the background by the daemon thread after the firewall configuration is set. LICENSE MIT Change-Id: Ic6cc0738f8c185d77f9cf69d4997b8044522e50e Reviewed-on: http://gerrit.openafs.org/2079 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman commit 1faf08ccc7704f43cbe57cd54b6458db347bcf91 Author: Jeffrey Altman Date: Fri Jun 4 00:46:39 2010 -0400 Windows: engage path mtu discovery for rx Change-Id: Ice32ca652dfcf1c14577c696eaca074f61a62675 Reviewed-on: http://gerrit.openafs.org/2085 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit ab5b2d2274bcb031ee2d0f8042ab45e15f3c428c Author: Jeffrey Altman Date: Fri Jun 4 00:45:21 2010 -0400 Windows: enable circular buffer management for rx socket input LICENSE BSD Change-Id: Ibbcb6171738b4f6adfb267b5782b53ae7170b0e9 Reviewed-on: http://gerrit.openafs.org/2084 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 7c167febd559de70ec8abd74a34bbc15f44945fd Author: Russ Allbery Date: Sat May 29 16:45:04 2010 -0500 Comprehensive edit of Admin Guide chapter two (first 20%) Update and revise chapter two (Issues in Cell Configuration and Administration) of the Administration Guide for current AFS and current computing concepts. Remove references to an AFS-provided login utility and discuss local login configuration for Kerberos more generically. Further clarify the role of ssh in ensuring the user has access to files in AFS during remote login. Improve the inode and namei discussion slightly. Update the setuid discussion for the new default of disabling setuid for cells and for the known security flaws in enabling setuid. Modernize terminology for DNS around cell naming and remove the descriptions of TLDs. We can now assume our target audience knows this stuff. Move index terms into the appropriate section for what's being indexed in a few more cases. Lots of other, more minor wording changes and updates. Change-Id: Id8b1ace5afca6b8b7b2082a9a0779a4b91c89dcd Reviewed-on: http://gerrit.openafs.org/2065 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 67e837374649d4def8df6371f104c8b2af928e2a Author: Derrick Brashear Date: Tue Jun 1 13:10:32 2010 -0400 rx mtu discovery constrainment code this code makes us work in the face of a sub1500 mtu network. a subsequent commit is needed to make it more effective: attempts to grow the mtu must be scheduled so we aren't forced to heavily brute-force on failure to discover the exact mtu immediately; for performance, we do want to grow to the real mtu. Change-Id: If876c134efd4b0952035193ef00a6e780f7adc64 Reviewed-on: http://gerrit.openafs.org/2069 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 8be3eee95ebd7c387c4745d2abc0f4907df6aaf7 Author: Simona Poilinca Date: Fri Jun 4 00:42:38 2010 -0400 Windows: convert cm_config.c to use strsafe library Replaced the unsafe string functions with the safe versions available in microsoft's strsafe library. Change-Id: Id9e9acf7eaa1b045d91b972b37a411c7a94ed3ac Change-Id: I377fe4e2e5bac904f5dd28916f1244262e1933c2 Reviewed-on: http://gerrit.openafs.org/1778 Reviewed-by: Jeffrey Altman Reviewed-by: Asanka Herath Tested-by: Jeffrey Altman commit dbef3c8b0bd5bab21943071c455b4bf2436507e5 Author: Asanka Herath Date: Thu Jun 3 23:58:42 2010 -0400 Windows: Support building a lite-client installer If LITECLIENT is defined when invoking the WiX based MSI installer build, we will build a light-weight client installer MSI. This minimizes the size of the installer for users who only need client functionality from OpenAFS. The light-weight client excludes: - Server components - Control center components - Administration utilities - Debug symbols Lite-client installer can also be built by invoking target wix-lite from the root NTMakefile. Change-Id: I544cdb7170d17358eb235f3c476c468dbae62776 Reviewed-on: http://gerrit.openafs.org/2034 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 1e0c6d22d7c44aad6aa0a0051e094a3558045dd2 Author: Rainer Toebbicke Date: Wed Jun 2 18:12:36 2010 +0200 "fs checkservers" during cache creation can crash client Many pioctl calls pass as soon as the afs_resourceinit_flag is set, which happens relatively early, alas before the cell name is set. PCheckServers and others need the latter and dereference NULL. Easiest: set the cell name as soon as it is known and the dynroot initialisation piggy-backed to it can be done. Change-Id: I9985f2c4a0afddfed04b85338108b3d6e97b64e6 Reviewed-on: http://gerrit.openafs.org/2072 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a069b18dfbc2e1a4834df9cc7c477d65a05b342c Author: Russ Allbery Date: Wed May 26 13:15:30 2010 -0500 Document in SalvageLog(5) the per-partition salvager logs Document that salvager creates separate logs per partition when doing a full server salvage and then appends them all to SalvageLog when it completes. Change-Id: I2ffa8c79ef83b590f90bb014fc318559deae7113 Reviewed-on: http://gerrit.openafs.org/2035 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit a546f1cd58abcdc129035cf4614c4b55f1e1b1f8 Author: Jeffrey Altman Date: Thu Jun 3 11:54:04 2010 -0400 Windows: Fix usage of cm_FreeServerList cm_FreeServerList will set the input variable to NULL if the contents of the list could in fact be freed. If they could not be freed, the individual entries are marked for deletion and will not be subsequently used. Do not set the list variable to NULL after calling cm_FreeServerList otherwise memory can be leaked. LICENSE MIT Change-Id: Ia3cacd760d7395a2dd6b063643a8aa86f9e468b9 Reviewed-on: http://gerrit.openafs.org/2078 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 64e08dca0bdbb32ec98218a0b0fcd486108af6c1 Author: Jeffrey Altman Date: Thu Jun 3 11:51:17 2010 -0400 Windows: Reduce number of Nat Ping Connections Instruct rx library to only perform NAT pings on file server connections that are actively in use and which are anonymous. LICENSE MIT Change-Id: I6b74e8070f2c522ed13e0c06ea7a304cce525ab9 Reviewed-on: http://gerrit.openafs.org/2077 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 7e9c978b1c9d47a9da0e7f3b6cb7982596eb4cda Author: Jeffrey Altman Date: Thu Jun 3 11:49:14 2010 -0400 Windows: Fix cm_IoctlSkipQueryOptions buffer management When cm_IoctlSkipQueryOptions advances the input buffer pointer it must also reduce the available input length. LICENSE MIT Change-Id: I4e0d673e3ff5d8621e715d33d73616a22211a8a9 Reviewed-on: http://gerrit.openafs.org/2076 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 51d954a75c4343d1bc06fc784484894dd9bdb398 Author: Jeffrey Altman Date: Thu Jun 3 11:47:46 2010 -0400 Windows: do not request KEY_WRITE privilege if not required When querying the registry cellservdb info the KEY_WRITE privilege is not required, therefore do not request it. LICENSE MIT Change-Id: I050717be3afb5df979897ffbef65987160a65149 Reviewed-on: http://gerrit.openafs.org/2075 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 019174fdda5bb6eb376ea78e20db74c7e1f77fab Author: Jeffrey Altman Date: Thu Jun 3 11:44:33 2010 -0400 Windows: warning removal cast away size_t larger than afs_uint32 warnings use variables with the proper signed vs unsigned state in order to avoid signed vs unsigned comparison warnings disable deprecated string function warnings LICENSE MIT Change-Id: I78a3786a0766979c8d83cc5dbd06f91e70b0ee47 Reviewed-on: http://gerrit.openafs.org/2074 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 3ff85264903aef41e63c5a86674ec66857db69f4 Author: Derrick Brashear Date: Thu Jun 3 15:50:46 2010 -0400 darwin notify don't recurse on vcache lock afs_vop_access->afs_VerifyVCache2->afs_GetVCache->afs_FetchStatus-> afs_Analyze->afs_NotifyUser can recurse and try to notify us. Don't worry about it; we're best-effort. we lack a lock primitive to see if we own this lock. Change-Id: Ibc0c8a8164a95f0d268e5f1f42a62c3a28c4ab9d Reviewed-on: http://gerrit.openafs.org/2081 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a2f3be5265a9e8a7f2cf0dd751a9ab82d289cef8 Author: Andrew Deason Date: Thu Jun 3 09:54:28 2010 -0500 up: refuse multicharacter arguments The 'up' command currently silently accepts and discards extra characters when specifying arguments. This can produce rather confusing behavior such as mistyping '-v -1' as '-v-1' resulting in the '-v' switch being honored, but the '-1' being ignored. The same thing occurs for specifying '-v1', even though the usage message implies that you can combine arguments. So instead, report an error message for any arguments specified that are longer than 2 characters, since they are never valid. Change-Id: I64846b53248ea1d06d03b6ac1fdb4317ba04b03b Reviewed-on: http://gerrit.openafs.org/2073 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit d263fb1507a8c679fd92b5bd2b6af2f1fb8b3cbf Author: Asanka Herath Date: Wed May 26 12:34:08 2010 -0400 Windows: Fix midl options for generating stub code MIDL is used to generate server stub code for implementing SMB RPC. Fix the invocation of MIDL so that MIDL can locate include files and respect AFSDEV_AUXMIDLFLAGS. Change-Id: I31e90897c8f0d8db6746dbc94a3fe4de53aab060 Reviewed-on: http://gerrit.openafs.org/2033 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 57d7b5ccf0ddda5a7887d7e84211c3e767a407e6 Author: Derrick Brashear Date: Tue Jun 1 12:13:42 2010 -0400 rx allow setpeermtu to take a peer modify setpeermtu to work when a peer is passed in. modify existing callers. note solaris caches a whole host's pmtu, so use that on all peers at the host. Change-Id: Iba05fffd47a7c7b63742d6c539be4fe248336fb7 Reviewed-on: http://gerrit.openafs.org/2068 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ca2bce169e1742e25846ea516e6796de6ac6a282 Author: Derrick Brashear Date: Tue Jun 1 12:08:57 2010 -0400 rx setpeermtu should handle a host correctly right now, when no port is passed, we don't correctly tweak the mtu for all peers on a host. do that here. Change-Id: Ia07f592bf001415d8a76bd3326f2dc6aa0641809 Reviewed-on: http://gerrit.openafs.org/2067 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 24b7d39c5f18ca60067e5ab9c8d9c08e9c695789 Author: Derrick Brashear Date: Tue Jun 1 12:04:43 2010 -0400 aklog no krb524 kill warnings if you're disabling krb524, these variables are unused. make them not be part of such a compile Change-Id: Ib10e8fc82614b7a821daa7c77540ce246551cb0a Reviewed-on: http://gerrit.openafs.org/2066 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit af1dbcf0c9d29d2dfaf87c7f6fe64018927626ad Author: Russ Allbery Date: Thu May 27 16:40:21 2010 -0500 Add warnings for Authentication Server commands For each command only useful with the Authentication Server, add warnings that the Authentication Server is obsolete and will be removed in a future version of OpenAFS. Encourage people who care to update uss to work with a modern Kerberos KDC, recommend kinit and aklog or klog.krb5 over klog, and warn that klog will be of limited use without an Authentication Server. Change-Id: Idc78ba548134b83ac1eea0fb81a5bc38a431bb38 Reviewed-on: http://gerrit.openafs.org/2052 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f05d22c1b9bc21f0baa415444cf4f05aa1de5e0b Author: Derrick Brashear Date: Fri May 28 08:49:37 2010 -0400 prune further list of connections we natping on if it had tokens before, again, still not worth a nat ping. nor for the vlserver. Change-Id: I30281801b604b67b418b8a54a1889c54c8f6e4db Reviewed-on: http://gerrit.openafs.org/2058 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 67f1a94234e122a7dfef9808171285e456af5da8 Author: Rod Widdowson Date: Thu May 20 18:27:11 2010 +0100 Rewrite vldb_check -fix vldb_check -fix was very 'topical' in nature. It showed signs that each sucessive corruption had been treated as a one off needing a specific fix. This made the code difficult to understand and incomplete: for instance a single volume on the wrong hash only was not corrected. Further there was some rather unfortunately code which would under certain circumstances stamp the last volume at various places across the file. This checkin removes all the old code and replaces it with a 'systematic' fix. During the last scan across all the volumes, all four of the hash chains are rebuild from the ground up. We can then get rid of the outer 'Mung Until Now Good' iteration and further we benefit from a linear run time. Tested by building several different forms of broken-ness in all three chains and then fixing it. Now with improved logging and correct non insertion of nonexistant elements and clean compiled with extra warning. Change-Id: Id39d806c9c90f67c6967bd99460ba9842a043158 Reviewed-on: http://gerrit.openafs.org/1991 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 16c4b6e6c06ef2e7cfe77bca0811af9001665805 Author: Rod Widdowson Date: Wed May 19 10:45:57 2010 +0100 Add bounds checking prior to IOs in vldb_check vldb_check would just read where it was sent. This means that if a hash entry was beyond the end of file the read would fail and halt the program dead. This change adds checks for that so we can go limping on. There is no code to fix this sort of corruption. I have another (preexisting) checkin to do that which will happen once I can get a clean test run. This checkin also removes a some pointless debugging printfs. Change-Id: Ib285e113c8db024de41ffaf6c11ceb2979d07041 Reviewed-on: http://gerrit.openafs.org/1990 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 20c2acfb2b2c5e6ab36c14726dce6197202f6d4a Author: Russ Allbery Date: Fri May 28 09:42:24 2010 -0500 Reformat chapter two of the OpenAFS Administration Guide Purely reformatting to make the document more maintainable. There are no content changes. Change-Id: I349c8e86de925cbed6e09be529a22e0a08b227f6 Reviewed-on: http://gerrit.openafs.org/2059 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 2e2494d6dbc3b4584c50b87073a2b7c7a0d13604 Author: Russ Allbery Date: Fri May 28 19:15:52 2010 +0000 Add a sample test program to the new test suite Add a modified version of src/util/test_ktime to the new test suite as an example of how to write a test program with the new harness. Change-Id: Ifbceff1905f9f0dd686c2a2d2edc2f8796e7918f Reviewed-on: http://gerrit.openafs.org/2063 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 194c3f10d4c4d571e5d734baf2dd27331624c084 Author: Russ Allbery Date: Fri May 28 11:35:28 2010 -0500 Import C TAP Harness 1.2 as a testing harness Creates a new top-level tests directory that will be used for all future automated test code eventually. Import runtests and the basic TAP library from C TAP Harness 1.2. Add top-level check and test targets that build the full source tree and then the new tests directory, and then runs runtests on the test list. Change-Id: I896f8ae488cd1dfa8529a10b4b479e45e7c67afe Reviewed-on: http://gerrit.openafs.org/2062 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f7cb812d07ba854e69ca8d971cd88d93afe6e01e Author: Russ Allbery Date: Fri May 28 11:34:37 2010 -0500 Add src/tests/OpenAFS/Dirpath.sh to .gitignore Change-Id: I027d71ead7c75037bdc070932659c3f7da69dc0a Reviewed-on: http://gerrit.openafs.org/2061 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2db48258392cd24f17d0de2b46fceb9039f59953 Author: Russ Allbery Date: Fri May 28 11:03:50 2010 -0500 Clean up warnings in the tests directory Build repair.o with strict aliasing disabled because it addresses the same data structure via two different structs at the same time. Fix various other, more minor warnings. Several fixes here require more Autoconf glue to work properly, but that's deferred to future work (such as some HAVE_* defines that we don't probe for and the handling of non-native 64-bit integers in some of the code). Change-Id: I721a9fb952d2cf485d2df8e5672e5e5f5d9d6159 Reviewed-on: http://gerrit.openafs.org/2060 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4d89ce0a89e9b9e2709e6f6d730f245b5bce744b Author: Marc Dionne Date: Fri May 28 17:48:12 2010 -0400 Linux: 2.6.35 - fsync no longer takes a dentry In 2.6.35, the fsync file operations drops the dentry argument. Add a configure test and cope. Change-Id: Iaf660808d52688a4a8fd53a76d8d055602f746b9 Reviewed-on: http://gerrit.openafs.org/2064 Reviewed-by: Derrick Brashear Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear commit e4596a9d07d99ce17fcf8ae7be6e5e1c2a134e8a Author: Rainer Toebbicke Date: Fri May 28 13:41:41 2010 +0200 Typo made sysctl table invisible AC_CHECK_LINUX_STRUCT for the check for ctl_name in ctl_table instead of AC_CHECK_LINUX_FUNC. Change-Id: Ia0e0de5d62ce7f702a3f1d7a5cd4d19ef726095c Reviewed-on: http://gerrit.openafs.org/2057 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0e9d4bc6f261fc8da2a20d1d236993082f70cecc Author: Derrick Brashear Date: Tue May 18 13:41:38 2010 -0400 viced: kill console use don't open /dev/console in the fileserver. if you want this, let syslog do it. Change-Id: I1d7c0fb4a8582b6c781acdb9ae0764b64dc1c301 Reviewed-on: http://gerrit.openafs.org/1986 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ac971a6c854e466ae412389da04f91298d01f707 Author: Russ Allbery Date: Thu May 27 11:45:06 2010 -0500 Comprehensive edit of chapter one of the Administration Guide Update and revise chapter one (An Overview of OpenAFS Administration) of the Administration Guide for current AFS and current computing concepts. Replace the Kerberos Server terminology with Kerberos KDC and add additional details about the relationship between AFS and a Kerberos KDC. Remove some remaining Authentication Server references. Add some details about the Protection Server management of the mapping from Kerberos principals to AFS IDs. Remove some now-obsolete distinctions and concepts between mainframes and workstations and recommendations for server systems. Reorganize the order in which the servers are discussed to follow a somewhat more natural order. Be clear that the Backup Server is optional and that there are other methods available to back up AFS. Mention backing up to disk as well as tape in a few places. Change-Id: I57ce083a84ca2a44f7a4383d80b05508e6448284 Reviewed-on: http://gerrit.openafs.org/2045 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 760b43baa807a9c84bf2796d9f6c969819098e2c Author: Russ Allbery Date: Thu May 27 09:57:42 2010 -0500 Reformat chapter one of the OpenAFS Administration Guide Purely reformatting to make the document more maintainable. There are no content changes. Change-Id: Ic3fb32ef68c14418b3ac6bab92fda759db89b394 Reviewed-on: http://gerrit.openafs.org/2044 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5f2c6bd341674618d14658d0f642465b0f0259b9 Author: Russ Allbery Date: Wed May 26 23:23:10 2010 -0500 Add k_haspag to libkopenafs Add the k_haspag function to libkopenafs, which returns true if the current process is in a PAG and false otherwise. The implementation currently duplicates code from the ktc_curpag function since the latter calls the regular pioctl() interface and hence introduces an Rx dependency that we're avoiding for libkopenafs. This should be refactored to avoid the code duplication at some point, but that will require building a utility library that can be reasonably linked into libkopenafs and is therefore deferred for future work. Change-Id: Ib97322ef24dc3a4e48cb45090c516c95b71e9fc7 Reviewed-on: http://gerrit.openafs.org/2041 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e29bd1f8d1734c45d244df45202a4b8eb47208c1 Author: Andrew Deason Date: Wed May 19 15:04:45 2010 -0500 libuafs: Add uafs_Init compat function Recent libuafs changes changed the libuafs initialization API. Add a uafs_Init wrapper for compatibility in case someone is using the old way. Change-Id: I30611479e0c281526dc52ac6a1969ae526886537 Reviewed-on: http://gerrit.openafs.org/2047 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3da8b3773f4caa85cf7ef58016a053560b87ca59 Author: Russ Allbery Date: Thu May 27 14:53:57 2010 -0500 Make all the default target in libadmin samples and test Change-Id: Idae0c8a6bf1b057d52c1d385daab5193083b63f6 Reviewed-on: http://gerrit.openafs.org/2051 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fe8db2a6979b96f5ff622c0fe9d42f6694555419 Author: Russ Allbery Date: Thu May 27 12:33:57 2010 -0500 Clean up warnings in libadmin/bos/afs_bosAdmin.c Use the correct data structures for BOS timestamps. Use afs_int32 for the expressed timestamps for executables since that's what the BOS RPC says it's using for right now; we should change this, but when we do, warnings will catch this use along with the others. Cast some const char *'s that are passed into BOS functions that take char *'s. Change-Id: Iff3a6c42241953ed086f8e739cdb344a41a44635 Reviewed-on: http://gerrit.openafs.org/2050 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a65d755e5e862b9077439c151dc238fe4ef62725 Author: Russ Allbery Date: Thu May 27 09:41:38 2010 -0500 Clean up the introduction to the Administration Guide Provide a more useful abstract and remove the (outdated) specific list of supported platforms and the M.m version number placeholders. Update the list of associated documents to match their current titles, and provide a better description of the Reference Manual. Reformat the parent document and preface for easier maintenance in the future. Change-Id: I42ce78274ed7c4ca7a2f0b9c5ec2e6f7a786adb8 Reviewed-on: http://gerrit.openafs.org/2043 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit cc071714fad5ab3a1c27782963fbd8d4d63437dc Author: Andrew Deason Date: Sun May 16 19:47:04 2010 -0500 libuafs: Remove afsd symlink in setup Remove the 'afsd' symlink in the build setup, along with the other symlinks. Otherwise, we try to recreate it every time and fail, since it already exists. Change-Id: I8fd70d6c29695f92a5a800bea34630221d142370 Reviewed-on: http://gerrit.openafs.org/2046 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 314ae59401820ab7a2dae10263959ea055bf6bd7 Author: Derrick Brashear Date: Thu May 27 10:58:03 2010 -0400 background daemon don't wipe code before it gets used the bop allocation will clear the bop structure on reuse. don't clear the error code early. Change-Id: Ie32bef854d28a575387e2488f10c302486dfd20b Reviewed-on: http://gerrit.openafs.org/2042 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c0408db079f58b11d9c53c9e67c556cac142bcbf Author: Russ Allbery Date: Wed May 26 16:07:43 2010 -0500 Flesh out NEWS for recent work Add entries to NEWS for all development releases back to 1.5.36, which is the point at which I got bored, taken from the release announcements to openafs-announce. Try to use a relatively readable and consistent formatting for all the entries and convert the old entries to the new format (mostly). Further history can be added from the release announcements when I or someone else gets bored. Change-Id: Iaf9171c82ca74cd98be3745d9c1965efc39d889a Reviewed-on: http://gerrit.openafs.org/2036 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit c679486e554864df4c98feacc6f759cccb0b69fa Author: Russ Allbery Date: Wed May 26 14:45:22 2010 -0700 Update Debian packaging to 1.5.74.1-1 Change-Id: I828f21edffce67eaba6cfdd76e66e754a58e52a0 Reviewed-on: http://gerrit.openafs.org/2037 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0d66561a0b21572676ee1729a6e925d2f491ab6f Author: Russ Allbery Date: Wed May 26 22:04:48 2010 -0500 Fix compilation of the imported config_file.c parser Include additional missing header files for proper function prototypes, define TRUE and FALSE, and declare krb5_clear_error_message as unused so that the config_file.c will compile and pass --enable-checking. Make the build depend on krb5_locl.h. Change-Id: I25a35098aa81c9d2a0efea48257dcb958602c785 Reviewed-on: http://gerrit.openafs.org/2040 Tested-by: Russ Allbery Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 19dee933a0ca1d824edb697e43f29628cce06f55 Author: Marc Dionne Date: Wed May 26 17:50:43 2010 -0400 scout.c: only declare width once The width variable was declared twice, for the whole function and also within the for loop, leaving the first one unused and triggering a warning and a failed build with enable-checking. Change-Id: Idd061aa0e9eff1f158bfdbd67a20fe5876570089 Reviewed-on: http://gerrit.openafs.org/2039 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit dc8f18d6f5003712bc9ef989363137a84953df07 Author: Andrew Deason Date: Wed Mar 31 11:40:42 2010 -0500 Protect ubik cache accesses Currently, ubik application cached data could be updated and read by different threads simultaneously. Add a mechanism in ubik for protecting accessing and updating the cached data. This adds the function ubik_CheckCache to do this, and removes ubik_CacheUpdate as an exported function (since it's not safe). Update all callers to use the new mechanism. In ptserver, remove the 'initd' variable; just rely on cachedVersion and ubik_CheckCache to tell us when to re-read the database. Remove db.lock in buserver and cheader_lock in kaserver, which served similar (though not completely threadsafe) protection as ubik_CheckCache. Add the ubik database lock cache_lock to protect the application cache. Change-Id: I857a67d410e2c539197c5212c3b114c3fd0403c2 Reviewed-on: http://gerrit.openafs.org/1546 Reviewed-by: Derrick Brashear Tested-by: Russ Allbery commit 5698becffffb49ff49f69ce202032ae0bd9e9f7a Author: Russ Allbery Date: Wed May 26 16:47:49 2010 -0500 Fix syntax error when supergroups are not enabled 1f22cab broke non-supergroups builds due to incorrect brace placement. Move the correct closing brace outside of the #ifdef. Change-Id: I2ed3f8f57b35f0030e26306f7e791ea6b5158c9a Reviewed-on: http://gerrit.openafs.org/2038 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 916699ed412f865a80106ed4968fd2ede12d16f4 Author: Asanka Herath Date: Wed May 26 12:31:39 2010 -0400 Add /dest and /obj to .gitignore These are build directories used on Windows. Change-Id: I20c37ae4ada78949c3a09d618476286f64f9b682 Reviewed-on: http://gerrit.openafs.org/2032 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Russ Allbery commit 5f70221b2c9eb08afbbb6e0c43f6c0276cebbcf3 Author: Russ Allbery Date: Wed May 26 12:20:57 2010 -0500 Remove references to IBM AFS Change references to the documentation sets that we still ship to reference the OpenAFS manuals instead of the IBM AFS manuals. Remove references to the IBM AFS/DFS Migration documentation, since that doesn't appear to be available anywhere any more, replacing them where relevant to more generic references to the DFS documentation. Add links to docs.openafs.org for mentions of the manuals in SEE ALSO, and standardize on one link format. Replace a few references to the IBM AFS Release Notes with the actual information in those notes, or drop the reference if it doesn't seem particularly useful. Change-Id: Ie9666842f1315891c6a9c37c0424200f4b78bff7 Reviewed-on: http://gerrit.openafs.org/2031 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit deca334a5c9773f1b873b6260353c5c6cbab0af7 Author: Derrick Brashear Date: Thu May 20 11:27:10 2010 -0400 avoid nat ping for authenticated connections this is a cheap way to ensure one nat ping per server. basically, only do it for the one unauth connection we have. Change-Id: I4583112d7b4a10a0e8f524795527d99a5b2adf51 Reviewed-on: http://gerrit.openafs.org/2010 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9f9ffb7822bf85fc24d29b63c09c124b1e9875af Author: Russ Allbery Date: Wed May 26 11:33:29 2010 -0500 Remove references to AFS Product Support in -oktozap salvager and salvageserver's documentation of -oktozap says to not use without consultation with AFS Development or Product Support, left over from the IBM product. Remove those references and add a caution more in line with open source. Change-Id: I136dc145caf3e8e3a992c239e1a46d86f96580ed Reviewed-on: http://gerrit.openafs.org/2030 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 1f22cab96abd1ec83ea5c0d9c3fc1a405385b8ea Author: Russ Allbery Date: Wed May 26 11:28:57 2010 -0500 Remove -rebuildDB flag to ptserver The -rebuildDB flag was documented to rebuild the Protection Database at startup, but it was accepted and ignored in the ptserver source, doing nothing. Remove the documentation and the option recognition in ptserver. Change-Id: I36f30f38464b602cb4739a958663a6feb5fe27bf Reviewed-on: http://gerrit.openafs.org/2029 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 46192481ec162c68491c43635c16047d1b03ecf5 Author: Russ Allbery Date: Wed May 26 11:25:39 2010 -0500 Remove documentation of kaserver -fastKeys -fastKeys wasn't accepted by the kaserver binary, but was still mentioned in the usage message and the kaserver man page. Remove the remnants of the flag. Change-Id: Ifb3ae49ea0cab80c325a77b0eb1062944697b53d Reviewed-on: http://gerrit.openafs.org/2028 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c3f85a084b5b07d4c289cecda92d319e9d94cb7f Author: Simon Wilkinson Date: Tue Apr 27 22:53:47 2010 +0100 Add an OpenAFS config file parser This adds a Kerberos INI style config file parser to OpenAFS, using the parser contained in Heimdal as a base. Currently, it only exports a very small number of functions, but exporting further functions is simply a matter of adding additional shims to hide the Kerberos context and other specifics. Note that we don't want to just use the parser as a library because firstly, we don't want OpenAFS to have a Kerberos dependency (as other crypto mechanisms will, and do, exist). Secondly, MIT and Heimdal use a different API here, so we would have to shim anyway. Also, our own parser means that we don't need to worry about passing in the krb5 context, and all of the issues that that presents. Change-Id: Ic0a5ddf03266c454827c6505d5f6ffefcddd2614 Reviewed-on: http://gerrit.openafs.org/1935 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 55945926f99affdbe3461fa9a1aff751c5ad3c03 Author: Michael Meffie Date: Wed May 19 12:37:35 2010 -0400 scout: adjustable column widths Adds new command line option to scout so users can set the number of characters to display without truncating. Change-Id: I69f159549d7f5b4cfee26c276ad34705f504ee2b Reviewed-on: http://gerrit.openafs.org/1951 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 54b3fbe775077c4c4f832a14fae2d046de97fd9a Author: Derrick Brashear Date: Tue May 25 18:21:32 2010 -0400 dumpstuff nbytes can't exceed 32 bits the read returns a 32 bit type; we can't possibly need to write 64 bits. (ssize_t is 32 bits on macos and so this ends up being a bad shift) Change-Id: I4d8f99b0c752a2c75ce65b9cfa1b3cb0d484cc7f Reviewed-on: http://gerrit.openafs.org/2024 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0875e29832d496532720812f6ece54813a7a893d Author: Russ Allbery Date: Tue May 25 14:37:05 2010 -0500 Synchronize LICENSE files We have two LICENSE files, which had been somewhat independently modified. Resynchronize them, remove trailing whitespace, and convert from ISO 8859-1 to UTF-8. Change-Id: Ia3dba0e328e7f026362e2e8efda206c34ce4e768 Reviewed-on: http://gerrit.openafs.org/2025 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c8261c63f9e804b62172b48d676d5be03620de2a Author: matt@linuxbox.com Date: Mon May 24 20:26:46 2010 -0400 windows handle NONODE case uniformly in cm_BPlusDirDeleteEntry Fix handling of a NONODE case in cm_BPlusDirDeleteEntry. Previously in this case, the routine referenced uninitialized memory. Change-Id: Ic3e3520b4c28ccc52e04486777bdcf0c5e54ef1f Change-Id: Id57a72112caf55b4b84ed64f709b8b73c72b7866 Reviewed-on: http://gerrit.openafs.org/2017 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit f7bca6eefdacf2adb6e60bc3eb04fb5b05dae277 Author: Heimdal Developers Date: Sun May 9 19:33:54 2010 +0100 Import of code from heimdal This commit updates the code imported from the external heimdal git repository to their revision 64651b4be5be1eaacd4388c428cb936cb8be34b5 which is described as switch-from-svn-to-git-1210-g64651b4 This commit imports the Heimdal configuration file parser. Change-Id: I9e061c439f9aabd4f09c876811bd1033d3f25f22 Reviewed-on: http://gerrit.openafs.org/1934 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b7eb19f81d83400ae05749c2fd244476e53d2bf3 Author: Derrick Brashear Date: Tue May 25 00:03:16 2010 -0400 fs getserverprefs needs a larger buffer it's very easy for the size of server preferences to be too large for the default buffer. cope. Change-Id: I0535edf784eb9e9a309dc17e571719e204b9d29b Reviewed-on: http://gerrit.openafs.org/2021 Reviewed-by: Russ Allbery Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e917fc5c474e11e47b656295d73514ca9ec45626 Author: Simon Wilkinson Date: Sun May 16 22:48:52 2010 +0100 Autoconf : Kill dead code Remove unused autoconf macros - they're not being called, and so have bitrotted, and are just cluttering up the tree. Change-Id: Ib2d1fc5121b6845cf0b500e5aef8ca822be58ad3 Reviewed-on: http://gerrit.openafs.org/1971 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 5219a6b33b8ea7a793d5b0797026abd7b187f85e Author: Simon Wilkinson Date: Thu May 20 11:57:20 2010 +0100 Linux: Disable syscall probes if we have keyrings If we are building for are kernel with keyrings, and we can guarantee that we can make use of those keyrings, then we no longer need to probe for the syscall table at all. Change our default behaviour so that when these two conditions are true, syscall probing is disabled. Both --enable-linux-syscall-probing and --disable-linux-syscall-probing can be used to override the autodetection and force things one way or the other. We have to check that we can use the keyrings because there was a window in the 2.6 kernel series where keryings were available, but the key_type_keyring definiton (which we use to create the session keyring) wasn't exported. In that situation, we attempt to traverse the process table and use the type of init's session keyring. This traversal is fragile, and if it fails, keyring PAGs will be disabled. So, we still want to be able to fall back to patching the syscall table, if we can, in this case. FIXES 125215 Change-Id: I11ba5c68fe37609bbd6b9c9f7e7c699334f42ebc Reviewed-on: http://gerrit.openafs.org/2002 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 13dba17d5a845475e8c68ae00c4b77fee12d48c6 Author: Andrew Deason Date: Thu May 6 15:40:36 2010 -0500 vol, volser, and viced type fixes Correct many uses of incorrect types for file offsets, sizes, etc. in the volume server, fileserver, and the volume package. Thanks to Tom Keiser who pointed out the incorrect types and suggested solutions. Change-Id: If4aedfe0cc06d05b3775069ae1285d4c330976cd Reviewed-on: http://gerrit.openafs.org/1920 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Russ Allbery commit 8a869e0ef99a10f5f26d4f65a96fba5a6440ce93 Author: Russ Allbery Date: Mon May 24 22:21:29 2010 -0500 Add libafs_tree to .gitignore Change-Id: Iff4a22319be1659f123a3a8b62c27a39d957bc29 Reviewed-on: http://gerrit.openafs.org/2020 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f924010fbcdcf7e8800165cdcdc4acfedc7225b6 Author: Russ Allbery Date: Mon May 24 22:03:49 2010 -0500 Fix libafs_tree's cross-architecture support The results of libafs_tree are supposed to build on any platform that shares the same basic kernel code, but this had broken in two ways: libafs_tree was including a pre-built afs/param.h, which needs to be regenerated on different architectures, and the Linux kernel build makefile was being pre-generated despite having some architecture-specific options. Copy over more of src/config and postpone generation of afs/param.h and generation of libafs/Makefile to the libafs build. Remove the substitution of AFS_SYSNAME from make_libafs_tree.pl; it was unused and now definitely shouldn't be used since it will break the architecture-independence of the resulting tree. Change-Id: I2730d3745cc67cf5f3ae61cf4643842f87865a80 Reviewed-on: http://gerrit.openafs.org/2019 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8aa5328bd539f88d4e090959e5bd95a19992bcff Author: Russ Allbery Date: Mon May 24 21:34:53 2010 -0500 Postmoderize use of AC_CHECK_TYPE Use AC_TYPE_SSIZE_T to handle the ssize_t check (introduced in Autconf 2.60). Use AC_CHECK_TYPE, not AC_CHECK_TYPES, to check for sig_atomic_t and socklen_t, and define them in afsconfig.h if they're not present on this platform. Do not define them in stds.h, since stds.h is an installed header file and cannot rely on Autoconf defines. Change-Id: I80e1a00efc84420002a95d6cafc25ea70befa49d Reviewed-on: http://gerrit.openafs.org/2018 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 48d3ec164bf76708c10d817e7601105cc2798153 Author: Russ Allbery Date: Mon May 24 14:28:01 2010 -0500 Update fs {get,set}serverprefs documentation for DNS Mention in the fs getserverprefs and fs setserverprefs documentation that VL servers may also come from DNS AFSDB and SRV records. Document that SRV record information is not (yet) properly used. Change-Id: I223efedf4d00ac1b57b3dce74a807790691abdbf Reviewed-on: http://gerrit.openafs.org/2015 Tested-by: Russ Allbery Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 6916146b466676bc95df000ca4c367ea7c971133 Author: Derrick Brashear Date: Tue Apr 27 13:16:20 2010 -0400 report server address when known for afs warnings if we have the server info, give an address with the error. we could probably give the program name too, as for flock warning, but... Change-Id: I508572357c8c7027003900156dbb1a09ace04731 Reviewed-on: http://gerrit.openafs.org/1851 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2f0998ff13fe55e74011bd32317697274f807cc5 Author: Derrick Brashear Date: Mon May 24 16:12:24 2010 -0400 getcapabilities avoid panic when cell is not filled for a new server, getcapabilities is not safe, as cell may not be filled. Change-Id: I0926034c1d9e9c8c08e7ca993de1bcef9c0de8cf Reviewed-on: http://gerrit.openafs.org/2016 Reviewed-by: Russ Allbery Reviewed-by: Simon Wilkinson Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dd7b9235e677f92d928f0db40afaab9a1c3ee580 Author: Rod Widdowson Date: Tue May 18 14:48:38 2010 +0100 Read volume at correct address when looking for broken forward links. vldb_check was reading a volume at the index rather than the file offset to read the volume. This was giving rise to phantom warnings since the hash was usually 0. The possibility of a broken flink is determined in another manner which is why in normal case we are not flooded with warnings. At the same time make the error message slightly more coherent. Change-Id: I35f237772819f6418eb9f8d77e0902bca28c4134 Reviewed-on: http://gerrit.openafs.org/1983 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3313e7499642c39b0be1574102b8cdf6bfa565b5 Author: Simon Wilkinson Date: Sat May 22 09:40:05 2010 +0100 Autoconf: Tidy up resolver retrans retry test There's no need for the retrans retry test to be a TRY_RUN test, TRY_COMPILE will pick up the existence of the '_res' structure and its elements. Also, clean up the use of the cache variable to set the result. In the old implementation a true test result would print '1', not 'yes', a false result would result in bad output in the config.log, and a cross compiling output would give #define HAVE_RES_RETRANSRETRY no which will give unexpected results with #ifdef tests. Change-Id: If78c1b01ee89242c67f87238ca502ce43718c6a2 Reviewed-on: http://gerrit.openafs.org/2014 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ffb6cbfc1ee41ac83a27c094d82bd1c68ef4861c Author: matt@linuxbox.com Date: Sat May 22 19:40:03 2010 -0400 windows map lstat to _stat (mrafsStyleLogs) Provides function macros mapping lstat to _stat, in Windows param files (i386, amd64, i64). change per jaltman Change-Id: I414422f26114fc270dff0b5915765bf3906a400e Reviewed-on: http://gerrit.openafs.org/2013 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3015ef6c594fa999c29e390a76c384eed09619d4 Author: Russ Allbery Date: Sun May 9 17:58:33 2010 -0700 Update bos addkey/listkeys and KeyFile man pages for asetkey Clearly prefer asetkey to bos addkey in the KeyFile, bos addkey, and bos listkeys man pages. Reference asetkey list and asetkey delete as alternatives to bos listkeys and bos removekey. Distinguish between Authentication Server cells and Kerberos v5 cells and mention the preferred afs/ principal format. Add some cautions around matching enctypes and salts when synchronizing keys with a v5 KDC. Update man-pages/README for completion of this task, clean up some other wording, and remove some other now-irrelevant information. Change-Id: I29b83a61cbdb08de508bdb313524a307e385044b Reviewed-on: http://gerrit.openafs.org/1938 Reviewed-by: Jeffrey Altman Reviewed-by: Andrew Deason Tested-by: Russ Allbery Reviewed-by: Russ Allbery commit 5ae464b185115e3537bbef862d893190bb56ab05 Author: Ben Kaduk Date: Fri May 21 21:39:16 2010 -0400 Do not lie about needing Giant Catch up to 2005. Giant has not been needed for vnode page operations for quite some time now. Change-Id: I59c7b4fb1f7cd4133d459d801db9bb6d9cef866f Reviewed-on: http://gerrit.openafs.org/2012 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit adb901ac887043747360c4c9bb3fc51523f8c56e Author: Marc Dionne Date: Wed May 19 16:49:07 2010 -0400 Linux: remove unused label The out label is no longer used and triggers a warning. So just remove it. Change-Id: Ic701b82fcd4f93ddf3673dbc16618201314f6fb3 Reviewed-on: http://gerrit.openafs.org/2000 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a48a6c2a62e3511ec5652295ffee61122c1d6cbf Author: Simon Wilkinson Date: Wed Feb 24 21:39:10 2010 +0000 More warnings cleanup Remove uneccessary warning inhibition in vol/ Update README.WARNINGS to match the current state of the tree Change-Id: Ic1e5c74e0e7c2ccce0519b1572034f3666aa75e9 Reviewed-on: http://gerrit.openafs.org/1392 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bf2e4dd23e751540666c0c7961e47d4b5d06667b Author: Simon Wilkinson Date: Wed May 19 18:11:58 2010 +0100 Linux: Use positional r/w, not llseek The Linux read/write file operations take a position. Use this position to determine where we're reading or writing in a file, rather than using the vfs_llseek() operator to set the file position argument. This avoids a potential race condition, as well as simplifying this code. Change-Id: I82b4a109f9871fa2ce5b308bc32923b1bf910920 Reviewed-on: http://gerrit.openafs.org/1993 Reviewed-by: Andrew Deason Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3d686e41948cce63c95b1f2f69011019dad42607 Author: Derrick Brashear Date: Wed May 19 10:57:31 2010 -0400 dafs: don't restart for new binaries using mrafs scanner time if binary restart times are enabled, dafs restarts every time due to a flawed comparison. fix it. Change-Id: I7eff4eb6406dc7eef12c75491191566a906a4adf Reviewed-on: http://gerrit.openafs.org/1992 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e57c3b7bf6723016308497bd9377eb2de9ab6c14 Author: Simon Wilkinson Date: Thu Apr 29 19:06:37 2010 +0100 Unix CM: Use macros for process name and id access This patch uses the new osi_procname() macro to obtain the process name for setpag() warnings on BSD and Darwin, and osi_curproc() to obtain the process identity, simplifying the code. Change-Id: I1f8a4d4bbcdb09eaeea3712b1fffd1aaa3cd2fa7 Reviewed-on: http://gerrit.openafs.org/1878 Reviewed-by: Derrick Brashear Reviewed-by: Matt Benjamin Tested-by: Derrick Brashear commit 4dab5984b7a221ef4e0b871411f58f6f33116547 Author: Derrick Brashear Date: Tue May 18 10:42:28 2010 -0400 mrafs logs don't clobber existing logs if a restart happens too quickly, we can wipe existing log files in mrafs log mode. cheat. assume we won't have too many sub-second starts. Change-Id: I86d652410d0f18609d305decff54f122e2b87f10 Reviewed-on: http://gerrit.openafs.org/1984 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 42a280f50daf6e4dc65873150c4738aacf2c3a86 Author: Ben Kaduk Date: Wed May 19 01:44:44 2010 -0400 Do not sleep in FBSD's getevent() Calling osi_AllocSmallSpace drops the glock, which allows a race condition that caused a rather fast deadlock on multiprocessor systems. Use afs_osi_Alloc_NoSleep instead. Change-Id: I9a328567a31fe0e4f77e7548fed31b7e4ff36f50 Reviewed-on: http://gerrit.openafs.org/1989 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c433f3d8eeb81d5c5091d104e53bf48a6d25e747 Author: matt@linuxbox.com Date: Mon May 17 21:28:56 2010 -0400 linux PageCheck may be PageFsMisc Define the PageCheck family of functions using PageFsMisc equivalents if those are found. I encountered a need for this on Centos 5.5 (2.6.18-8.el5xen), but it may be more general. Change-Id: I365a769614fd7514e0c0223bf1854cce09f759f7 Reviewed-on: http://gerrit.openafs.org/1982 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 41dd0be8e30dc4edf7e3c087736dc41d625cecc5 Author: Derrick Brashear Date: Tue May 18 13:06:44 2010 -0400 darwin afs.conf: growlagent example provide an example usage of the growl agent Change-Id: Ic680008784a85d877049dee429d8f77f5ce8f5f7 Reviewed-on: http://gerrit.openafs.org/1985 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d0abe56aa47d4561ba57527d53a2b0db2ea613c2 Author: matt@linuxbox.com Date: Sun May 16 19:58:39 2010 -0400 linux include osi_compat.h in rx/LINUX/rx_knet.c Does include osi_compat.h in rx/LINUX/rx_knet.c Change-Id: I0d8c0a6931c7594c424edeb03000695a7cb50ba0 Reviewed-on: http://gerrit.openafs.org/1981 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5ea24a7c5534b4fda7904284d21d34b6e52a3f27 Author: Simon Wilkinson Date: Mon May 17 20:15:46 2010 +0100 Fileserver: Don't sync every 10 seconds The patch which moved our calls to fsync into the background, added a sync prior to each batch of fsync calls. This is an incredibly bad idea. POSIX says that sync "shall cause all information in memory that updates file systems to be scheduled for writing out to all file systems". On Linux this means that we in effect perform an fsync() on every open filehandle on the entire system, and in addition flush all superblocks and journals out to disk. This makes the following fsync() calls superfluous - sync() will have already written out all of the data. Add to this the fact that the fileserver is doing this every 10 seconds, and this becomes a major performance bottleneck, particularly if the machine uses a journalled fs - as any disk operations will end up blocking whilst the journal is written to disk. Change-Id: Id06cb99ae83af2e4a82e7b20fb14b8457dc16883 Reviewed-on: http://gerrit.openafs.org/1977 Reviewed-by: Andrew Deason Reviewed-by: Rainer Toebbicke Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 54bf41004b901ca090d63e239768588fa90bc806 Author: Jeffrey Altman Date: Mon May 17 16:01:03 2010 -0400 rx: work harder to notice and handle MorePackets request in particular, we did badly at handling kernel requests for more packets, but other cases did not properly keep packet stats either. attempt to globally better handle demand for more packets. Change-Id: I88837fed880f582444221ec53d280ca4070b607d Reviewed-on: http://gerrit.openafs.org/1978 Tested-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Reviewed-by: Hartmut Reuter Reviewed-by: Derrick Brashear commit af6b80f25726dbafc8bf3b2aaf15309e7f3d41fa Author: Simon Wilkinson Date: Mon May 17 08:40:49 2010 +0100 Autoconf: Use AC_CACHE_CHECK AC_CACHE_CHECK has been available since Autoconf 2.5 (released in 1995), and provides a simpler mecahnism for performing cached checks than AC_CACHE_VAL does. Modify all of our simple AC_CACHE_VAL calls to use AC_CACHE_CHECK. Change-Id: I490f5e6ae5a3fdc1ada88aba9cd22c89d415a376 Reviewed-on: http://gerrit.openafs.org/1974 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 249e3f9c21ffc280892fdd0e006e3e3a2a1e0300 Author: Derrick Brashear Date: Sat May 15 09:30:57 2010 -0400 afsprefs: clarify restart requirement don't make the red text make it seem like a restart is always needed Change-Id: I9c533ac4e25f623ad62183a42ff279c1d77fd5fe Reviewed-on: http://gerrit.openafs.org/1961 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 644162ae3de315adbf6d9e3cd4d647f87174cb42 Author: Rod Widdowson Date: Wed May 12 15:48:25 2010 +0100 Clean up logging from vldb_check. vldb_check used to say "%: Volume '' not found in hash " for two sorts of failures - If the volume really wasn't in a hash chain of that type at all - If volume's next pointer (for the hash type) pointed to a volume with a different hash. In both cases it would then print out some confusing (and spurious) information about the next element in the chain, prior to applying the same fix (of zeroing the next pointer). This change fixes the error message. Change-Id: I5eb6ae1a461628d401b997dde4bab53a0cc7571d Reviewed-on: http://gerrit.openafs.org/1955 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 01d08c0ce879487226d78f423588b27b18d888f7 Author: Rod Widdowson Date: Sat May 15 16:25:26 2010 +0100 Stop overanxious htonl in vldb_check -fix vldb_check -fix is corrupting the server entries (Number, Partition, Flags). This is because it is doing a htonl on what is a char field. The read code already has a comment "make sure not to ntohl these, as they're chars, not ints". This change strips the corresponding htonl from writeheader (and puts in a similar comment). Change-Id: I5902be0f1e928521bfcb5ec66edd227c08ea2bdc Reviewed-on: http://gerrit.openafs.org/1964 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2736eb7b090bcec9756c55f312cc97a4521f8b02 Author: Simon Wilkinson Date: Sun Apr 25 20:36:06 2010 +0100 Demand Attach: Volumes and vnodes are different fssync-debug attempts to copy sizeof(Volume) bytes into an object defined as a Vnode, a sure fire way to make things go boom. gcc on Snow Leopard picks this up as a buffer overflow, and warns about it. Fix the problem by only copying sizeof(Vnode) bytes. Change-Id: Iadcda0b465f9a9f310dcbe4d3862ea479e052674 Reviewed-on: http://gerrit.openafs.org/1834 Reviewed-by: Tom Keiser Reviewed-by: Alistair Ferguson Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6fd1db1a86e830b3758772a79f25c30080c4dd06 Author: Simon Wilkinson Date: Sun Apr 25 20:23:27 2010 +0100 Demand Attach: Simplify __VVGC_entry_cl_add The __VVGC_entry_cl_add was giving an uninitialised variable warning for empty_idx, because it was using a separate variable, empty_found as a sentinel for when empty_idx was holding a real value. Simplify all of this by removing the sentinel, and making empty_idx being -1 mean 'not found', and a real value imply found. Change-Id: I6c485993df1ff8dfd27824234c811af998ff94fa Reviewed-on: http://gerrit.openafs.org/1833 Reviewed-by: Tom Keiser Reviewed-by: Alistair Ferguson Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 44da0b32ee192017a080e26037e4f4b18e90717c Author: Simon Wilkinson Date: Sun Apr 25 20:14:02 2010 +0100 Demand-Attach: Remove dangerous trailing else Change 9aa09f5e634db8a8b2dedf3a749f2a90ef206e2f introduced a dangerous trailing else into the VScheduleSalvage_r function: #ifdef A if (foo) { ... } else #endif #ifdef B if (bar) { ... } #endif something_else() In a situation where we have A && !B, then something_else() ends up only being run when foo is false. Given that something_else() is VOL_LOCK, this will not end well. In the real world, we hit this problen when we build the volume package with SALVSYNC_BUILD_CLIENT and !FSYNC_BUILD_CLIENT - in other words, whilst building the fileserver. Change-Id: I97e07a6e730df8ac480d295b4cf30b0695ace511 Reviewed-on: http://gerrit.openafs.org/1832 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cea3bf909ab4b0807ef9f7d93235b4daeb1290dc Author: Ben Kaduk Date: Mon May 17 00:22:32 2010 -0400 Enable PutVCache for FBSD80 and higher Matt's patches in a123bd8ccd brought in support for FBSD 7.0, but also disabled several calls to afs_PutVCache() for FBSD80 and higher. Matt says that that patch was focused on 7.0, so the 8.0-related bits may not be relevant. I have run with the PutVCache calls enabled, and if anything, my system seems more stable with them. Change-Id: I8d906848e977d4974e4dcdc151964bb2ac3116b6 Reviewed-on: http://gerrit.openafs.org/1969 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit ed2f4f8d3d92761d38b1ebfba8187e5e02745be1 Author: Ben Kaduk Date: Sun May 16 00:43:35 2010 -0400 Kill FBSD4X with fire We haven't even pretended to work on the 4.X series for quite some time, and keeping this code around just makes things (slightly) harder to read. AFS_FBSD_ENV is now equivalent to AFS_FBSD50_ENV (though the latter should not be used). Leave the fbsd_4 sysnames in afs_sysnames.h for archival purposes. Change-Id: Ibebda92967ca26c3dd4bf0b2cc6a66ae3a94d0ff Reviewed-on: http://gerrit.openafs.org/1968 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 0b3e411bfcd1ffc719c41a3f62137f75b17a09ab Author: Simon Wilkinson Date: Sun May 16 23:14:11 2010 +0100 Autoconf: Use AC_CHECK_MEMBERS AC_CHECK_MEMBERS has been available since autoconf 2.50, which was released in 2001. Use this, rather than rolling our own mechanism to check for structure membership. Change-Id: Ic63bfdd6c448ce3cf2ed13d8f1f36d02e18bd223 Reviewed-on: http://gerrit.openafs.org/1973 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit aa7273233d39be552897d2180426820a3755deed Author: Simon Wilkinson Date: Sun May 16 22:56:13 2010 +0100 Autoconf: Use a standard test for socklen_t Use the standard AC_CHECK_TYPES mechanism to check for the existence of socklen_t, and to typedef it as an int if it's not found, rather than growing our own. Change-Id: Ib5aeb600750558167f63833dd4a7480dbe312b8a Reviewed-on: http://gerrit.openafs.org/1972 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0f36d82e896b7f3783ef11ec4196e5009aee162a Author: Ben Kaduk Date: Sat May 15 17:11:15 2010 -0400 Do not try to increase the refcount of a NULL vnode osi_lookup is not guaranteed to give us a valid vnode, so check before calling VN_HOLD(). Change-Id: I3d2a4d441f6991c08beccb6b10a428f5746db146 Reviewed-on: http://gerrit.openafs.org/1967 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c0afd1419de3fb8cab44ac212d0a85a9998c7cba Author: Andrew Deason Date: Sat May 15 23:12:33 2010 -0500 Solaris: do not call VFS_RELE with GLOCK VFS_RELE can call afs_freevfs, which grabs GLOCK. Thus, don't call VFS_RELE with GLOCK held or we can try to recursively acquire GLOCK and panic. This is currently unlikely to occur (sans vfs refcount unbalances) without support for forced unmounts, since the last vfs ref will usually come from the caller of afs_unmount(). But it still may be possible. Change-Id: I152bd13abc2e90f258f98194833c50c3a2846904 Reviewed-on: http://gerrit.openafs.org/1966 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 7e32fbea90821d5321352cb86b18533fb34f0409 Author: Hartmut Reuter Date: Fri May 14 13:25:44 2010 +0200 Don't use afs_linux_storeProc with memory cache, it only works with disk cache. Change-Id: I54585c61c66af7160d0ddbcbc1251fa42fbf44d8 Reviewed-on: http://gerrit.openafs.org/1958 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9562721b89a2a7a7f32a165762d7fba8540006a9 Author: Andrew Deason Date: Wed May 12 13:59:06 2010 -0500 Solaris: stop NetIfPoller on shutdown The NetIfPoller code that is enabled on AFS_SUN510_ENV never gets shutdown properly. The current code looks as if it was intended for NetIfPoller to recognize the appropriate termState and just return, but we never wait for it, and so we can complete the shutdown sequence without NetIfPoller ever knowing that we are shutting down. This can cause the machine to panic, as we keep attempting to run NetIfPoller even after libafs has been unloaded. Since NetIfPoller is fired by default every 30 seconds, we probably do not want to wait for it to fire during shutdown. Instead, just destroy the necessary timeout and task queue, which will wait for NetIfPoller to complete if running, and will just prevent it from running in the future otherwise. Change-Id: I25f9536d2713baf524a2450400c428ac506525f1 Reviewed-on: http://gerrit.openafs.org/1957 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 7730769ccfebd2a268503b6e618609722cc3b4a5 Author: Jeffrey Altman Date: Wed May 12 11:27:17 2010 -0400 Windows: move afsconfig.h / param.h to afscred.h move the inclusion of afsconfig.h and param.h to afscred.h so that they are included everywhere and so that the conditional use of _USE_32BIT_TIME_T is applied consistently by afscred.h. LICENSE MIT Change-Id: Id8c595509ec381ff6df6186e4d1c809413782a59 Reviewed-on: http://gerrit.openafs.org/1956 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 135042cd8c1beee7c045ce3b0b86272bf85a5464 Author: Jeffrey Altman Date: Wed May 12 10:25:01 2010 -0400 Windows: netidmgr_plugin must include afsconfig.h In order to properly use afs headers afsconfig.h must be included first in afsfuncs.c. Update the makefile to specify the correct include paths. Since this results in the afs assert.h being used, we must include the lib file that includes the AssertionFailed function. LICENSE MIT Change-Id: I46f76410ea16eeffeb8406ef4e89120a3255366a Reviewed-on: http://gerrit.openafs.org/1954 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 54f66f3722a6ddc0c35f5ab509c317f7278c0373 Author: Jeffrey Altman Date: Wed May 12 10:24:03 2010 -0400 Fix missing semicolon in non-AFS_NAMEI_ENV builds vol/nuke.c Change-Id: Ibfd37180199aecf6f79fbc84e2f035678e826d17 Reviewed-on: http://gerrit.openafs.org/1953 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 96868e5cda94ba3a11a8cbf3df98e7032198b239 Author: Jeffrey Altman Date: Wed May 12 10:22:07 2010 -0400 Windows: fix consistency of afsconfig-windows.h Windows is a AFS_NAMEI_ENV platform Windows (as of WDK 6) defines socklen_t as signed int Change-Id: I0aa549309d19c745e4df50d510c19f3174b1f2eb Reviewed-on: http://gerrit.openafs.org/1952 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 0dd5159163e464e35ccc73eb79225ea9fc0cd872 Author: Derrick Brashear Date: Fri May 7 10:32:09 2010 -0400 inlinebulk analyze errors afs_Analyze was not being called on inlinebulk errors if the error potentially required a retry. do so. Change-Id: I60fc0a7553f9ce592c40c7aecb60346e138468f0 Reviewed-on: http://gerrit.openafs.org/1926 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 34b0fef60a555de11590631fce1e92454457fc72 Author: Jeffrey Altman Date: Sat May 8 21:38:05 2010 -0400 Rx: prevent rx_rpc_stats mutex from being a global bottleneck Prior to this patchset, the 'rx_rpc_stats' mutex was superior to both the 'peer->peer_lock' and the 'rx_peerHashTable_lock'. That meant that the 'rx_rpc_stats' was being held across many operations that walk the peer hash table. For example, rxi_ReapConnections, rx_disablePeerRPCStats, and rx_shutdown. Since every RPC issues a call to rx_IncrementTimeAndCount, the reap connections event would effectively bring all RPC processing to a halt. This patchset moves 'rx_rpc_stats' later in the hierarchy and restructures rxi_ReapConnections, rx_disablePeerRPCStats, and rx_shutdown so that not only doesn't the 'rx_rpc_stats' mutex need to be held across the entire function but the 'rx_peerHashTable_lock' does not need to be held while complex operations on the peer object are taking place. rxi_ReceiveDebugPacket is also fixed to hold the rx_peerHashTable_lock and peer_lock at appropriate times while completing its function. Change-Id: I1a11798f1bb2a8f03316c6c455954bd6b8d1459b Reviewed-on: http://gerrit.openafs.org/1928 Tested-by: Jeffrey Altman Reviewed-by: Dan Hyde Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit f793bc07e12b86561bc05eab9eb37dda55d792f5 Author: Jeffrey Altman Date: Wed May 12 00:58:30 2010 -0400 Windows: Add support for NetWkstaGetInfo levels 101 and 102 On Windows 7, NetWkstaGetInfo levels 101 and 102 are queried. Add support to the WKSSVC RPC Pipe service. LICENSE MIT Change-Id: Ia780ee69834c01c2d0c2965ae2c65f80d504a923 Reviewed-on: http://gerrit.openafs.org/1950 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 953a2049a9a451a1f4015a64f8c5153044beba13 Author: Jeffrey Altman Date: Mon May 10 09:07:50 2010 -0400 Windows: Prevent overflow during percent used calc in Explorer Shell Ext In the Volume Info and Partition Info dialog boxes, percent used was overflowing the variable due to using too small a variable and multiplying before dividing. FIXES 126846 Change-Id: I9a8a9275d22675cfb53c9e520758f2c4d6606954 Reviewed-on: http://gerrit.openafs.org/1939 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 63ed515374bb0f7fea9436a7346382d65c6efa6f Author: Jeffrey Altman Date: Sun May 9 10:50:07 2010 -0400 Windows: Freelance vs ACLs If the user attempts to list acls or set acls on the freelance root.afs volume, generate a meaningful error. Change-Id: I6e5b147bf0cdd98ec0224a723098f5bbcb37b1e1 Reviewed-on: http://gerrit.openafs.org/1931 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit ed0fa83863308653381896cccddb0fc931a02dde Author: Jeffrey Altman Date: Sun May 9 20:49:05 2010 -0400 Windows: use system CreateUuid instead of afs variant The afs_create_uuid function on Windows results in duplicate uuids being produced. Windows provides its own CreateUuid function. Use it when afs_create_uuid is called. Change-Id: Id7f14b13c003fb845d90b09c3ca40cf258a53dbc Reviewed-on: http://gerrit.openafs.org/1937 Tested-by: Jeffrey Altman Reviewed-by: Rod Widdowson Reviewed-by: Jeffrey Altman commit afaecee40f4ae07bdf6c1419e70bdecbd5aa9526 Author: Jeffrey Altman Date: Sun May 9 10:15:30 2010 -0400 Make afsio be useful on Windows and fix bugs On Windows, the stdin and stdout handles default to text mode which corrupts data piped through them. At the start of readFile and writeFile, the mode is now set to binary. The ProbeUuid callback is supposed to determine if this client is the same as the one being requested. Since we are advertising a new uuid in TellMeAboutYourself and WhoAmI, we should perform the uuid check and return a valid answer in order to avoid confusing the file server. Add support for TellMeAboutYourself. On Windows, return valid interface information. Always print verbose output to stderr. Display MB/sec to three decimal places. In readFile, always perform a AFSFetchStatus operation otherwise we have no idea what the file size is. On Windows, the path separator is backslash. Change-Id: I174eda991383301d01fe5d6431d459b6ea01a0be Reviewed-on: http://gerrit.openafs.org/1930 Tested-by: Jeffrey Altman Tested-by: Hartmut Reuter Reviewed-by: Jeffrey Altman commit 6d48026f86794ecf4dba70cc3f8f5ebd685c5255 Author: Jeffrey Altman Date: Thu May 6 17:12:48 2010 -0400 Windows: RXAFS_InlineBulkStat errors must be processed via cm_Analyze RXAFS_InlineBulkStatus does not return errors such as EACCES, VNOVOL, VNOVNODE, VOFFLINE, VBUSY, VIO, VMOVED, etc. as an RPC return code. Instead they are returned in the status info errorCode field for each file. Traditionally, the error associated with the first FID in the query list has been returned to the caller of cm_TryBulkStatRPC(). However, the error has never been processed through cm_Analyze() which means that the per-vnode processing for VNOVNODE and the volume global processing for VMOVED, VNOVOL, etc. has never been performed. As a result, failover to other .readonly volume instances cannot occur, volume moves will not be handled, and files that have been deleted are not detected. This patchset makes the following changes: 1. If an inline bulk operation has been performed and the inline errorCode is a volume global error, then that error replaces the RPC return code within the cm_Analyze() processing for the RPC. This will affect whether or not a retry operation is performed. 2. The variable 'inlinebulk' is reset to 0 at the top of the cm_Analyze() loop in case failover from an inlinebulk capable file to an inlinebulk incapable file server takes place. 3. The FID that is passed into cm_Analyze() is not a real fid. Instead it consists of the cell and volume but vnode = 0. This ensures that the error (if any) is not applied to the directory object. 4. If an inline bulk operation was performed, prior to performing the cm_MergeStatus() operation a vnode a check is made to determine if an error was returned for that vnode. If so, cm_Analyze() is called with no connection, a fake cm_req_t, the fid, and the error. This permits cm_Analyze() processing to be performed on the file. LICENSE MIT Change-Id: I91b10faae085b52ba753b3942215951e2122b937 Reviewed-on: http://gerrit.openafs.org/1918 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit dea064a5090dfdc0011dd4254f7d801b4b77cf9e Author: Michael Meffie Date: Tue May 11 15:54:53 2010 -0400 Linux: missing configure test Add the kmem_cache_create test for dtor to the configure to build again on older versions of linux. Fixes, osi_vfsops.c:264: error: too few arguments to function ‘kmem_cache_create’ Change-Id: I1c1aa63e8dbe2df6c9b889edaa66708d7db01847 Reviewed-on: http://gerrit.openafs.org/1948 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7237efdabc75049a70af4bb079dd7b2dd439dd17 Author: Simon Wilkinson Date: Thu May 6 22:22:50 2010 +0100 Remove intptr.m4 We now require an autoconf version of at least 2.60. This version supplies AC_TYPE_INTPTR_T and AC_TYPE_UINTPTR_T, so we no longer need to have our own. Change-Id: I362324d1cfb39efb01c3f6f2d95eb7f4ed041998 Reviewed-on: http://gerrit.openafs.org/1919 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 88d13f1f58546460201aded9335acb411bc49d1a Author: Derrick Brashear Date: Tue May 11 11:40:09 2010 -0400 vnode alloc bitnumber returns bitnumber fix function return types to match a bitnumber (int) and comment the function appropriately Change-Id: I9542c02b1aa7aacdd0596675992bb1e8a1708572 Reviewed-on: http://gerrit.openafs.org/1941 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 134b599c3ad475685dd0a7251d192e38966fef4c Author: Andrew Deason Date: Wed May 5 13:51:23 2010 -0500 vlserver: prevent duplicate IPs via ChangeAddr Add a safety check in VL_ChangeAddr/ChangeIPAddr to check if we are adding a duplicate server IP in the database. Return VL_MULTIPADDR when we try to do that. Change-Id: Iaff2792b90f4152dac5a1ab4c1072ef56fef518b Reviewed-on: http://gerrit.openafs.org/1927 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f2ac483c2bdb018c4f225d2781f15b7926d5063b Author: Jeffrey Altman Date: Sun May 9 20:46:11 2010 -0400 Windows: define HAVE_SSIZE_T The windows param.*.h files define the ssize_t type. Therefore, we must define HAVE_SSIZE_T in order to avoid a collision with the ssize_t typedef in afs/stds.h. Change-Id: Ie34cb565f09acfffe985476d24dbca917b05c5db Reviewed-on: http://gerrit.openafs.org/1936 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 8aa46c5a66bfb18c4ef8452ad7d124af556a7813 Author: Simon Wilkinson Date: Sun May 9 19:40:58 2010 +0100 Add a list of files to import from Heimdal Add an initial list of files to import into OpenAFS from Heimdal. Currently this is just the list that are required to support our new configuration file parser. Change-Id: I785bacc603121f587378fcfbe93e585290c8ab7f Reviewed-on: http://gerrit.openafs.org/1933 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 43f4e3a51248683aeff77da94410a95baba3d83e Author: Simon Wilkinson Date: Sun May 9 19:37:52 2010 +0100 Add a tool to import external repositories This commit adds a tool to aid with the importing of external git repositories. import-external-git.pl allows a developer to easily update the src/external portion of the tree to the latest release of externally developed software. It's currently intended to support our use of Heimdal functions, but could be extended to support any project whose code we wish to use in the kernel, and which has a git repo. Change-Id: I6d91474c5de67e57fb73ff4d59c5afe9bb14c240 Reviewed-on: http://gerrit.openafs.org/1932 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 13ebb6412b4603be50de30789ba048bef485171b Author: Jeffrey Altman Date: Sat May 8 22:41:39 2010 -0400 Windows: fs.c requires size_t len not int len Missed one case of an 'int len' being passed into StringCbLength. Also, remove one instance of 'int len' that was not used at all. LICENSE MIT Change-Id: I457d4ae98adf9d4ca0c1b7dcb74470d9bbc85a54 Reviewed-on: http://gerrit.openafs.org/1929 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit fd9ab5cb7c7346ad443072767a360d902578e87b Author: Russ Allbery Date: Thu May 6 12:30:23 2010 -0700 Include common param file for Linux alpha builds The sysname for Linux Alpha is alpha_linux_26 (or 24 or 22) with an extra underscore before the version, unlike all the other Linux sysnames. Allow for that case when deciding whether to include the common Linux param header. Change-Id: Icab3a9214d0bd020b846734cce27da6c1bdeab56 Reviewed-on: http://gerrit.openafs.org/1915 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b811e4f91e756643dc2c7da7179ba63e2e0f5803 Author: Ben Kaduk Date: Fri May 7 00:47:53 2010 -0400 Define osi_procname for FBSD The kernel linker doesn't like to load modules with unresolved (implicitly-defined) symbols (understandably). Make it happy. Change-Id: I23fdbb9c9e07a0c583580f5c5eee577a04fae278 Reviewed-on: http://gerrit.openafs.org/1925 Reviewed-by: Simon Wilkinson Reviewed-by: sanket Reviewed-by: Derrick Brashear Tested-by: Benjamin Kaduk commit 7ba5c7263d60230f54a3229d1ffd89a3c76b416d Author: Ben Kaduk Date: Thu May 6 23:31:26 2010 -0400 Actually fix build for FBSD80 after vcache refactoring One more s/tvc/avc/ Change-Id: Ie99310bb08da5bf7aaee022e9c0ca43d1a33c3db Reviewed-on: http://gerrit.openafs.org/1923 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit de68cdef9ef647bfa59aa6f330c5202afce1d100 Author: Ben Kaduk Date: Sun Apr 4 19:34:24 2010 -0400 Add entries for FBSD 8.1 and 9.0 Though neither have been released, yet, RELENG_8 and HEAD are starting to get changes that we need to conditionalize on. Change-Id: Ia3af3c38abe4d0d01e0cef974771b45a97d3d9aa Reviewed-on: http://gerrit.openafs.org/1691 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 07098dc6708472cf5624b368d63efbdef7d409b8 Author: Simon Wilkinson Date: Thu May 6 15:00:00 2010 +0100 Modernise use of AC_CHECK_TYPE Prior to autoconf 2.13, AC_CHECK_TYPE took two arguments, the type to check and the a default type to use if that type wasn't defined. This usage has been deprecated since 2.13, and the AC_CHECK_TYPE macro itself now behaves differently. Whilst there is a compatibility mode, the autoconf documentation discourages its use. We also have an occurence of a slightly more modern AC_CHECK_TYPE, where we explicitly #define a default value if one isn't provided. The autoconf manual also discourages this form, however, in favour of using AC_CHECK_TYPES, and placing suitable typedefs in an external header file. Modify our code so we do things in the recommended way. Change-Id: Ie28067f2c90e9a3aa25cfde45ef081da2d380ee1 Reviewed-on: http://gerrit.openafs.org/1914 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 972a4072827fb2ec680354d5adebc2c5cca06939 Author: Simon Wilkinson Date: Thu May 6 14:58:52 2010 +0100 Always include afsconfig.h in autogenerated files Modify rxgen and compile_et so that the files they output always contain afsconfig.h before afs/param.h. This avoids problems where afs/param.h, or headers included from it, rely on having the results of configure tests available. Change-Id: I0198500a17abd31ee1057d6780cbe5a5e1bc8c59 Reviewed-on: http://gerrit.openafs.org/1913 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dc9bef83b0fa416bd1bd5a1524aa4a697873b91a Author: Antoine Verheijen Date: Thu May 6 09:10:38 2010 -0600 OpenBSD: Use osi_obsd_Free() for all releases of OBSD Use osi_obsd_Free() in afs_osi_Free() for all releases of OpenBSD, not just releases from 4.4 onward. Otherwise, afs_osi_Free() will use AFS_KFREE, which does not exist, since OBSD/osi_machdep.h is not included, resulting in unresolved symbols when trying to load the kernel module. Change-Id: Ic9632c9df347cc17e122b6302ef14e63fa5b68b4 Reviewed-on: http://gerrit.openafs.org/1910 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8fe309e6b67297e7d59bc001af62e0847cabce78 Author: Antoine Verheijen Date: Thu May 6 09:09:19 2010 -0600 OpenBSD: Use FREE instead of KFREE In OpenBSD releases prior to 4.2, use the system (kernel-specific) FREE macro to release space in the kernel module, not KFREE. The latter does not exist and results in unresolved symbols when trying to load the kernel module. (This was undoubtedly a typo.) Change-Id: Id66704ab4d0928e2ce1234de16bb74fe22f4f9c7 Reviewed-on: http://gerrit.openafs.org/1909 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8e27248698766e3d97e18363c5c4729a4e02add7 Author: Simon Wilkinson Date: Thu May 6 14:55:59 2010 +0100 Always include afsconfig.h Our coding standards say that OpenAFS source files should always have #include #include at the start of the file. Including just param.h, or having these includes in a different order can produce unexpected effects, because param.h includes sysnames.h, which in turn includes stds.h, which may rely upon having the results of configure tests available. Fix the obvious places in the Unix build which get this wrong. Change-Id: I081f04dab30a6bbb49fe71d3ac2d7c11e231e2f5 Reviewed-on: http://gerrit.openafs.org/1912 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3e449fcceed35200fa76ed586b6ab8cf60a8ec0f Author: Marc Dionne Date: Wed May 5 18:15:05 2010 -0400 Fix typo: LockType -> lockType Fix simple typo that causes a build error. Change-Id: I85f2899850383746094b7e9bab81dea13c2caeab Reviewed-on: http://gerrit.openafs.org/1908 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8b6550a09026e299dbaa48356aca02d1d5b1803c Author: Derrick Brashear Date: Sun May 2 19:06:43 2010 -0400 fcntl write lock on readonly file error fix apparently we return EROFS where we should return EBADF. Fix the error the client gets; the RPC is unchanged (and indeed shouldn't be changed) Change-Id: I738f1ee36f39d03bf018c0f91c7de9c8ed8cc9a9 Reviewed-on: http://gerrit.openafs.org/1895 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5c192d15ac611cd44b0f3f65796a5b10b7246c56 Author: Derrick Brashear Date: Wed May 5 15:50:07 2010 -0400 afsdump scan kill warnings make prototypes for all initialize error table functions appear Change-Id: Icc72f5218a2f6e0444a325c7fc9a0c1c34843344 Reviewed-on: http://gerrit.openafs.org/1907 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 98d20e250d9043c11e4644e574b5a60e9534a4f4 Author: Derrick Brashear Date: Tue May 4 11:39:19 2010 -0400 freebsd vcache splitting fallout fix the vcache splitting to work again Change-Id: I8833fc6655dcb79329835664d38f5330645b45f8 Reviewed-on: http://gerrit.openafs.org/1904 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1e69ec9cfef0bc571d1b91432354f486d49480b5 Author: tharidufernando Date: Sat Apr 10 09:01:16 2010 +0530 Windows: Secure C String usage in src\WINNT\afsd\fs.c The use of strlen, strcat, strcpy, strncpy and sprintf in src\WINNT\afsd\fs.c does not effectively protect against buffer overruns and string truncation errors. This patchset replaces their use with StringCbLen, StringCbCat, StringCbCopy, StringCbCopyN, StringCbCopyEx and StringCbPrintf respectively from strsafe.h. The functions sscanf, fscanf and scanf do not check for the size of the parameters so it is prone to buffer overruns. These functions can be replaced by sscanf_s, fscanf_s, scanf_s when the Visual Studio compiler version is 1400 or greater. Also memcpy will be replaced by memcpy_s which will check for the size of the destination buffer. In all cases, failure conditions are handled. Patchset development was mentored by Asanka Herath and Jeffrey Altman. Change-Id: I01e9dfc616641c220b57d2871e3e140406df3653 Reviewed-on: http://gerrit.openafs.org/1736 Tested-by: Jeffrey Altman Reviewed-by: Tharidu Fernando Tested-by: Tharidu Fernando Reviewed-by: Jeffrey Altman commit fb50f2478c0402eb3062208e173ebe33d00ac9c4 Author: Jonathan A. Kollasch Date: Sat Apr 10 10:55:17 2010 -0500 NetBSD 5.0 support. Change-Id: I5b9c5b8204ef729d9719f195ddbaf83c5f9cb4b5 Reviewed-on: http://gerrit.openafs.org/1738 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7084e5ff7df7ed5ad15f60bae262fc844248ae28 Author: Andrew Deason Date: Mon May 3 14:57:28 2010 -0500 Solaris: shutdown in freevfs, not unmount Call the afs shutdown sequence (afs_shutdown()) in the VFS_FREEVFS handler, instead of in the VFS_UNMOUNT handler. This way we shutdown when the last reference to our vfs goes away, instead of when we are unmounted. That doesn't make much of a difference right now, but doing so will be required for supporting forced unmounts. Change-Id: I4158865b139d05e2955e4809b93628df27b83922 Reviewed-on: http://gerrit.openafs.org/1899 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fc8ab5cfd6592f9a9df24706a8f5dcc1e41f2b33 Author: Andrew Deason Date: Thu Apr 29 17:47:15 2010 -0500 Solaris: prevent AFS umount while busy Return EBUSY from unmount if someone still references stuff in AFS. This prevents kernel panics that can occur on shutdown if we umount while there is a file in AFS open. Normally a process can hold a file in AFS open, AFS is unmounted, and the file is closed, triggering our code which explodes if called after we're unmounted. This adds VFS_HOLD/VFS_RELE calls whenever we 'create' a vcache, or retire an old one, to keep track if anyone has an open reference to us. Change-Id: I95d8cf7e7e4d32a05bee97e06832a530b40af217 Reviewed-on: http://gerrit.openafs.org/1880 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 34b7fd4a4989fe5d0484e00ae9582d2f29d98d9c Author: Andrew Deason Date: Thu Apr 29 16:00:26 2010 -0500 Solaris: return ENOTSUP for force-unmounts We don't support forced unmounts yet, so indicate as such. Change-Id: I3a130a4a8d31eeffd012352f656c2b4e42b46f27 Reviewed-on: http://gerrit.openafs.org/1879 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9be76c0d312e9d4ba879d2f82a7c556bf8025da7 Author: Simon Wilkinson Date: Sat Nov 7 00:16:28 2009 +0000 Refactor afs_NewVCache afs_NewVCache was a twisty turny maze of #ifdefs and duplicated code. This makes a number of sweeping changes to simplify this code, and to move platform specific elements out into their own directories. *) ShakeLooseVCaches is refactored so that the same code can be used both for platforms that support dynamic vcaches, and those which don't. *) afs_NewVCache, ShakeLooseVCaches, and afs_AllocVCache are all modified to remove platform specific code, and to call platform specific functions. *) A new platform file 'osi_vcache.c' is created to hold a number of platform specific vcache operations: *) osi_TryEvictVCache handles the decision of whether a vcache can be evicted or not, and does so if required *) osi_NewVnode allocates a new vnode *) osi_PrePopulateVCache does the necessary population of the vcache, before it's threaded onto the VLRUQ and associated hash tables. *) osi_AttachVnode handles attaching an OS vnode to our vcache, where that is necessary *) osi_PostPopulateVCache handles the vcache population that must occur after we're on the VLRUQ and have a vnode attached. Change-Id: I368e5fb500d012b44141aa8f8cf0516e63e58f57 Reviewed-on: http://gerrit.openafs.org/1881 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5e09bcd936f60a9b3f6547299ab2baf98111bba6 Author: Michael Meffie Date: Mon May 3 15:51:40 2010 -0400 pts mem -expandgroups and -supergroups examples Examples of the pts mem -expandgroups and -supergroups options for the man page. Change-Id: Idea0509797212397eff87aa5975eaf5364c8414c Reviewed-on: http://gerrit.openafs.org/1896 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5e24220c3d500c971e876e6805e3e46b91bad2e6 Author: Antoine Verheijen Date: Mon May 3 15:04:20 2010 -0600 OpenBSD: Fix bug in setpag() when group list is empty In OpenBSD, the PAG uses the 2nd and 3rd group slots in the task's group list. If an application sets en empty group list (such as Samba does), any existing PAG is lost and any new one is NOT set because the existing code will set the new group count to 2 instead of 3, and it leaves the first group entry as garbage (whatever random value the memory contained), thereby totally messing up the task's group list. This patch fixes it so that it behaves as expected. Change-Id: Ia718d55cbaad8ed372fba926dbfcb5db52ea684a Reviewed-on: http://gerrit.openafs.org/1898 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0ec2239b730bc9b1f8f819ef398d24bb7f1dff4e Author: Antoine Verheijen Date: Mon May 3 14:32:13 2010 -0600 Fix pattern to detect i386-based OpenBSD system type When the pattern to detect OpenBSD system types (via MKAFS_OSTYPE) was split into two separate ones for amd64 and i386 architectures, the pattern for i386-based systems was not set quite right. As a result, i386-based OpenBSD systems are no longer detected properly at this stage, resulting in an error of "cannot find input file: src/libafs/MakefileProto..in" during configure. This patch corrects the pattern. Change-Id: I67079af74117fa3cdc765f19944e23223709ae6b Reviewed-on: http://gerrit.openafs.org/1897 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 98d9d6cf83904d1422a96bb0646f560646d62114 Author: Asanka Herath Date: Tue Apr 20 15:06:41 2010 -0400 Windows: Show configuration pages for all types of MSI installations The OpenAFS MSI installer wizard used to not show any configuration pages for "Typical" and "Complete" installations. Setting the workstation cell and logon options during installation required selecting the "Custom" option. Many users choose the "Typical" option during installation, and thus would never see the configuration pages. Therefore, for these users, the workstation cell was being set to the default. This patch makes the workstation cell and logon option configuration pages visible to all types of installations (except silent installations which show no UI). Change-Id: Ie3bc040607a8d6b636c884bfcb919d0fc69b0e06 Reviewed-on: http://gerrit.openafs.org/1797 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 49c4200a9e313d775a90cc3b6c3b79b18e8e0367 Author: Tom Keiser Date: Thu Mar 11 10:38:31 2010 -0600 Provide a queue_NodeInit() interface Provide a queue_NodeInit() interface for the rx queue package. Change-Id: I85f6caf3605b9a88113ff4d904012ed2aa12a679 Reviewed-on: http://gerrit.openafs.org/1860 Reviewed-by: Tom Keiser Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cec1b09ff77f8009ceac73cf744584427df81397 Author: Jeffrey Altman Date: Sun May 2 15:30:27 2010 -0400 Windows: Restructure cm_LookupInternal addition of Freelance entries cm_LookupInternal creates Freelance mount points and symlinks when queries cannot be found in the Freelance root.afs directory. If the search name is a full cell name for which vldb information can be obtained, then a mount point is added. If the search name is a left-most substring or the full cell name with a dot appended to it, then a symlink was created. This approach created a very poluted Freelance name space. This patchset makes the following changes: 1. Do not create symlinks with a dot appended to the cellname 2. Do not create symlinks where the left-most substring is not a full dot separated component of the cellname. 3. Permit lookups to succeed when we would have created a symlink in the past without creating the symlink. LICENSE MIT Change-Id: I4573a2f13d4843878c3f5efc546df29a5023accc Reviewed-on: http://gerrit.openafs.org/1894 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 71f91cd93cb6e8c7430ddab7e5b9e0220070730e Author: Jeffrey Altman Date: Sun May 2 15:26:39 2010 -0400 Windows: Permit BPlus tree lookups within cm_ApplyDir BPlus tree lookups are much faster than searching through the native directory format on Windows because the case sensitive hash tables cannot be used successfully. Permit BPlus trees to be used except when called with cm_BPlusDirFoo as the action function because cm_BPlusDirFoo is used to build the BPlus trees from the native directory format. LICENSE MIT Change-Id: I3f6f5ba7113e206c76fafd1ec83822adc7f42f9e Reviewed-on: http://gerrit.openafs.org/1893 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit ebbd415f28dded52d92ed13f66d058707ef3d36f Author: Jeffrey Altman Date: Sun May 2 15:05:40 2010 -0400 Windows: Prevent cm_FreelanceAddSymlink from creating a symlink ending in a dot Symlinks are ending up in the Freelance root.afs directory that end with a dot. Make sure it cannot happen. LICENSE MIT Change-Id: I8a19c0cf6c2a68c22839e15641206f7e9db8b15b Reviewed-on: http://gerrit.openafs.org/1892 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit ec35612ce9072119eab2bb3fc6f76420ed8e9077 Author: Jeffrey Altman Date: Sun May 2 15:03:52 2010 -0400 Windows: normalize error codes from cm_FreelanceAddSymlink Return all error codes from the end of the function. LICENSE MIT Change-Id: I7703c90884820ed7eb1f43183d80c7df038cfb8b Reviewed-on: http://gerrit.openafs.org/1891 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit da2db6234221494956eca71ed3693c0a2bbf4a67 Author: Jeffrey Altman Date: Sun May 2 14:48:00 2010 -0400 Windows: Force rebuilding Freelance directory in AddMount and AddSymlink cm_FreelanceAddMount and cm_FreelanceAddSymlink is supposed to return the allocated FID of the entry that was added. However, cm_NameI is called to perform the lookup without forcing an update of the Freelance fake directory. As a result the entry may not be found. Force an update prior to calling cm_NameI() by using cm_clearLocalMountPointChange() and cm_reInitLocalMountPoints() if required. LICENSE MIT Change-Id: I08147b2ec61c810fdc718964362315af67d485b8 Reviewed-on: http://gerrit.openafs.org/1890 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit f8efae8c7072593ae519539790838055783affff Author: Jeffrey Altman Date: Sun May 2 14:17:43 2010 -0400 Windows: normalize return codes from cm_FreelanceAddMount Instead of returning an undefined CM error code, -1, which might end up being confused with an Rx error, return legal CM_ERROR_xxx values. LICENSE MIT Change-Id: Ie78e4e9cf00fa938806c8b355f54169a5691ff04 Reviewed-on: http://gerrit.openafs.org/1889 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 1ff924e7229451e4f789bb83a301d23d75761eaf Author: Jeffrey Altman Date: Sun May 2 14:03:23 2010 -0400 Windows: use cm_noteLocalMountPointChange whenever fakeDirVersion is changed cm_noteLocalMountPointChange() is meant to be used when fakeDirVersion is changed. It previously wasn't used because cm_noteLocalMountPointChange() would obtain the cm_Freelance_Lock. Now that cm_noteLocalMountPointChange() can be called while holding the lock, use it everywhere. LICENSE MIT Change-Id: I737f4572773a93a656ca0f58e07a55d250c368a1 Reviewed-on: http://gerrit.openafs.org/1888 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 3a48bf73d3087bf6d40f119b491d718e6b7e8284 Author: Jeffrey Altman Date: Sun May 2 13:56:24 2010 -0400 Windows: add locked parameter to cm_noteLocalMountPointChange If cm_Freelance_Lock is held set the 'locked' parameter to TRUE. This avoids a requirement to drop the lock only to have it be obtained when cm_noteLocalMountPointChange. LICENSE MIT Change-Id: Ic1e8a008639b33769a088c3b24ef7a7e7b09fb12 Reviewed-on: http://gerrit.openafs.org/1887 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit f2b98e27f8dd03ba45a3d88053458aa7bcd932bd Author: Jeffrey Altman Date: Sun May 2 13:21:12 2010 -0400 Windows: remove unused code from cm_FollowMountPoint The variable 'tlen' is set to the length of the mount point target string but is never used. Remove it. LICENSE MIT Change-Id: I1e53831eff90962c93720831a210faa019e38d67 Reviewed-on: http://gerrit.openafs.org/1886 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 4810026677d9527c8005184b2dd4bca610496657 Author: Jeffrey Altman Date: Sun May 2 13:11:14 2010 -0400 Windows: initialize to zero Freelance fake root directory The Freelance fake root directory buffers were not zero-filled. This results in random behavior that can cause the service to terminate unexpectedly. LICENSE MIT Change-Id: If4e42f74bf07a7296319f3a73f8c7628de4e1fd8 Reviewed-on: http://gerrit.openafs.org/1885 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 612bb07ae118f71f5ce6330c87425e175b2a8564 Author: Jeffrey Altman Date: Sun May 2 13:04:42 2010 -0400 Windows: make cm_BPlusDirFoo public Make cm_BPlusDirFoo so that the function pointer can be referenced from cm_ApplyDir. LICENSE MIT Change-Id: Ic58ce47dbcd9d6348666b1767941d861cd860df5 Reviewed-on: http://gerrit.openafs.org/1884 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 1b4b0b7576475daf540be15ef759e9a999671a1b Author: Jeffrey Altman Date: Sun May 2 09:21:48 2010 -0400 Windows: correct "fs quota" pioctl validation check The validation check for the response from the GetVolumeStatus pioctl is incorrect. The response is not simply a VolumeStatus structure but also several C strings appended to it. LICENSE MIT Change-Id: Ieb0c0cd166f85e073431890f51f735958776eb74 Reviewed-on: http://gerrit.openafs.org/1883 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 715670cbe968ee499a29f9477626962dd74c01dd Author: Jeffrey Altman Date: Sun May 2 09:16:29 2010 -0400 Windows: getAFSServer wrong variable used in uncompiled code In the uncompiled implementation of getAFSServer, the unmodified 'cellname' is used in the send_DNS_AFSDB_Query call instead of the properly constructed 'query' variable. LICENSE MIT Change-Id: I9de506a2986872ab88aeea158aa43133efc75d50 Reviewed-on: http://gerrit.openafs.org/1882 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 4f7bf8fb432ead9d0252e462cb627ab457c5b849 Author: Jeffrey Altman Date: Wed Apr 28 12:33:03 2010 -0400 Windows: FlushFile ioctl should call cm_FSync, not buf_CleanVnode When flushing a file, we need to commit the file length changes as well as the dirty buffers. Call cm_FSync instead of buf_CleanVnode which is called by cm_FSync. LICENSE MIT Change-Id: Id21e49e0559d20fce3e1d65cb73496a8b6cb1fa1 Reviewed-on: http://gerrit.openafs.org/1875 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 1844719127f9e1202f6e1823a64f12286d9a2e1c Author: Jeffrey Altman Date: Wed Apr 28 12:21:00 2010 -0400 Windows: add 'locked' flag to cm_FSync and call when dropping write locks cm_FSync should be called when releasing file server write locks. This ensures that all dirty buffers are stored before the lock can be acquired by another client. Since cm_Unlock holds the cm_scache_t->rw exclusively when calling cm_FSync, add a 'locked' parameter to cm_FSync to avoid an unnecessary release and reacquire of the rwlock. LICENSE MIT Change-Id: I70bbeffc24ec4238461281bab4006b3a57b275e2 Reviewed-on: http://gerrit.openafs.org/1876 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Asanka Herath Reviewed-by: Asanka Herath Reviewed-by: Jeffrey Altman commit a1cbbccce3cb615b43535721f8990f6019aa27ec Author: Marc Dionne Date: Wed Apr 28 19:07:32 2010 -0400 Warning fix: cpp hates apostrophes The compiler complains when the text in a #warning contains a single apostrophe: error: missing terminating ' character Change the text to avoid it. Change-Id: Ibf1f4d2cb922b313545ed228a2a8d4eb6b134178 Reviewed-on: http://gerrit.openafs.org/1877 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 94c15f62d3e82c4a4cf2ac7c4e247b4c5658eb2b Author: Matt Benjmain Date: Wed Apr 28 06:19:16 2010 -0400 netbsd: rebase cm at NetBSD 4.0 Rebases the NetBSD client port at OpenBSD, which was originally based on an original NetBSD client port by John Kohl. The platforms remain closely connected. At latest milestone, the port builds as a NetBSD LKM, which was loadable and can mount /afs (but much work remains past this point). Change-Id: I1381a60078794da03a82e7bf6e78127da82d61ee Change-Id: I8e07e82796f6981c99d22ff50dd5b284aad88a9f Reviewed-on: http://gerrit.openafs.org/1874 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 7f399f2caca1b614687b55393c8b8d7330fb4220 Author: Derrick Brashear Date: Wed Apr 28 02:02:05 2010 -0400 upstream dumpscan changes pull in code changes from upstream for dumpscan Change-Id: Ib1bcba7a420d19c1bf27b2a5405aaee786e6cbd6 Reviewed-on: http://gerrit.openafs.org/1873 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d02f9a0b0b95ac6ada6be0b2b9a1e164f75a425d Author: Simon Wilkinson Date: Wed Apr 28 01:13:30 2010 +0100 Linux: Register number sysctls only when desperate The AFS sysctl interface was trying to register numeric system calls whenever the kernel would let it. This is anti-social, as we've never had sysctl numbers allocated to us. In kernels newer than 2.6.24, this misbehaviour is detected and punished. In recent kernels, the binary interface has gone away entirely. Since 2.6.19, the kernel has supported allocated unnumbered system calls. These are only available via /proc/sys (and not the using the legacy, binary, API), but they're really the only interface available to us. Change the sysctl registration code to use unnumbered calls whenever they are available. Unnumbered calls aren't available in 2.4.x, so completely remove that code there. Change-Id: I882117ca2250894f479292026fed84ff0b5e7972 Reviewed-on: http://gerrit.openafs.org/1871 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b1c6d709cba64cda7bce0f5f91ab30a1e7bb8983 Author: Marc Dionne Date: Tue Apr 27 20:00:23 2010 -0400 Linux: specify void argument for afs_try_to_freeze inlines The new freeze inlines take no arguments, but need to be declared as taking (void) to prevent warnings that it is not a proper prototype. Change-Id: Ife675e69f566fabaee4bc41f2cc4fa9a20e816db Reviewed-on: http://gerrit.openafs.org/1870 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 009b547195eed40f7fa2fede24068c90e30c33e5 Author: Marc Dionne Date: Tue Apr 27 18:36:46 2010 -0400 Linux autoconf: fix name for struct cred test The new macro scheme changes the name of the tested define. Update the code to match. Change-Id: I0e9f04692d8fbb6e9452a9b169c191ce7148349b Reviewed-on: http://gerrit.openafs.org/1868 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d88b0b9a7b673cb828af6b68e5a9c48052b96a48 Author: Marc Dionne Date: Tue Apr 27 18:25:15 2010 -0400 Linux autoconf typo The test for the new export ops has a typo which makes the test fail where it should succeed: eops -> _eops Change-Id: I97dd0707b911c51f6394ada426a98e06a83ad35e Reviewed-on: http://gerrit.openafs.org/1867 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6c53cd7ad3980bd38b4d522a55d439e99608eb11 Author: Tom Keiser Date: Thu Mar 25 12:08:51 2010 -0500 Add some directory package doxygen comments Change-Id: I75c358f08c71b2de722de03bb65fb8696657d57f Reviewed-on: http://gerrit.openafs.org/1861 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b7a94ae11de37e22655073f55fe829427c38c832 Author: Simon Wilkinson Date: Tue Apr 27 22:16:24 2010 +0100 Linux: autoconf fallout grap != grab - fix spelling of grab_cache_page_write_begin Change-Id: I4032bff80b6d1d7568af8f9de59a56c0bd6a661a Reviewed-on: http://gerrit.openafs.org/1859 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c598e34fc36a5c5eb82b2b81f4caba66068d59b7 Author: Matt Benjmain Date: Tue Apr 27 12:06:48 2010 -0400 netbsd: remove old (non-original) NBSD port Prepare for rebase of NBSD port at the current OBSD port, which is descended directly from the original NBSD port and more closely resembles it. Change-Id: I9ff67ebea04534ac5ddc11c0aa1d65028067806a Reviewed-on: http://gerrit.openafs.org/1858 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 14195f0f48d52dd3a81c52c4a3bc2078857d0f86 Author: Marc Dionne Date: Sat Apr 24 22:12:27 2010 -0400 Linux: Remove unnecessary crhold on incomplete kernel credentials When credentials debugging is active in the kernel, sanity checks in various credentials functions such as get_cred or put_cred require that they are called with full fledged kernel credentials. This can be a problem with recent kernels in osi_Init where we build our own credentials and try to "crhold" them. Getting a reference doesn't make much sense anyway since we're using a statically allocated structure that we never try to free or modify. As a minimal fix, just don't call crhold when we're using the kernel credentials structure. Change-Id: If4f843ad33526c6a42f1cf67c57763593ffa50ac Reviewed-on: http://gerrit.openafs.org/1828 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 014821d281cac7815ac7908a853191b17bf2a868 Author: Derrick Brashear Date: Mon Apr 26 17:43:16 2010 -0400 flush changes on LOCK_EX unlock right now, flock with LOCK_EX, on unlock, triggers an async store. make it sync, but also, make sure to ask to have any in-memory data sent to us (e.g. VM_StoreAllSegments); unlike Solaris VMSYNC_INVAL, we don't want to invalidate the pages, just get copies written back. LOCK_SH did not, does not and AFAICT should not trigger writes. Change-Id: Id4a72f73b685b5566bb31f6f610f22d806899280 Reviewed-on: http://gerrit.openafs.org/1846 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fa70575af3dd5b8e1467dd516413b6d153a9963a Author: Derrick Brashear Date: Mon Apr 26 16:41:29 2010 -0400 allow file length to be updated unless we're writing right now, merely having the file open O_RDWR, or mapped, precludes a length update from being reflected. Change-Id: I7f732b053c392aa6cc1c8ad6de8e0f4bd6468728 Reviewed-on: http://gerrit.openafs.org/1841 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0c7cb6051fdc930d03df53b294fcbe5eaa6bbaff Author: Simon Wilkinson Date: Tue Apr 27 19:31:55 2010 +0100 Linux: Reorder the tests As a final change to the Linux autoconf stuff, reorder the list of tests so that it's more easy to see what's being checked for, and to prevent multiple copies of the same thing being added. Change-Id: I84ca132e178b45ac25ebd48e71193bdd84965770 Reviewed-on: http://gerrit.openafs.org/1857 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2ce28370cf2d3a16d84664463731b1148447edb0 Author: Simon Wilkinson Date: Tue Apr 27 18:57:30 2010 +0100 Linux: Don't preprocess osi_vfs.h Before we did inodes properly, we needed to pre-process osi_vfs.h, in order to merge our inode structure with the Linux one. Ever since we moved to native inodes, that preprocessing has been disabled, and we've just copied osi_vfs.hin to osf_vfs.h Skip this pointless step, permanently rename osi_vfs.hin to osi_vfs.h, and remove the unused support scripts. Change-Id: I5e21eccf2242080cd8b994bd1654260bfb531420 Reviewed-on: http://gerrit.openafs.org/1856 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a8cc8dbbe53a4764dcd355cf1080f497cb8f5d2e Author: Simon Wilkinson Date: Tue Apr 27 17:49:19 2010 +0100 Linux: Don't waste autoconf checks on cpp defines If something is a #define, then there's no point in doing a test compile to check for its presence. Instead, just do #if defined(X) Remove the tests for for_each_process and prev_task. Change-Id: Id8a9fddf2571cccd5d61982d4662bce2009c8f43 Reviewed-on: http://gerrit.openafs.org/1855 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a89d6b029d059d01b8bbfc18b9ee6e3f5a964b85 Author: Simon Wilkinson Date: Tue Apr 27 17:41:22 2010 +0100 Linux: Add general autoconf macro for Linux kernel Add AC_CHECK_LINUX_BUILD() to do a standardised Linux build, which takes a "checking" message, the autoconf variable to use to cache the results, headers and code to run, preprocessor variable to define, and a description of that variable. Reimplement all of our existing check macros in terms of this one, resolving many typos along the way. Change-Id: I41988c83fcdbfbf8152f6dd0e7c4bd16c7a04240 Reviewed-on: http://gerrit.openafs.org/1854 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 02f2c7cb3734d44dc90b77d631909373daefacd3 Author: Simon Wilkinson Date: Tue Apr 27 13:02:20 2010 +0100 Linux: Add autoconf macro for structure checks Add a new autoconf macro for doing structure element checks, and modify all simple structure checks to use it. This introduces a standard name form - STRUCT_structure_HAS_element, so there are some changes in the code to make use of this standard form. Change-Id: Ife967322503ae6f428e76845000de04f26929e65 Reviewed-on: http://gerrit.openafs.org/1853 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6fc3ac36701cd64736b784e99184c504fa4226f4 Author: Simon Wilkinson Date: Mon Apr 26 23:54:05 2010 +0100 Linux: Macroise kernel function autoconf tests We spend a lot of time in autoconf checking to see if kernel functions are available. Rather than copying and pasting the same code everytime we do so, create a macro to do function tests, and use that macro. This results in standardised naming, so change all of the places that use autoconf results to use the same standardised names. Change-Id: I36212e6c28c4b8455f859da1bbf3e456a2aabc07 Reviewed-on: http://gerrit.openafs.org/1849 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit eef18466d920985c37ed8d22a6557b609c6225a6 Author: Simon Wilkinson Date: Mon Apr 26 22:13:39 2010 +0100 Linux: Tidy up freezer code Linux now provides try_to_freeze(), which can be used to replace all of our refrigerator code. This has been in the tree for a long time, and actually predates many of the changes we've been modifying our code to work with. So, use try_to_freeze wherever we can, and keep a simpler compatibility function for kernels which are too old to have it. Change-Id: Iec50f83382f46d2b17b43da815a75755ea916bc6 Reviewed-on: http://gerrit.openafs.org/1845 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ef8bd5a29b937a1211540aa60398ee966470a712 Author: Simon Wilkinson Date: Mon Apr 26 21:34:17 2010 +0100 Linux: Simplify header file checks Provide an autoconf macro to perform tests for the existence of Linux kernel header files. Use this to standardise the naming of header file presence #defines, and to simplify the linux tests. Change-Id: I49629679db56c5f9a39487bd78fc2e59d5da0269 Reviewed-on: http://gerrit.openafs.org/1844 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a0259edcac06554688145302468e7696713744aa Author: Matt Benjamin Date: Tue Apr 27 13:03:36 2010 -0400 Rename afs_nbsd_* functions in OBSD The OBSD cm port prefixes function names with afs_nbsd_, an artifact of its origin in the original NBSD cm port. Make the prefix afs_obsd_. Change-Id: Id412fe0f752a147e2a9afda904db220ea6efd736 Reviewed-on: http://gerrit.openafs.org/1850 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f5036d6314d4161ab57f7f6bcc074e535289c1eb Author: Simon Wilkinson Date: Mon Apr 26 23:36:38 2010 +0100 Overzealous .gitignore under rxkad The .gitignore in rxkad ignores sboxes.h and fcrypt.h, since they used to get copied there from the domestic subdir. Now that they actually live under rxkad, they souldn't be ignored. (with thanks to Marc for the commit message) Change-Id: I1dd6766e75c15ca7f5604601bbe5b4e67f4fffa6 Reviewed-on: http://gerrit.openafs.org/1848 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c761f3ddde786e4ced1022ec5570d4cb2ce15169 Author: Marc Dionne Date: Mon Apr 26 18:15:16 2010 -0400 Overzealous clean target under rxkad The clean target under rxkad removes sboxes.h and fcrypt.h, since they used to get copied there from the domestic subdir. Now that they actually live under rxkad, they souldn't be removed. Change-Id: I867496dd0d3dd997d402ebfbfc6272447b1af98e Reviewed-on: http://gerrit.openafs.org/1847 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4768ed68d0831d208f4ebeead06e0b4e422f728e Author: Derrick Brashear Date: Mon Apr 26 15:55:57 2010 -0400 dcache dirty pages flag is solaris only note that IFDirtyPages is Solaris-only, so there's no confusion. may be worth visiting to see if and how the code should be minimized or adapted for elsewhere Change-Id: I7dfe4760eb4038d23a920c2e23f33d93e604bbca Reviewed-on: http://gerrit.openafs.org/1840 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 90c970d3b60bb28a21b2861b75469281b5c464a5 Author: Simon Wilkinson Date: Fri Apr 23 17:07:40 2010 +0100 Linux: Don't hide memory management Given that we now only switch from user space into kernel space in one place, don't hide the mechanism we use to do so behind macros. This makes it much easier to visually confirm the correctness of the code. Change-Id: Ie52e071c81a9178c792be1eaa7e36d8453ebb319 Reviewed-on: http://gerrit.openafs.org/1820 Reviewed-by: Simon Wilkinson Reviewed-by: Dan Hyde Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ad306046291c5c67178251d349f1250fef895ae2 Author: Simon Wilkinson Date: Fri Apr 23 17:10:15 2010 +0100 Linux: The kernel module always runs in the kernel There's no situation where we'd be including osi_machdep.h and not be building for the kernel, so just remove the case that disables all of the locks if __KERNEL__ isn't defined. Change-Id: I1141c37cf0cd517191dee7ca2404e109d4053c29 Reviewed-on: http://gerrit.openafs.org/1821 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 51c1eb362da866e28a9fb9a6f5d9d412aac7e8c2 Author: Derrick Brashear Date: Mon Apr 26 00:21:30 2010 -0400 fix other oldtvix typo i failed to push this to commit 0dac8f93af5262472bc5bdf94dbb605a24da59d0, and so, well, here's the real fix. sorry. Change-Id: I6799ecb207f246ac3e4c48b1de55268d2fba4d23 Reviewed-on: http://gerrit.openafs.org/1837 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0dac8f93af5262472bc5bdf94dbb605a24da59d0 Author: Marc Dionne Date: Thu Apr 22 17:22:37 2010 -0400 Initialize oldvtix Initialize the variable to avoid compiler complaints that it could be used uninitialized. Use a sentinel value and issue a warning if we try to use the variable and we haven't set it to a useful value. Change-Id: I037be2ad8e0b55d06b50aafdeca5012764640f16 Reviewed-on: http://gerrit.openafs.org/1810 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1798fe6da1d40c083bc10fe101a73b5f67b6fa0d Author: Simon Wilkinson Date: Fri Apr 23 18:03:49 2010 +0100 Linux: Use kernel network helper functions Linux has various network helper functions available, which are guaranteed to do the right thing in terms of setting address space limits, not dereferencing NULL pointers, and the like. Use these, where they're available, rather than rolling our own. kernel_sendmsg and kernel_recvmsg appeared in 2.6.8. Change-Id: I1cd91afd2182ad936756bbc4cf692262499c16e4 Reviewed-on: http://gerrit.openafs.org/1822 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 06f8a6232b7ad56a82dc94384dc950411107f48a Author: Simon Wilkinson Date: Fri Apr 23 18:38:02 2010 +0100 Linux: Remove old code from RX kernel implementation The RX implementation was split into LINUX and LINUX24 along with the kernel, but the old 2.4 and 2.2 only code was never removed from the LINUX/ directory. Do so now. Change-Id: I80300a1390e297298f4af3c06086e25d0acf8c1a Reviewed-on: http://gerrit.openafs.org/1819 Reviewed-by: Derrick Brashear Reviewed-by: Marc Dionne Tested-by: Derrick Brashear commit d6d82659d0b68aad201916b6323591ff497486f8 Author: Simon Wilkinson Date: Fri Apr 23 16:54:39 2010 +0100 Linux: Don't pass f_pos down to the filesystem In 2.6.8, Linux shifted from passing f_pos directly to the read and write routines, and started passing a copy. This helps reduce, but does not remove, the race issues with f_pos itself. Make this change for us. Take the opportunity to remove the uneccessary macros, and tidy up some casting. Change-Id: I3b4cdf1e6e8127cbe0055829605268953c4397a6 Reviewed-on: http://gerrit.openafs.org/1818 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bd95ded9cfd95c4498896cbbadff6af3b752c43d Author: Simon Wilkinson Date: Fri Apr 23 15:59:46 2010 +0100 Linux: Removed unused define VFS_STATFS isn't used in the Linux 2.6 case, and is wrong anyway. Remove it in an attempt to clarify some particularly muddy water. Change-Id: I404429e3eeb87146bfdced5625b56857ba2ab9fd Reviewed-on: http://gerrit.openafs.org/1817 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 20d08fb0ec7190bac622e9ac8a17f97b7feef1cb Author: Simon Wilkinson Date: Fri Apr 23 15:07:58 2010 +0100 Linux: Don't roll our own llseek llseek is a little more complex than just setting the pos field of the file structure. Where vfs_llseek is available to us (it has been since 2.6.8) use that directly. If vfs_llseek isn't available, then use either the filesystem's llseek method, or default_llseek (available since 2.6.0), to ensure we get the proper locking. Change-Id: I26bcbff984c7164be1724eee7a46cbe6e02bc510 Reviewed-on: http://gerrit.openafs.org/1816 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5afa2965b2c4eab2a32dbd4ff036a835eb903e75 Author: Derrick Brashear Date: Sat Apr 24 17:05:47 2010 -0400 cachemgr store file too big error exit via usual path have just one path for exiting on errors so we do everything this means we will EndCall, instead of not, in the EFBIG case Change-Id: I2df025eee4bd5173ed4f80a73f9a9a347e7257d2 Reviewed-on: http://gerrit.openafs.org/1827 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fbbfb51e7d997a40bf7d57150f69bfb055831a07 Author: Simon Wilkinson Date: Sun Apr 25 22:07:04 2010 +0100 Move rxkad/domestic/* into rxkad/ directory proper Historically, the fcrypt code lived in its own directory, named 'domestic', so that ACLs could be used to prevent nasty foreigners from getting access to it. Now that those days are gone, having the domestic directory just complicates builds. Remove it, and reunite fcrypt with the rest of the tree. Change-Id: I2d1f66463121bbb391260b613913d76c27931429 Reviewed-on: http://gerrit.openafs.org/1836 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 37d2e8bfa8aa83ed592bd25cd3c7fd58f178de9a Author: Simon Wilkinson Date: Sun Apr 25 19:11:06 2010 +0100 Improve shared library building support This change removes the need to maintain two forms of symbol export lists, instead generating the simpler lists required by AIX and Mac OS X from the more complex Linux and Solaris mapfile. It can only handle simple mapfiles at present, any more complex files (for example, those which contain versioning information) will require changes to the translation script. The now unused .exp files are removed, and a dependency on the .map file added to the library build line. This change adds support for export lists to Darwin for the first time. Doing so identified a number of symbols in libafsrpc that are required by libafsauthent, which were not being exported. Export these symbols, and bump the minor revision of the shared library. Change-Id: Ibd1d02bb89b85500dc2a010e6cde1f4b81efe050 Reviewed-on: http://gerrit.openafs.org/1831 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0d7197f92517446be422150e32e0e07118a88271 Author: Simon Wilkinson Date: Sun Apr 25 11:31:36 2010 +0100 Linux: Remove prototype warning inhibition The Linux kernel builds used to add -Wno-strict-prototypes to the CFLAGS. Now that we've got prototypes for pretty much everything, remove this line so we can see any real warnings that might occur. Change-Id: I71b97bd3d19259f6ec6a55cfe095f5f4bf1ab78f Reviewed-on: http://gerrit.openafs.org/1830 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 36ea3e1ffe3fb7fc625cdb9cdca2d98ce8297a2b Author: Simon Wilkinson Date: Sun Apr 25 10:55:23 2010 +0100 Fix make clean and make distclean Fix these make targets so they actually clean the tree. Reorder the list of file deletions in distclean so that it exactly mirrors the creation order in configure.in, which should hopefully make it easier to keep this all in sync in future. Add all of the missing files in packaging, and the shared library build tools, to this list. Make kauth and vol clean remove ka-forwarder and fssync-debug, respectively. Change-Id: Iae13419f1cb21058882c0b0e0c283e3c947e33c9 Reviewed-on: http://gerrit.openafs.org/1829 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1a0912ffc2e4ec76a599e8d817c8e084799e464d Author: Simon Wilkinson Date: Sun Apr 25 21:52:20 2010 +0100 Really kill des_stub Some bits of des_stub were lingering on. Get rid of it completely. Change-Id: I853135621a757c78cdb50117500f056ade0e6ab5 Reviewed-on: http://gerrit.openafs.org/1835 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d77c69504bed925ab420c5bac84d7ef23aff4417 Author: Simon Wilkinson Date: Sat Apr 24 17:34:02 2010 +0100 Fix objdir builds Change f2db78a346112f5320efc6f0b6b9fe4ae0d893d3 included hard references to compilation sources with no srcdir prefix, and so broke objdir builds. Fix this so that we can build outside the source tree again. Change-Id: Iaae2d4a1047cc2ac0f5f4aae92cadc1f2a0d09e2 Reviewed-on: http://gerrit.openafs.org/1826 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bf53b0882b7ef3d6e25500e968d007f464be5c04 Author: Derrick Brashear Date: Fri Apr 23 14:40:45 2010 -0400 macos growl agent warning parser fix warnings start at offset 5, not 6 (warn is shorter than fetch or store) Change-Id: Ibaa1239b0f9797da149cb05b3f871611b13833c8 Reviewed-on: http://gerrit.openafs.org/1825 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8b0164cd9ef7fd9db8acb0f53c1e4efb00d931af Author: Derrick Brashear Date: Fri Apr 23 11:56:08 2010 -0400 openafs 1.5.74.1 so it can be tagged and non-unversioned builds of the mac client changes can be seeded for testing Change-Id: Ibaa231d356bf667b13e271c9868c6ce0182bd2a6 Reviewed-on: http://gerrit.openafs.org/1814 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f5086e38922b88ec753d4ca632d89cc51913819e Author: Derrick Brashear Date: Fri Apr 23 11:02:32 2010 -0400 macos launchd be more patient right now we would wait 20 seconds for shutdown (the default), get impatient and be useless. be less useless. Change-Id: I8c6bc9b7546352cfa73d461b7cdddd2b5b5d7889 Reviewed-on: http://gerrit.openafs.org/1813 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d4e66ef219c88cdb17f2e860027cf6752ea21b17 Author: Simon Wilkinson Date: Thu Apr 22 22:24:11 2010 +0100 Unix: Modify disk cache versioning This change increments the disk cache version number, and adds a structure size record to the disk cache header. All old disk caches will be replaced when the client is started. With the various changes made to unify our file handles, and to support large file handles on Linux, the size of the 'fcache' structure was modified earlier in the 1.5 series. However, fcache is also the building block of the CacheItems file, so these changes inadvertently broke users upgrading from 1.4. In addition, as the disk cache inode is now a union of many different structures, the structure size is now potentially volatile across both kernel, and OpenAFS revisions. Up the version number so old disk caches are invalidated and won't crash users who are upgrading. Also take the opportunity to add an item to the header which stores the size of struct fcache used by the disk cache. If the size on disk doesn't match that expected by the kernel module, truncate the cache and start again. Change-Id: I2ee8863d0bfaaaba34272c9e139638e17669a53e Reviewed-on: http://gerrit.openafs.org/1811 Reviewed-by: Andrew Deason Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cfc9b34856c6649a44e9fe762f9b0c0f09d7c653 Author: Marc Dionne Date: Thu Apr 22 19:39:21 2010 -0400 Warning fix: cast to expected type Cast argument to match the expected type from the format string. Change-Id: Iddec912ff8a27f46d872fc3101677913adfb537a Reviewed-on: http://gerrit.openafs.org/1812 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 30f2dded7340a776f2d41a17cee944ef83665648 Author: Andrew Deason Date: Thu Apr 22 11:54:06 2010 -0500 Update nextVnodeUnique before checking inUse When attaching a volume, update the nextVnodeUnique field for the volume, before we do any checks on the volume; for example, checking inUse, which may result in a demand-salvage if we are running DAFS. If we do not do this, we can schedule a demand-salvage without setting nextVnodeUnique, and VUpdateVolume_r will update the volume header uniquifier to nextVnodeUnique+200, when nextVnodeUnique is not set. So, we will always set the uniquifier to 200. Fortunately, the salvage should usually fix the uniquifer anyway. So, set nextVnodeUnique before doing any of those checks, to avoid screwing up the uniquifier when taking the volume offline. Change-Id: Ib211bbf5e93efbebcb679259944e7abf211aa6e1 Reviewed-on: http://gerrit.openafs.org/1809 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 3a0e2a725306504302d5efd254a027d865860093 Author: Andrew Deason Date: Thu Apr 22 13:21:52 2010 -0500 Prefer EndCall errors in StoreMini Partially revert b1eb6a7a3f80500f0187cc6a1dd2013e1a5e154a, so we do not mask the rx_EndCall error with a EndRXAFS_StoreData error (for example, if EndRXAFS_StoreData returns RXGEN_CC_UNMARSHAL, and rx_EndCall returns VBUSY). We need to agree on how to do this throughout the tree, but for now, just fix StoreMini. Change-Id: I4913946089fd0857506d9186f85c5c8115a5b95d Reviewed-on: http://gerrit.openafs.org/1808 Tested-by: Andrew Deason Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 77468e3a0820d32cc8a1b2b6c4601ba83803f727 Author: Simon Wilkinson Date: Thu Apr 22 18:02:08 2010 +0100 Linux: Tidy up packaging Remove the fuzz setting - we're no longer patching the build, so we don't need it. Change-Id: Ic56b4d9efed40aedb425d9852018907736ef957f Reviewed-on: http://gerrit.openafs.org/1807 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0d0e7699c9f789214205fe6837cded1a4c95f9c0 Author: Simon Wilkinson Date: Thu Apr 22 17:56:25 2010 +0100 Linux: RedHat packaging updates for RHEL6 Update our bundled spec file and related tools so they can be used to build OpenAFS on the RHEL6 beta. - Make kmodtool recognise el6 as having "modern" kernel naming conventions - Replace %{PACKAGE_VERSION} (which seems to have disappeared) with the standard %{version} macro Thanks to billings and phalenor on IRC for their testing efforts. Change-Id: I6538af56f365952b98c2dcbafb1c043435449e63 Reviewed-on: http://gerrit.openafs.org/1806 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 219276bab080640d0f024eba344073bdffaf6c1f Author: Andrew Deason Date: Thu Apr 22 09:59:30 2010 -0500 Resolve symlinks for 'fs rmmount' 'fs rmmount' is the only 'fs' command that does not resolve symlinks for its pioctls for some reason. Make it resolve symlinks. Thanks to Arne Wiebalck. Change-Id: Ifb6bdf0b381abd2e157d93d7eea4d853e1b3a689 Reviewed-on: http://gerrit.openafs.org/1805 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7d9e6dbbf1c81d31645957906c9b3b0caa803ca7 Author: Derrick Brashear Date: Wed Feb 17 00:48:03 2010 -0500 byte-range lock warning should include pid is is the same pid cmdebug would print. just include it in the logged byte-range lock warning. FIXES 126438 Change-Id: Idd83a4c4a56edf43ab257b3a7f08e1bbb774f04a Reviewed-on: http://gerrit.openafs.org/1333 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2a8c554a4553c32359cecf268fd12029c9d6d85d Author: sanket Date: Sat Apr 17 19:44:25 2010 +0530 Adding osi_procname macro to different platforms osi_procname(procname, size) is added to different platforms to obtain the processname in the string procname( preallocated ) with size size Change-Id: Iab8fed3e99839cee7c07a2de6144af9b09af3a57 Change-Id: Ib4e45564ae942e74c331444969a462427f5e7cf3 Reviewed-on: http://gerrit.openafs.org/1771 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3239cb830082ed995391bdda86d61daba9bed1a1 Author: Derrick Brashear Date: Wed Apr 21 18:45:33 2010 -0400 macos bulkstat again revamp this to avoid various issues with vnode references, and to avoid potentially finding CVInit vcaches but not reclaiming Change-Id: I6cb8d73b66c449a104799082259c97ede7e32e9b Reviewed-on: http://gerrit.openafs.org/1802 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 54226e9ad45003f4f54b1a7ba2b13003dcf1edb7 Author: Russ Allbery Date: Mon Apr 19 22:01:27 2010 -0700 Fix UCONTEXT detection on ppc_linux26 via include order param.linux26.h defines USE_UCONTEXT for all Linux platforms for glibc 2.4 and higher, but it does this by testing __GLIBC__ and __GLIBC_MINOR__. These are defined by features.h, which is included by any system header. At least one system header must be included before those are defined. lwp/process.c was including and before any other headers, leading to those macros being undefined. Most of the Linux architectures either have their own implementation or were explicitly defining USE_UCONTEXT in the per-architecture param file, but ppc_linux26 was relying on the default. Fix this by reordering the includes to include the various system headers before and add a comment explaining why. This previously worked in earlier versions because the old param.ppc_linux26.h file included , which included "stds.h", which included a system header prior to the check for ucontext. The new generic param file reverses that order. Change-Id: I214e54f684afdef07e6e2dec5b6e6e4d255ab4ec Reviewed-on: http://gerrit.openafs.org/1791 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 80f05473428969ff71d1791cda8cb09d30223724 Author: Andrew Deason Date: Wed Apr 21 12:41:21 2010 -0500 Recover from afs_GetVolSlot errors afs_GetVolSlot can panic in a few different ways, such as failing to read from or write to VolumeInfo. Instead of panic'ing, return an error to the application. Adjust callers to deal with getting a NULL volume returned. Based on a patch by Mike Meffie. Change-Id: Ibb301fed795ee9ee5906b8e7973945a06218b8f1 Reviewed-on: http://gerrit.openafs.org/1801 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6bde63c46502ef8a70f4e9ceefbff7404c6d0ef8 Author: Russ Allbery Date: Tue Apr 20 20:46:32 2010 -0700 Add RFC 5864 to the protocol documentation directory Add a copy of RFC 5864 (DNS SRV Resource Records for AFS) to the protocol documentation directory for reference. As permitted by the IETF Trust License Policy section 3(e), I release this document under the MIT/X Consortium license included in this copy of the document. LICENSE MIT Change-Id: I8e22aac07b4cedbe18b8375213a7866cf98a1386 Reviewed-on: http://gerrit.openafs.org/1799 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e8d6d9dfd7c49fc1017d0b7f370e0ba3f3baedb8 Author: Russ Allbery Date: Mon Apr 19 21:18:57 2010 -0700 Install afsd.fuse and man page if built If --enable-fuse-client is passed to configure and afsd.fuse is built, install it into the same directory as afsd and install afsd.fuse.8 as a symlink to the afsd.8 man page. Add documentation of afsd.fuse to the afsd man page. Change-Id: I7d0cd3992a8466e626af2191c713e5623cc40d84 Reviewed-on: http://gerrit.openafs.org/1792 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f3fc021808f73ae770ac1ee25e90df632201b217 Author: Anders Kaseorg Date: Wed Apr 21 04:09:03 2010 -0400 Add src/afsd/afsd.fuse and src/libuafs/afsd to .gitignore Change-Id: I4b7e5261d92944ed871a1113b0f4a651357f9fcf Signed-off-by: Anders Kaseorg Reviewed-on: http://gerrit.openafs.org/1800 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7321493788411419cd4c2817b97cfcd8227b849c Author: Andrew Deason Date: Sun Apr 18 18:49:18 2010 -0500 Add documentation for fs callback xstats Change I572ff682de4cc7ef27bb46dd028d3d797b873841 added the fileserver callback xstats collection to afsmonitor. Provide some documentation for these fields, along with the other fields displayed by afsmonitor. Change-Id: I21618047519fbb28f6707ff9ba95a17fe27e0f3c Reviewed-on: http://gerrit.openafs.org/1783 Tested-by: Andrew Deason Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear commit 0428e5fd9523148b4c9ab59701a19ad521549662 Author: Derrick Brashear Date: Tue Apr 20 19:59:53 2010 -0400 kauth admin tools ubik prototyping kill off ubik_Call (but not CallIter, yet) Change-Id: I7af515b4e1c55c493c304a8ffd5c74cb96cd3b97 Reviewed-on: http://gerrit.openafs.org/1793 Tested-by: Derrick Brashear Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 1662aa04d70631fd77eaeef8899f0056ce6773f8 Author: Jonathan Billings Date: Tue Apr 20 15:53:21 2010 -0400 Updated dkms.conf to remove MPS=$SMP from make * Removed the logic to set $SMP based on CONFIG_SMP from /boot/config-$kernelver * When using --with-linux-kernel-packaging in the configure line, dkms no longer needs MPS=$SMP in the make line. Change-Id: Ib65782050cae9f439ad5fed5c7bbbc403e556b4f Reviewed-on: http://gerrit.openafs.org/1798 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9ab56bb0c8c95de188b1120221ca2ad1b6fdddb9 Author: Jonathan Billings Date: Tue Apr 20 12:13:11 2010 -0400 Added explanatory comments for restorevol move Since restorevol is placed in %{_prefix}/afs/bin by make dest, we need to fix it so it ends up in %{_bindir} to be used in the base package. Change-Id: I31f2602868230416525a84a9d716230f08cb34ab Reviewed-on: http://gerrit.openafs.org/1796 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 8cca2e64ef6005d2ee050fee5641b16ae43117a9 Author: Jonathan Billings Date: Tue Apr 20 12:00:21 2010 -0400 Fixed more locations to reflect recent changes Moved restorevol man page to base package Moved state_analyzer man page to server package Change-Id: I714dd6eca86def48fefc0206c93038ae71415cc9 Reviewed-on: http://gerrit.openafs.org/1795 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 8f952a3ebda3567630c94d60877c5c926df98d08 Author: Jonathan Billings Date: Tue Apr 20 11:50:59 2010 -0400 Fixed RedHat SPEC file to reflect updates in code Moved the restorevol binary from /usr/afs/bin to /usr/bin Added the new state_analyzer.8.gz man page Change-Id: Ibf4133034b1945d58843162cb45bdd485e8c34a1 Reviewed-on: http://gerrit.openafs.org/1794 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit d80382efc5b0e3c8d32688a94c7ff7c68882cb59 Author: Russ Allbery Date: Mon Apr 19 21:36:09 2010 -0700 Remove special-case call sequence for KAM_SetPassword on s390 For Linux s390 (but not s390x), an additional argument was passed to KAM_SetPassword between the kvno and the encryption key. This doesn't seem to match the rest of the code and is now, with stricter prototyping, preventing the code from compiling. Remove it and use the same call sequence on s390 as everywhere else. Change-Id: I750f64212e80d4bed4500e316ad7d354608866d7 Reviewed-on: http://gerrit.openafs.org/1790 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 63b6bb1ee7d52ba11c817fbfbbda5704d21669dc Author: Andrew Deason Date: Mon Apr 19 14:48:14 2010 -0500 Use AC_PREREQ We use AC_USE_SYSTEM_EXTENSIONS, which was introduced in autoconf 2.60. To allow for less confusion and perhaps a more clear error message, specify that we require using at least that version. Change-Id: I42a3f4e889ad443d8d8cd3ba0c085c67606b8be3 Reviewed-on: http://gerrit.openafs.org/1784 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit e6f6c3493e4c6d0ea620f34bd764925f9d004a2c Author: Russ Allbery Date: Mon Apr 19 14:00:31 2010 -0700 Fixes and clarifications to vos setaddrs man page Add a caution explaining how the file server addresses are registered and pointing users at NetInfo and NetRestrict plus restarting the file server for the normal case. Mention what version of OpenAFS introduced this command. Drop the note about the version of OpenAFS that added the -encrypt flag, since the whole command is newer than that. Reference vos listaddrs -printuuid specifically to get the UUID. General formatting and wording cleanup: use terminology more consistently, continue a long example line, wrap long lines, fix a spelling error, and add cross-references to NetInfo and NetRestrict. Change-Id: Idd6175339dc0feb1b777963bbb09731e42b83522 Reviewed-on: http://gerrit.openafs.org/1787 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1a29506a2c387b1046b2e9e8966af693567099a5 Author: Russ Allbery Date: Mon Apr 19 14:55:16 2010 -0700 Update Debian packaging for 1.5.74 Include the Debian changelog entry for 1.5.74-1 and install the new vos setaddrs man page. Change-Id: I4cc9e0590cb47d0ae885d7116f5bafd469f43cae Reviewed-on: http://gerrit.openafs.org/1788 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fe48d1777f88dc5ec8e56b2e68a2a491fe3edb45 Author: Derrick Brashear Date: Mon Apr 19 14:02:14 2010 -0400 macos disable bulkstat there's still a bug Change-Id: I23e02f9a05e001f0082b757c4a1dd78186fe6977 Reviewed-on: http://gerrit.openafs.org/1782 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5df92c083eb96b5b1496124715998ab9bfe9ef69 Author: Derrick Brashear Date: Sun Apr 18 13:45:51 2010 -0400 macos bulkstat don't double reget refs if another code path already got back the refs from finalizevnode, don't do it again Change-Id: I7e06ceeb2c7e71b1be94fd0fccb6e28c37457b24 Reviewed-on: http://gerrit.openafs.org/1776 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b64a0af473aea79dd7a198210e0283016433546e Author: Derrick Brashear Date: Sun Apr 18 13:35:09 2010 -0400 bulkstat restore bulkfetching state for reused vcaches when i introduced NewBulkVCache I elided this case. Set it here. Change-Id: Id88425b0ee662ecc23dd43cf7fa253ab61b02945 Reviewed-on: http://gerrit.openafs.org/1775 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6c49c21f9734d01ba6bf00f3a8e41460ff377868 Author: Jeffrey Altman Date: Sun Apr 18 18:34:18 2010 +0100 Windows: Preserve volume location info in case of comm fail The cache manager refreshes volume location information every two hours. If during a refresh the communication with the vldb server fails, the previously known volume location information should continue to be used. The previous behavior in which the volume location information is discarded first and then the update is performed can result in unnecessary client failures when a temporary disruption in communication with the vldb server occurs. Instead, wait until we have a successful response from the vldb server before the previous server list is discarded. LICENSE MIT Change-Id: I7c63c4f673a7a1360a74611c356329f31f9ceec3 Reviewed-on: http://gerrit.openafs.org/1769 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 91bef849e58ff45fbcac3107fbc7c19d2bc88b7e Author: Jeffrey Altman Date: Sun Apr 18 18:20:52 2010 +0100 Windows: correct locking in cm_FreeServerList The cm_serverLock must be held when checking the state of the list head. LICENSE MIT Change-Id: I1134a6617d4c1e38b95512b1fdc41c5f5857ea7a Reviewed-on: http://gerrit.openafs.org/1774 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 2beda68d4ad84e3e853a320bfb9d610b33f77902 Author: Jeffrey Altman Date: Sun Apr 18 12:38:27 2010 +0100 Windows: prevent infinite idle error response The idle error value (if any) is stored in the cm_req_t object. Since the value is never cleared, the same value can be returned for all requests that make use of the same cm_req_t object. Change the behavior to only return an idle error once and then clear it. LICENSE MIT Change-Id: Iac9ff8e56e856c2f0e440a34ac39ccd68de37c77 Reviewed-on: http://gerrit.openafs.org/1773 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 1239acfb44d13d92b38b8b0c95ec5c480a4e2253 Author: Jeffrey Altman Date: Sat Apr 17 15:21:32 2010 -0400 Windows: Increase the memory map version Since the cm_buf_t data structure changed, update the memory map version number so that the cache will not be reused. LICENSE MIT Change-Id: If01997ebd90c8f004d7cf4ba92f46fe4b9f570bf Reviewed-on: http://gerrit.openafs.org/1772 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 690b5c814e13bfc4652043474d2dcf48e4c8468d Author: Derrick Brashear Date: Sat Apr 17 10:14:50 2010 -0400 openafs 1.5.74 make 1.5.74 versions Change-Id: I320cdbab2961dcf2a17bb71e8d4283aaf38941ce Reviewed-on: http://gerrit.openafs.org/1768 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit a9018b3132c92400bc87d7f3cf88b547d20f3ece Author: Jeffrey Altman Date: Sat Apr 17 11:13:21 2010 -0400 Windows: 1.5.74 change log Important changes affecting the Windows distribution for 1.5.74 Change-Id: I980a66a2ab4a90c580249641fc22e3c7a91097dc Reviewed-on: http://gerrit.openafs.org/1770 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 3ad9c5583845986979a25d615a9640770a3bf9f6 Author: Jeffrey Altman Date: Fri Apr 16 22:42:34 2010 -0400 Rx: make conn_call_lock and conn_data_lock usage consistent The rx_connection.flags field is protected by the conn_data_lock but the conn_data_lock is not held everywhere the conn flags field is altered. This produces a race that can result in a deadlock when waiter flags are inadvertently prevented from being cleared. The conn_call_lock usage in rx_EndCall which was removed in Change e169708681eb1bbbb31951b95f68e861a4b01c7e must be restored. If rx_EndCall never obtains the conn_call_lock it can't ensure that the thread in rx_NewCall actively checking the calls will not end up blocking when there is now a call channel that can be reused. This usage of conn_call_lock can be removed only if a true producer/consumer model is implemented. Change-Id: Id093fd6c4a42afb833c775411be0cd406abf4ef7 Reviewed-on: http://gerrit.openafs.org/1766 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f6d2a279b9f4899f2ab072d949f0d4ff11a517f6 Author: Jeffrey Altman Date: Fri Apr 16 22:52:20 2010 -0400 Windows: cm_UpdateCell must hold cell lock across server random cm_UpdateCell fails to hold the cell lock across the server randomization. As a result the vlserver list can be destroyed while randomization is taking place. LICENSE MIT Change-Id: I7753e7e9f8a7d536ce0e2082aaca7b62ab745504 Reviewed-on: http://gerrit.openafs.org/1767 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 249f80fe747d03a84d42e78272dfe291084cacf8 Author: Jeffrey Altman Date: Thu Apr 15 21:43:44 2010 -0400 Windows: CM_SCACHESYNC_STOREDATA for non-files have no buffers Do not add QData objects with null cm_buf_t pointers to the cm_scache_t bufWritep queue when synchronizing directory changes. If a callback is required while the directory change is being pushed it can result in a deadlock. LICENSE MIT Change-Id: Id66c52ed794ceec44011167659e41a0b61898625 Reviewed-on: http://gerrit.openafs.org/1761 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 168f69db1995c0bce4daad2e4af1558282c2f80c Author: Jeffrey Altman Date: Fri Apr 16 00:31:58 2010 -0400 Windows: define new event log messages for cm_Analyze VBUSY, VRESTARTING, etc. Add MSG_SERVER_REPORTS_VBUSY, MSG_SERVER_REPORTS_VRESTARTING, MSG_ALL_SERVERS_BUSY, MSG_ALL_SERVERS_OFFLINE, and MSG_ALL_SERVERS_DOWN. Add event message throttling. Only permit one copy of a message to be generated every five seconds if the message will duplicate the prior message. This often occurs when a server or volume becomes inaccessible and there were a large number of requests queued on it. Integrate these new messages into cm_Analyze processing for VBUSY, VRESTARTING, ALLDOWN, ALLOFFLINE, and ALLBUSY errors. LICENSE MIT Change-Id: Ib30595ded23724810e294133fa75873e20ffbf0b Reviewed-on: http://gerrit.openafs.org/1762 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 5a253b19117e4f42c0db91ca3a45843462c0266c Author: Jeffrey Altman Date: Fri Apr 16 00:09:25 2010 -0400 Windows: wait for I/O on buffers to complete in cm_SetupStoreBIOD cm_SetupStoreBIOD constructs a list of dirty buffers for a file that are to be written to the file server. When constructing the list, if when determining the first dirty buffer we come across a buffer that is already actively involved in an I/O operation, call buf_WaitIO() to wait until the buffer is no longer busy before continuing. This reduces lock contention and synchronization conflicts. LICENSE MIT Change-Id: Icd79b9578b7411b138f14257bcb885249960eab0 Reviewed-on: http://gerrit.openafs.org/1760 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 349f533351a8a13a7fa2a14edd9139714064c82d Author: Jeffrey Altman Date: Thu Apr 15 23:58:21 2010 -0400 Windows: split cm_buf_t.flags field to ensure proper locking It turns out that for all these years the locks protecting the cm_buf_t flags field have been racy. Some of the flags were protected by the cm_buf_t mutex and others by the buf_globalLock. This patchset splits the flags field so that the appropriate lock will be used exclusively to protect a common set of flags. LICENSE MIT Change-Id: I85c98c85244c987df30a811d405f7d897e407ba2 Reviewed-on: http://gerrit.openafs.org/1759 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit f02d34315ed260e716c49ca9adeaa2635e334e60 Author: Marc Dionne Date: Fri Apr 16 19:34:35 2010 -0400 Remove unused variable in vos.c Remove an unused variable introduced by a recent commit. Change-Id: I04432d87a27b656807430f041f84d6ada2632434 Reviewed-on: http://gerrit.openafs.org/1765 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit a20326646dead6256637229b6456c380177a28ca Author: Derrick Brashear Date: Fri Apr 16 11:49:43 2010 -0400 work around finder setting modes on symlinks we could mask the mode setting on symlinks, however, it would be nice to change the fileserver to allow mode setting on symlinks in some (safe) cases. preserve our ability to do so. Change-Id: Iba69965c607530bcf2210b508c7aa37403c47477 Reviewed-on: http://gerrit.openafs.org/1764 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2a35e3a0286882eb91d4caddcb0054c413fb7db3 Author: Harald Barth Date: Fri Apr 16 01:45:35 2010 -0400 Add vos setaddrs command and man page The vos setaddrs command sets the IP addresses for a server entry in the Volume Location Database (VLDB). Specify one or serveral hosts. All existing hosts in the VLDB entry are replaced with the new entries on the command line. Change-Id: I3c26e49c4a6e2aebae363017d074329ac265132a Reviewed-on: http://gerrit.openafs.org/1744 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ef960553d7102ddab1ba6c85d51cba79b8fef7b5 Author: Jeffrey Altman Date: Fri Apr 16 09:32:42 2010 -0400 Convert param.rs_aix61.h EOF from CR-LF to LF The src/config/param.rs_aix61.h source file was stored in the repo with CR-LF end of line. This is causing problems for Windows Git which converts CR-LF to LF for storage in the repo. Change-Id: I8937322ac368ac275d3dbc6bcccf2808d3db061f Reviewed-on: http://gerrit.openafs.org/1763 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 4eef3b62657504c0c1cec718332dbdf4e200b20e Author: Simon Wilkinson Date: Thu Apr 15 20:52:11 2010 +0100 Tidy up UKERNEL includes UKERNEL is just another userspace build - there's no need to maintain completely separate header file lists in each object file for "userspace" and "ukernel". Tidy this up to improve the readability of these sections of code. Change-Id: I69f476a0b8aae1204cd4207c7c656ec7e07184df Reviewed-on: http://gerrit.openafs.org/1758 Tested-by: Andrew Deason Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0607e8a4a19183798c656bf29aaa3f8aa75ac078 Author: Jeffrey Altman Date: Wed Apr 14 23:21:37 2010 -0400 Rx: restore thread safety to rx_NewCall Thread safety in rx_NewCall requires that only one thread be actively allocating or recycling a call at a time. Since we are no longer holding the conn_call_lock across the entire transaction we need to have another synchronization mechanism. Add a new rx_connection flag, RX_CONN_MAKECALL_ACTIVE, which when set indicates that a thread is actively obtaining a call. If any other threads see this flag set, they will wait until being signalled that the thread has completed its activity. In addition, because the call->lock may be dropped when processing rxi_ResetCall(), we must hold a reference to the call once we begin using it. Otherwise, the call may be garbage collected behind our back. Change-Id: Ie97757f812d7043203ffcaf399400789cda39da1 Reviewed-on: http://gerrit.openafs.org/1755 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b2773aa121d3c1c31ac39ac652566f54cfc4bd1b Author: Derrick Brashear Date: Wed Apr 14 12:10:31 2010 -0400 macos and bsd readdir type guessing fix right now we never return a link hint. we know here it's a link. say so. Change-Id: Iab81b83fc8de714ad52c99c86153159aa6f641f3 Reviewed-on: http://gerrit.openafs.org/1753 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 74698fbcdbf2a9adfcdd152952e18a10f2c6e80f Author: Derrick Brashear Date: Thu Apr 15 00:13:43 2010 -0400 darwin bulk race needs an iocount if another user raced with us, we need an iocount back since finalize will have dropped one. Change-Id: I93b2bb5b6004b39436684e78c4620f4d7d9d0c8e Reviewed-on: http://gerrit.openafs.org/1756 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 72aab36e10b2349cb22197fda09a330feed68ac7 Author: Derrick Brashear Date: Thu Apr 15 01:29:31 2010 -0400 snowleopard fuse fallout didn't notice in testing that 64 bit version of afsd got slaughtered. put it back. Change-Id: I3a6588df36a31ab014d79faf4ed5646339f6f84b Reviewed-on: http://gerrit.openafs.org/1757 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ab2005d719d2184a1645fdc33f49e73275d91353 Author: Marc Dionne Date: Tue Apr 13 19:35:39 2010 -0400 Replace unsafe use of gets() Build tools compain that this is dangerous - replace gets() with a bounded fgets(). Change-Id: I3bd1854a1dc4a11c801cabb987ab680fa978bd20 Reviewed-on: http://gerrit.openafs.org/1750 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3f101a9ef49dbb31f516d08b82c716548b66882e Author: Derrick Brashear Date: Wed Apr 14 18:33:47 2010 -0400 drop afs_xserver lock during GetCapabilities new contact to a fileserver can trigger an InitCallBackStateN RPC to us, which our agent will need afs_xserver to handle. don't hold it; we only need it to fill in capabilities. racing here is ok. Change-Id: Ie0aaea3ab462e421bd31ba3b703d8cd0cb0d61df Reviewed-on: http://gerrit.openafs.org/1754 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 55a24ddd4231782bf4a76c8fabade00c67845501 Author: Russ Allbery Date: Tue Apr 13 16:32:49 2010 -0700 Autogenerate a Debian changelog for correct package versioning The Debian packaging infrastructure takes the package version from the most recent entry in the changelog file. Change the changelog file to a template and add an entry to the top that will be set to the current version of OpenAFS, with a Debian revision that will sort before any official package. Change-Id: Ic7fb1d30be10210b7d032cdc49a963410997db82 Reviewed-on: http://gerrit.openafs.org/1749 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 38a80c33233852d47a124a26fe7428543df6a10f Author: Andrew Deason Date: Thu Apr 8 14:50:18 2010 -0500 Add a FUSE implementation for afsd This adds afsd.fuse, which allows for mounting AFS via FUSE (via libuafs), instead of via the OpenAFS kernel module. Change-Id: Iaafe4a5f3034fed943e2e73f79ac95580946f9a8 Reviewed-on: http://gerrit.openafs.org/1725 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0dbe0fba4f4249be11524f8e2d3a1e115591cd18 Author: Andrew Deason Date: Tue Apr 6 17:07:33 2010 -0500 Use afsd code in libuafs Share the same CM code for the kernel client as in libuafs, so we don't duplicate code for initializing the cache and other things. In order to do this: - Remove some libuafs global variables that share name and functionality with those in afsd, and declare some static - Remove uafs_Init(), and move the ukernel-specific code in it to osi_Init(); replace with uafs_Setup(), uafs_ParseArgs(), and uafs_Run(), which just call into afsd functions - Remove libuafs' cache initialization code (CreateCacheFile, SweepAFSCache, etc); instead just use afsd's - Add uafs_mount(), to perform the 'mount'ing step that takes place in the normal kernel CM - Add afsd_uafs.c for the glue between afsd and libuafs Note that this now requires libcmd for libuafs. Change-Id: I62306a18ad255680031494caf1720b29e22856d2 Reviewed-on: http://gerrit.openafs.org/1724 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 507b08a6964bd9bf98784959aaa43796283a2d09 Author: Jeffrey Altman Date: Mon Apr 12 14:45:14 2010 -0400 Rename uvldbentry spare1 to matchindex In the nvldbentry structure 'spare1' was renamed to 'matchindex'. Do the same for uvldbentry as that is what the field is used for. Change-Id: I2d1200b1044f6ae9b4523eb603a21b0484b046c7 Reviewed-on: http://gerrit.openafs.org/1741 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ea44842df8f5098798e3b8ffb1b6ff62cbfcc246 Author: Marc Dionne Date: Tue Apr 13 18:58:11 2010 -0400 Fix new UKERNEL warnings on 64-bit Commit 830cb48c enabled new warnings when building UKERNEL, which causes builds with --enable-checking to fail. These are 64-bit specific warnings from int to pointer conversions and one printf warning. Changes: - cast printf argument to (int) in afs_usrops.c - use (iparmtype)(uintptrsz) to convert 32-bit integers to pointers - move the definition of uintptrsz to src/afs/afs.h so its available to other source files, and remove the original definition in afs_syscall.c Change-Id: Id0a5fd762cf10a741f89e3a2ed0a85556137df49 Reviewed-on: http://gerrit.openafs.org/1748 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d773b01a61d2f7dbf8362ddbad8e31887841de20 Author: Andrew Deason Date: Tue Apr 13 13:53:13 2010 -0500 Add support for pkg-config m4 macros Include pkg.m4, so we can use pkg-config macros in autoconf even if pkg-config is not installed. Change-Id: Ie81307beb84499297e251f0f90781d544044a235 Reviewed-on: http://gerrit.openafs.org/1747 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6bccc0aee0b8a0b0a0b665064c746b8e3fb22843 Author: Andrew Deason Date: Tue Apr 13 12:59:30 2010 -0500 Squash afs_GenericStoreProc warning code is potentially unitialized. Initialize it. Change-Id: I9c8a787d9f7f05ea88752063f1b31e0be61e28ba Reviewed-on: http://gerrit.openafs.org/1746 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 830cb48cbdd6fb41f7db8b50429ca7441a963518 Author: Andrew Deason Date: Tue Apr 13 12:41:31 2010 -0500 libuafs: Add $(XCFLAGS) to CFLAGS on all platforms Only darwin had $(XCFLAGS) in the libuafs build for some reason. Add it to all platforms, so they get e.g. -Wall if so configured. Change-Id: Ifab39af3abf087932feb1b9085ccb26baaec3164 Reviewed-on: http://gerrit.openafs.org/1745 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6b549bdba641d883609d9d33ceba957395fff37a Author: Michael Meffie Date: Mon Jan 11 21:16:06 2010 -0500 DAFS: avoid volume lock contention during initialization Avoid the excessive volume lock contention during startup to improve the time to pre-attach a very large number of volumes. The parallel attach worker threads avoid the volume lock while scanning the partitions for volumes and send batches of volume ids to the main thread to be preattached under the volume lock. FIXES 124489 Change-Id: Ieb33a3bdd5b06349abd9c3dd994c620021cd6194 Reviewed-on: http://gerrit.openafs.org/1092 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 523d39f020f551e59b0f369c8480fa13b90db277 Author: Felix Frank Date: Wed Mar 3 22:41:15 2010 -0500 Fileserver capabilities support for the UNIX client The attached patch has the client perform a GetCapabilities RPC on fileservers it encounters. It uses an additional server flag bit to keep track of the servers that have been queried already. In the case of afs_CeckServers(), GetTime RPCs are largely replaced by GetCapabilities. GetTime is performed on a server if and only if afs_setTime is nonzero and either (a) no setTimeHost has yet been determined or (b) the server in question has been designated as setTimeHost The GetServers() function could thus be simplified even further wrt. the setTime mechanism, but doing so would imply more rewriting (violating the KISS principle; a followup patch should deal with that). When a client is asked to reset callback states, it also resets the "capabilites known" bit. Thanks go to Simon Wilkinson, Jeffrey Altman and Jeffrey Hutzelman for input regarding logic and implementation details. FIXES 124972 Change-Id: I4e22db3c5ca71f00e8c77f337e38daa0fa5b9124 Reviewed-on: http://gerrit.openafs.org/1640 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3f09a3cbd30feea0add9e288380a32bba8230e0f Author: Jeffrey Altman Date: Mon Apr 12 08:58:20 2010 -0400 Rx: avoid out of order lock acquisition in rx_NewCall Sha-1 33010ef25e716f2ec2df17cc113f4ef8f67e3a74 broke the lock order conventions between the conn->conn_call_lock and the call-lock. This patchset corrects the ordering and handles the synchronization issues that might occur when the call->lock is dropped within rx_NewCall. Change-Id: Ic05837e2491a1e738e7585cf2ee6cda20775229b Reviewed-on: http://gerrit.openafs.org/1740 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit edbfcbdf0efa01fde56c9f8d857b495a86f24a14 Author: Andrew Deason Date: Mon Apr 12 12:39:00 2010 -0500 Do not turn off AFS_HAVE_STATVFS for UKERNEL Many param files turn off AFS_HAVE_STATVFS for UKERNEL. We obviously still have statvfs() available whether we are running with UKERNEL or not, so modify param files to enable it for UKERNEL if it was enabled for non-UKERNEL. The only places using this define are afsd and vol/partition.c, the latter of which will not be affected. Change-Id: I1f276c88cbe0ca401580a564be664a7fc6739fde Reviewed-on: http://gerrit.openafs.org/1743 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f77c078a291025d593f3170c57b6be5f257fc3e5 Author: Andrew Deason Date: Thu Apr 8 16:37:51 2010 -0500 Split afsd into afsd.c and afsd_kernel.c Move the parts of afsd.c that depend on using the kernel module into afsd_kernel.c. Keep in afsd.c code that can be used with libuafs drivers. Change-Id: I22c4dd698e8c12c42dabd85ea38226ffd8746d11 Reviewed-on: http://gerrit.openafs.org/1723 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b28cdd0a0e59290d8cdbf73de26ce8f34b068a61 Author: Matt Smith Date: Sat Apr 10 01:36:59 2010 -0500 Fix problems from afs_osi_gcpags reorganization Corrections to mistakes made during the reorganization of afs_osi_gcpags.c to per-OS directories. Includes fixes to LINUX24 and whitespace corrections. Change-Id: Ie9d1637b00dacc0f58e90df0e4fb2505a571bc1b Reviewed-on: http://gerrit.openafs.org/1737 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8d9bb0defb3f63640d557b377fa937d0db0de013 Author: Michael Meffie Date: Fri Apr 9 22:31:24 2010 -0400 afsmonitor: fix segv on exit Fix crash during afsmonitor shutdown when monitoring multiple fileserver or clients. Change-Id: I5fa5cb7d89dbdfcc5f97541a0e0c6b0836d558b1 Reviewed-on: http://gerrit.openafs.org/1735 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 35b90a6f526f3724d88acd95c9d4594ec9b3c736 Author: Michael Meffie Date: Fri Apr 9 21:03:09 2010 -0400 afsmonitor: show busy counts Update afsmonitor to display rx_nBusies, fs_nBusies, sysname_ID, and fs_GetCapabilities, which where claimed from spare fields long ago. Add a new group name called Busies_group to show just the busy fields. Change-Id: Id096c8bd8ba148def425a75e06250f7d5319672b Reviewed-on: http://gerrit.openafs.org/1734 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dc915673f23bf18c0eda9bf947422f6b5360fdb7 Author: Marc Dionne Date: Fri Apr 9 20:19:19 2010 -0400 Fix UKERNEL build error - include afs/afs_osi.h Commit d0f2ffca breaks the build on my system because afs/afs_osi.h no longer gets included for the UKERNEL + !KERNEL case. This causes many errors as a result of missing definitions such as afs_kmutex_t. Pull out this include into a separate ifdef based only on "KERNEL". Change-Id: Idafa7702550eb8cb2c7693f4173e482b15702d7e Reviewed-on: http://gerrit.openafs.org/1733 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6de3486c2c78cfbb2e9a9038593b60cfccf671a6 Author: Matt Smith Date: Fri Apr 9 13:32:46 2010 -0500 Move contents of afs_osi_gcpags to per-OS files Moved the relevant chunks from src/afs/afs_osi_gcpags.c to osi_gcpags.c located in each of the OS subdirectories. Also updated libafs and libuafs to reflect these changes. Change-Id: I537d92952718ef3b3bb0583daf7993288716652c Reviewed-on: http://gerrit.openafs.org/1727 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 185a6a474ccaf15c1abb708bcdfe27857454cef4 Author: Andrew Deason Date: Thu Apr 1 13:55:51 2010 -0500 Correct incorrect type-punning fixes Commit 549002c906795f978eebf81c706995116a04a8ff attempted to resolve a few type-punning-related warnings, but did so using unions. Unions are not guaranteed to work correctly with type-punning on non-gcc, so partially revert and reimplement. Change-Id: I6a49184284809c929bc45b5de5b32b8323467505 Reviewed-on: http://gerrit.openafs.org/1679 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4c68f58827913129947bc44978e7469b3271c3c6 Author: Michael Meffie Date: Thu Apr 8 13:27:36 2010 -0400 afsmonitor: add fs callback xstats collection Adds the capability to afsmonitor to display and process thresholds for fileserver callback xstats collections. The callback counters are placed to the right of the full perf data. When afsmonitor is started without a configuration file, the callback xstats data is retrieved and displayed, since by default afsmonitor will show every field. When a configuration file is given, poll the fileserver only for the collections needed to display information requested by the 'show fs' commands. Change-Id: I572ff682de4cc7ef27bb46dd028d3d797b873841 Reviewed-on: http://gerrit.openafs.org/1731 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7214af16a9cc23632f2a00d035e6c0afec887e55 Author: Michael Meffie Date: Fri Apr 9 11:46:10 2010 -0400 afsmonitor: avoid showing full perf stats garbage Unfortunately, the full perf stats contain timeval structures which do not have the same size everywhere. Avoid displaying gargbage, but at least try to show the overall stats. Change-Id: I9245b333ac15212194490e1a3f11b7c98dfaadda Reviewed-on: http://gerrit.openafs.org/1730 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 76a1088782f363cc784f7a8fe2aa3906558ec559 Author: Derrick Brashear Date: Fri Apr 9 15:21:08 2010 -0400 ukernel osi prototypes header and add statvfs to it so we stop getting a warning Change-Id: I585f559f083203214d298062862434f9f381808b Reviewed-on: http://gerrit.openafs.org/1729 Tested-by: Derrick Brashear Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear commit f54785bdedea5aad8d6d918b4ad4e99fca9836e1 Author: Andrew Deason Date: Thu Apr 8 15:35:12 2010 -0500 UKERNEL: allow creation of non-detached threads Make usr_thread_create create a non-detached thread by default, and just have callers call usr_thread_detach if they want it detached. The only current caller of usr_thread_create already calls usr_thread_detach. Also add usr_thread_join to make it possible to join a created thread. Change-Id: Iad581c45d36dc43e94c950a5ca6a41dea8dc4b2f Reviewed-on: http://gerrit.openafs.org/1722 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2f03d4e6e25d0db4986120e1d2ec6a200b0d0d39 Author: Andrew Deason Date: Tue Apr 6 16:57:27 2010 -0500 Use AFS_CACHE_VNODE_PATH for UKERNEL Use the AFS_CACHE_VNODE_PATH cache mechanism for UKERNEL, to be compatible with new kernel caching code, and simplify the cache code a little bit. Change-Id: Ifc44790db08a336cca0032a1d05eedf70d2b24b8 Reviewed-on: http://gerrit.openafs.org/1721 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d0f2ffcaa3728bbcccf63b37ab1a52e8b45ede96 Author: Andrew Deason Date: Fri Aug 14 16:17:11 2009 -0500 Make osi_GetTime work on 64-bit libuafs libuafs was previously using an implementation of osi_GetTime (and thus clock_GetTime) that required 32-bit time_t's to work properly. Instead, just use the non-kernel osi_GetTime for UKERNEL, since we're just in userspace either way. Change-Id: I4f2d060f7e2aaeaaa3fe164aca6bee5333de4583 Reviewed-on: http://gerrit.openafs.org/1714 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d29a2443f028c04d09817ca0f6b62b0ae23c6af7 Author: Andrew Deason Date: Thu Apr 8 17:22:35 2010 -0500 afsd: squash inode format warning Coerce the inode into an int, so we can predictably print it when we print debug info. Change-Id: I81533b66b632eb0fed3a9e37480feaf2fa92d510 Reviewed-on: http://gerrit.openafs.org/1720 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 269d7cc02ad65af5caf0369a07eab54052378ce8 Author: Andrew Deason Date: Thu Apr 8 17:26:09 2010 -0500 UKERNEL: prototype uafs_Shutdown Prototype uafs_Shutdown in afs_usrops.h, so users of libuafs can stop the CM. Change-Id: I63e0106f7bfb5fff9a3ff1936005f6e24855efec Reviewed-on: http://gerrit.openafs.org/1719 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 54b78ce087776342a4abb301fcb3fe8e58180621 Author: Andrew Deason Date: Thu Apr 8 12:15:34 2010 -0500 UKERNEL: Use real vnode type constants In UKERNEL, make VDIR be S_IFDIR, VREG be S_IFREG, etc. This makes fakestat work correctly, since the va_mode of faked mountpoints are OR'd with VDIR. Change-Id: I7ac1dc7ae1d7cefade9bf92d8169db80977a5c76 Reviewed-on: http://gerrit.openafs.org/1718 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d6345e824514d7f301b43b99e5f8067d66770ed7 Author: Andrew Deason Date: Tue Apr 6 17:00:58 2010 -0500 UKERNEL: check for null afs_CurrentDir on shutdown During shutdown, do not release afs_CurrentDir if we don't have one. Change-Id: I809a23f36929a02cb63753d66627357615cbaf9e Reviewed-on: http://gerrit.openafs.org/1717 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b822971a3ee6bd2dc0024b30b255f8f83e23637c Author: Andrew Deason Date: Thu Apr 8 14:49:53 2010 -0500 UKERNEL: add uafs_statvfs Change-Id: Iedd7882f4a57cd89d145f1c61c5f85181187db03 Reviewed-on: http://gerrit.openafs.org/1716 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f7b192364227be1d1db58097d72b049f8ebc0777 Author: Andrew Deason Date: Fri Aug 14 16:26:16 2009 -0500 Prevent uafs_readdir/closedir segfault Check for the NULL case in uafs_readdir/closedir, so we don't blindly dereference the given pointer. Change-Id: Iaefce9bf2e5135a60e9739f866a1f27333f06e28 Reviewed-on: http://gerrit.openafs.org/1715 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 50f248d160a34cd83363d97a1a5f0ff8beb83299 Author: Russ Allbery Date: Thu Apr 8 14:54:23 2010 -0700 Update Debian packaging files The Debian packaging files in the tree were ancient. Update to the packaging files from the just-uploaded 1.5.73.3-1 version, which should build and correctly install the current development source. The current packaging files no longer use a hard-coded version in debian/rules, so remove the configure machinery for creating it. The correct way of handling the version number is to generate a new changelog entry. That work will come in a subsequent patch. Change-Id: I187fe7cc3f4ca38de6165d58274841d300b6cdf1 Reviewed-on: http://gerrit.openafs.org/1713 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cf432e38459b963e74f46a4833626b2c03f2fad7 Author: Russ Allbery Date: Thu Apr 8 13:23:11 2010 -0700 Add OpenAFS-debug.*.plist to .gitignore Change-Id: I6f931cb19997c8743223ee42d4072ad632c3bad4 Reviewed-on: http://gerrit.openafs.org/1712 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f2af7a6ffcead3ffd1f2ae9fac5fc682c6c8c7ac Author: Michael Meffie Date: Wed Mar 10 08:48:38 2010 -0600 pts mem -expandgroups option Improve support for supergroups in the pts membership command with a new option called -expandgroups. This option will recursively show the complete membership of users and groups. The expanded members of a group are all the users which are members of all of the group's sub-groups. The expanded groups of a user are all the groups which are supergroups of the users's groups. Change-Id: I811a4e5e73632e5e205fe10f3f3a36a98464d49e Reviewed-on: http://gerrit.openafs.org/1601 Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5b44b5dfe0d7aee14f87df9a6b8c5e582473d0fe Author: Michael Meffie Date: Wed Mar 17 19:16:50 2010 -0400 pts mem -supergroup option Improve pts support for supergroups with an option to list the supergroups of a group. Change-Id: I4fe1cd131cd334386bc16ce733e01e29e0511d4f Reviewed-on: http://gerrit.openafs.org/1600 Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fdb9429eafda330bfdf1feefeb1a9ff61c7746b7 Author: Simon Wilkinson Date: Wed Apr 7 00:29:44 2010 +0100 Linux: kmap() not page_address() Using page_address() will return NULL if the page is in highmem. To avoid this, we must kmap() the page we're getting the address of, and kunmap() when we are done. If the page isn't in high memory, then kmap() is equivalent to page_address(). Change-Id: I42abfadaf3101bf5ad41bd7e5f720ba2583c4ee5 Reviewed-on: http://gerrit.openafs.org/1705 Reviewed-by: Russ Allbery Tested-by: Russ Allbery Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear commit 75cf37f9449e2c75236028b603918d22cd278ef9 Author: Russ Allbery Date: Wed Apr 7 11:53:23 2010 -0700 Explain in CellServDB man page that server lines can be omitted It's possible to use AFSDB records only to locate the VLDB servers but still list the cell in the client CellServDB so that the client is aware of it and populates it into dynroot. Describe doing this in the man page. Change-Id: I714cd515dc4b72a6e358bbd8f9332d4ddce5a5fc Reviewed-on: http://gerrit.openafs.org/1710 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit be44999904dccffc6de5626362a77babbda0688f Author: Andrew Deason Date: Wed Apr 7 10:35:53 2010 -0500 Fix typo in bos_create manpage Change-Id: I1ea456e47eccc0a74f042898ef8a3bcde3aacf15 Reviewed-on: http://gerrit.openafs.org/1709 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4ebd6098dfbf76ebc5ede7a2e9d7222936265a03 Author: Rod Widdowson Date: Wed Apr 7 11:14:32 2010 +0100 Make tests/afcp compile cleanly It didn't compile because it includes changing that to afs_consts.h makes it happy. Change-Id: I3a21e6ab2b99d8f4ebbc55922163b0695a6187f3 Reviewed-on: http://gerrit.openafs.org/1708 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8d41bc24c51018a25eac49b3403cbb276713e1ad Author: Russ Allbery Date: Tue Apr 6 16:31:37 2010 -0700 Reallocate memory in aklog for the AFS ID string aklog was previously writing the magic AFS ID string into previously alloated memory with sprintf, but the variable in question was only as long as the username, so this code could overwrite memory and lead to heap corruption. Free previously allocated memory and use afs_asprintf to format the AFS ID string instead. Change-Id: I7649864817340764c39c176606a9a543c10983c9 Reviewed-on: http://gerrit.openafs.org/1706 Tested-by: Russ Allbery Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a763edc3a490f6c837d4272468803c36f8febda2 Author: Russ Allbery Date: Tue Apr 6 15:27:51 2010 -0700 Make src/rx/rx.c not executable Change-Id: If471b579e6f1bf4f69a37f6edcc34e9546766df2 Reviewed-on: http://gerrit.openafs.org/1704 Tested-by: Russ Allbery Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7d395f1754649b70311895c37962cd1770cb9f73 Author: Russ Allbery Date: Tue Apr 6 17:46:13 2010 -0700 Improve demand-attach fileserver bos documentation Add a caution to the fileserver man page explaining that traditional and demand-attach require different configurations, and also mention that there are two different server implementations. Add an example of a bos create command for creating a demand-attach File Server to the fileserver man page. Add a caution to the bos create man page that a traditional fs node won't work with demand-attach and vice versa. Document the necessary arguments for the dafs type. Clarify in EXAMPLES which bos create commands are traditional and which are demand-attach. Add an example of changing from a traditional to a demand-attach configuration. Change kaserver to ptserver in the example of a simple process. Change-Id: I4077246b69edf6e1ddc7c0761ac8e1006d471c24 Reviewed-on: http://gerrit.openafs.org/1707 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 10884e7354e6d5a3b7869e115cc90424410cfd12 Author: Jeffrey Altman Date: Mon Apr 5 11:24:16 2010 -0400 Windows: WinTorture Verbose mode display all logged messages In verbose mode, wintorture should send to stdout all logged messages. LICENSE MIT Change-Id: I4e173c35fcf6b1284d31149d773308b9f9c9a773 Reviewed-on: http://gerrit.openafs.org/1696 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit eb25c5b1c3b7d7e25ce00bafc08fa2d92acc4afa Author: Jeffrey Altman Date: Tue Apr 6 15:07:47 2010 -0400 Windows: Support new Cygwin docbook stylesheet location Make the computation of the docbook stylesheet location based upon testing for directory existence now that versions of cygwin 1.7.2 and place the stylesheets in a new location. Change-Id: I844ae35a34eab73ee033bba875e68f71dc54f26b Reviewed-on: http://gerrit.openafs.org/1702 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 10b4833d29025c01e8eeea1c5b3411bda9a4cbc5 Author: Jeffrey Altman Date: Tue Apr 6 15:06:55 2010 -0400 Windows: permit documentation to be built without binaries Add a dependency to the documentation rule on config so that the documentation can be built without the entire source tree Change-Id: I81d18fa9ec32c4d7d9799db2b1eac57c1d83df75 Reviewed-on: http://gerrit.openafs.org/1701 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 0bc5b666b1c4a46d2dd797415dc7d25a460bbf59 Author: Jeffrey Altman Date: Tue Apr 6 14:29:26 2010 -0400 Windows: tag is listitem not llstitem Latest version of docbook picked this error up. Change-Id: I2e6248d27e56c0074b0f80124733b79d7d1b51f0 Reviewed-on: http://gerrit.openafs.org/1699 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit b9f014bdbf1ff009dba56f138a6c618281539d9a Author: Derrick Brashear Date: Tue Apr 6 14:42:44 2010 -0400 make openafs 1.5.73.3 another point release Change-Id: I3430d62a4088e0b6f930b0b6cd2507f96226adea Reviewed-on: http://gerrit.openafs.org/1700 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit da4a70eabfab3ad0d1db0f7cc60b7a4f2a8c04f1 Author: Derrick Brashear Date: Tue Apr 6 09:57:24 2010 -0400 macos bulkstat avoid reclaiming vnodes when a vnode has gone CVInit, don't use it as a vlru pivot. Change-Id: I0b874c141069a23a9724d360a7864b0271c36e15 Reviewed-on: http://gerrit.openafs.org/1698 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 170a12c6eacab152bea9576bfcdb9cf9c0bea8ce Author: Derrick Brashear Date: Sun Apr 4 10:37:48 2010 -0400 avoid macos bulkstat vlru when no non-dead vnodes exist if we can't find a candidate to be the vlru item to manipulate past, simply don't do the vlru update FIXES 126868 Change-Id: I5c053d1934b0787ab7f2021c70a776e54208d345 Reviewed-on: http://gerrit.openafs.org/1690 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2b42e781681a3024f3e50685a51293bd87d08f59 Author: Derrick Brashear Date: Mon Apr 5 00:42:04 2010 -0400 panic generation update something weird, e.g. panic(cpu 0 caller 0x5c91c3d0): buf@/Users/shadow/Source/openafs/src/rx/rx_kcommon.c:1348 which came from an osi_Assert. not sure yet what the deal is, but attempt to make this less ambiguous and less likely to conflict with other macros. Change-Id: Iac27e89fc655d2b1ba6d04936e137060d8abd9c4 Reviewed-on: http://gerrit.openafs.org/1693 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 03bb2c9d40859ce5d1205e7c8503a80c8192f5e4 Author: Jeffrey Altman Date: Mon Apr 5 13:19:49 2010 -0400 Windows: cm_UpdateVolumeLocation !append exts to num vol names cm_UpdateVolumeLocation will append ".readonly" to a volume name if the base name cannot be located. However, this should not be done if the base name is numeric. LICENSE MIT Change-Id: Id61b8803eed51d124b612ffba8b185a4b4982c1d Reviewed-on: http://gerrit.openafs.org/1695 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 33010ef25e716f2ec2df17cc113f4ef8f67e3a74 Author: Jeffrey Altman Date: Mon Apr 5 13:35:42 2010 -0400 Rx: Remove conn_call_lock contention between rx_NewCall and rx_EndCall Add a new call state, RX_STATE_RESET, which permits us to remove the conn_call_lock contention between rx_NewCall and rx_EndCall. It is no longer necessary for rx_NewCall to hold conn_call_lock across rxi_ResetCall which can block. rx_EndCall is therefore always free to complete without unnecessary delays caused by rx_NewCall. Change-Id: Ie169708681eb1bbbb31951b95f68e861a4b01c7e Reviewed-on: http://gerrit.openafs.org/1697 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 568a4078563e2cb9bd89409486e361357cc18450 Author: Aditya Sarawgi Date: Mon Apr 5 22:55:48 2010 +0530 Replace kmodstat by kldstat FreeBSD uses kldstat instead of kmodstat to get the stats of the dynamically loaded kernel modules. Change-Id: I3f658469e60f48b50a81e6ab5bcc507186fd8c5a Reviewed-on: http://gerrit.openafs.org/1694 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f61d2ba1c9953136c8e27667407a800ff9b7a89b Author: Jeffrey Altman Date: Thu Apr 1 23:33:16 2010 -0400 Fix usage of RX_CALL_TQ_WAIT flag The usage of RX_CALL_TQ_WAIT flag was not consistent within both rx.c and rx_rdwr.c. When a thread is waiting on the transmit queue it must not only set the RX_CALL_TQ_WAIT flag but also increment the call->tqWaiters count. Upon waking up, it must decrement call->tqWaiters and only clear RX_CALL_TQ_WAIT if the tqWaiters count reaches zero. Change-Id: I7de01d27f073cddd9651fbcd9cd2038e56ac35cf Reviewed-on: http://gerrit.openafs.org/1685 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 00a0351ae0b0850f0191d5df2d9478fbc8e4f30a Author: Derrick Brashear Date: Thu Apr 1 21:33:49 2010 -0400 rx_ClearTransmitQueue should signal waiters when flushing if we flush, play it safe and signal tq waiters. Change-Id: I945649c2e440c78c5c5a62da70236a67dc190228 Reviewed-on: http://gerrit.openafs.org/1682 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit fc02ed1065ea4d3f2a55ace2b994a459ba4a5d8a Author: Derrick Brashear Date: Mon Apr 5 00:41:28 2010 -0400 macos panic decoder update make it able to decode prerelease and point release panics Change-Id: Ibf28a7df7f0a21ff8f297d548a6b853a5e296064 Reviewed-on: http://gerrit.openafs.org/1692 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ec74299c7c0f6e705e6ba2329001b92f9941868e Author: Derrick Brashear Date: Fri Apr 2 01:29:22 2010 -0400 macos 32 bit platform user address transform make the ioctl32 translator work as expected, e.g., create proper user addresses. Change-Id: Ia690dee5f9978d679e942a9954f2123df4a96bc2 Reviewed-on: http://gerrit.openafs.org/1687 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f9799b856183017274876ed09b1da2c069b5177d Author: Derrick Brashear Date: Fri Apr 2 01:32:06 2010 -0400 make 1.5.73.2 fix aklog for 32 bit macos, make freebsd vaguely more useful Change-Id: I53bb88f11eedb365e4430aed468cb9c84442d44b Reviewed-on: http://gerrit.openafs.org/1688 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 836c5bcfaf33ec118e209b066639c5196efedf47 Author: Derrick Brashear Date: Thu Apr 1 23:17:53 2010 -0400 freebsd switch back to condvar-based sleep add TimedSleep for condvar-based sleep. this should be revisited; mac and freebsd should be able to share this. possibly several other platforms. Change-Id: I918f45a689dd129119477cc63820f5c802e182d2 Reviewed-on: http://gerrit.openafs.org/1684 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 687652c74a050e28d1c0cffb24e58545257a13c8 Author: Derrick Brashear Date: Fri Apr 2 01:01:23 2010 -0400 macos installer pane warning fix didEnterInstallerPane is void, not BOOL. make it so. Change-Id: I934129684c839fa304bbfb7745833f5a7739e111 Reviewed-on: http://gerrit.openafs.org/1686 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit af5923c0507f45fc4124ed9ae5ac5ed014923034 Author: Andrew Deason Date: Thu Apr 1 16:42:25 2010 -0500 tubik: Correct use of flags_cond and version_cond Waiters of flags_cond and version_cond were not doing so correctly; the correct way is to acquire a lock prior to their respective checks, and atomically drop/acquire that lock with pthread_cond_wait. Otherwise, we could miss a wakeup if a flag changed between our check and when we wait. To make this possible, make versionLock a normal pthread mutex in AFS_PTHREAD_ENV, so it is a lock we can pass to pthread_cond_wait. Make the waiters pass versionLock to pthread_cond_wait, and eliminate flags_mutex and version_mutex. Change-Id: Id33a72182b907d069e342cb049e23868ab2f7eb9 Reviewed-on: http://gerrit.openafs.org/1681 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5a7d6da52573aeb5ca062e3458ea7c375ed28054 Author: Andrew Deason Date: Thu Apr 1 15:33:24 2010 -0500 Kill afs_inet_ntoa Replace all calls to afs_inet_ntoa with the threadsafe afs_inet_ntoa_r. afs_inet_ntoa was being used in a few places that may be threaded (ubik), and in general should be avoided in case the relevant code becomes threaded. Remove the definition of afs_inet_ntoa to prevent anyone from using it. Change-Id: I163d3f58fdd3d28077780963ced9995247682d78 Reviewed-on: http://gerrit.openafs.org/1680 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 73dd2783d7b73350ca047bf0bea2895e152eca71 Author: Derrick Brashear Date: Thu Apr 1 23:11:42 2010 -0400 freebsd glock assertions assert we don't try to recurse on the glock Change-Id: Iecf0f869e4a541a0b5322def47c944dec310ae3e Reviewed-on: http://gerrit.openafs.org/1683 Reviewed-by: Benjamin Kaduk Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8844c339608d92c6a69364f84fcd14366cea9f13 Author: Andrew Deason Date: Thu Apr 1 13:18:41 2010 -0500 fssync-debug: fix strict-aliasing problems We cannot type-pun pointers like that. Instead, declare a new struct on the stack, and copy the memory into it. Remove the CFLAGS_NOSTRICT suppression on fssync-debug.o. Change-Id: I25b48399417e009dc94bfebd513c0ee6feea282a Reviewed-on: http://gerrit.openafs.org/1678 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a83e7ea4d86352d89f270be93db77a0774aaea3f Author: Simon Wilkinson Date: Wed Mar 24 12:40:35 2010 +0000 Fix formatting issues in src/afs This patch changes formatting in src/afs to be return_type fn_name(args) { } ... as in the rest of the code. Change-Id: Ib6e792d0795a83ea6fcf35df4413dec6492a4cc0 Reviewed-on: http://gerrit.openafs.org/1645 Reviewed-by: Rod Widdowson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 91450a968df15b6134ab2cef49e5f4a3679735c8 Author: Ben Kaduk Date: Wed Mar 31 22:28:10 2010 -0400 Set a storeOps storeproc for the memcache case Finish fixing the bug from 34ffc9cd that 57d8e454 only partially fixed -- set a storeOps.storeproc element in rxfs_storeMemOps as well as in rxfs_storeOps. This eliminates a NULL/uninitialized memory dereference. Change-Id: I9fe0fb147222b8f7a5a76c9ada9ca93f53ce1fa7 Reviewed-on: http://gerrit.openafs.org/1677 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 709315400c9735a2360e01c927e5a3816a5dc2d3 Author: Ben Kaduk Date: Wed Mar 31 11:27:38 2010 -0400 Fix build for FBSD80 The change to a dynamically-allocated group list came before the change to allow the maximum size of that group list to be set as a tuneable at boot. The 8.0 release happened to come between them, so we must treat both cases. (Note that AFS_FBSD81_ENV is not yet defined anywhere; that will come later.) Change-Id: I87a0e2cff3c42de60d512fe5653abe0161afc789 Reviewed-on: http://gerrit.openafs.org/1676 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0b475c0c5f784c296ee7acba622353653d2b4504 Author: Ben Kaduk Date: Wed Mar 31 00:49:02 2010 -0400 Update to the new thread world order for FBSD Since FreeBSD 5.0, system calls have taken a thread argument instead of a proc argument. Finish catching up. Also remove the retval argument, which is not in the system sysent definition, and is unused. Since we took our sweet time getting around to it, we can also remove large swaths of FreeBSD 4.X-only code from the area. Fix the vop_*_args struct definition comments that had changes in addition to proc-->thread while we're here. Change-Id: Ib469e77655a6c04bfbfe1e5fab54f6f3a6119a85 Reviewed-on: http://gerrit.openafs.org/1675 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ef2604e4532d6712b3d91a98a4d1f1f070de487d Author: Ben Kaduk Date: Tue Mar 30 23:35:13 2010 -0400 Include limits.h for FBSD Needed to pick up INT_MAX in the KERNEL case, for stopping the XDR madness, among other things. Change-Id: Ibcf2681b450f6a3603418991951f5144ab677d28 Reviewed-on: http://gerrit.openafs.org/1674 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6a261db9a6bb1ac4b0bb2b88efe2e3e718970ab3 Author: Derrick Brashear Date: Tue Mar 30 16:28:27 2010 -0400 openafs 1.5.73.1 with rpm and macos versions which hopefully work for packaging (well, the macos does) Change-Id: I42016db95ddaff6f76e1f0954eb06cfd743f18cf Reviewed-on: http://gerrit.openafs.org/1670 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 053522f534f73f9843a68334158ff98a48d9578e Author: Ben Kaduk Date: Tue Mar 30 20:34:02 2010 -0400 Make GCPAGs_perproc_func cleaner for FBSD case Partially rewrite 2cf1f10a to reduce code clutter. Instead of accessing pproc->p_ucred directly in afs_GCPAGs_perproc_func(), push this access into a FBSD-specific afs_proc2cred() function. This is not quite right, since we do not lock the proc mutex, but in the same way as the old version and with more reasonable preprocessor conditionals. This also eliminates a probably-needless call to osi_Panic. Change-Id: Ib403132f31cc13f8c4581cb89ecc8938d0a0dd88 Reviewed-on: http://gerrit.openafs.org/1672 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c0f1970909d691d551273deee9b63bda50896ae6 Author: Jonathan Billings Date: Tue Mar 30 16:35:50 2010 -0400 Updated RedHat RPM spec file to include unreferenced files Added the libkopenafs libraries and headers to the authlib package. Added the afs_compile_et binary to the devel package Removed the reference to .../man5/afszcm.cat.* because it is already caught by the earlier reference to .../man5/afs* glob. This caused a warning during the package build process. Change-Id: I64a037a8534ac3d2c6b0aa22249d6827e08af9b1 Reviewed-on: http://gerrit.openafs.org/1671 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ae19c2d2464417a9454ef46ab3d63ae23024676d Author: Jonathan Billings Date: Tue Mar 30 16:06:07 2010 -0400 Move restorevol to bin from sbin in make dest Adds to the changes made in d6df1a8cec39edf7c0d2598921c735ac6aca70d7 so that 'make dest' installs restorevol into bin. Change-Id: I9c7f302ad9a2f25e9a362ea96dbbf0d91a7d9b04 Reviewed-on: http://gerrit.openafs.org/1669 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit da9b39c0a474c134f6e7c2bfd978bb7a70e770d0 Author: Derrick Brashear Date: Tue Mar 30 11:43:33 2010 -0400 darwin notify avoid reentrant vfs context panic if we own the context, don't get it again. Change-Id: I1f574bc3dda764c7a9552f1adf0f64e50afc1d7d Reviewed-on: http://gerrit.openafs.org/1668 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 283c0f5347a71ce2d4a1e22c8379f4f89b21489a Author: Russ Allbery Date: Mon Mar 29 22:17:31 2010 -0700 Update VCS instructions for Git Rename README.CVS to README.GIT and update the references from CVS to GIT. Refer readers to the wiki for the detailed instructions and information about Gerrit. Change-Id: Ia1826110c4b974ab36a64555ca44e6c5ce74f7ef Reviewed-on: http://gerrit.openafs.org/1667 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2f4a1897bfb2db8655a4eb2f87785753df1c5698 Author: Davor Ocelic Date: Mon Mar 29 16:54:43 2010 +0200 Minor state_analyzer manpage corrections Done according to adeason's comments on http://gerrit.openafs.org/#change,1655 Change-Id: Ia5b28473fa37ad2a877a5a56b1b7f1c4893e8db1 Reviewed-on: http://gerrit.openafs.org/1666 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 001a61a6180bb1c70401c40c8cd1d38d804eba8c Author: Rod Widdowson Date: Wed Mar 24 16:59:15 2010 +0000 Render the IP address for the "Ubik: Lost contact with sync-site" log message in the same way that all other IP addresses are (via afs_inet_ntoa, rather than stripping the buytes out in a manner which assumes a specific endianism). Done more as a way to test my understanding of the GIT/GERRIT technology with a small non-important checkin. Change-Id: I177e1288e8e23087aeebb7abe4ed63a7c2b88ccb Reviewed-on: http://gerrit.openafs.org/1649 Tested-by: Rod Widdowson Reviewed-by: Rod Widdowson Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7c6f94b365169cd643cbe03a23d14b2e35d429af Author: Ben Kaduk Date: Mon Mar 22 22:35:51 2010 -0400 Catch up to dynamically-sized cr_groups in FBSD80 In FreeBSD 8.0 and later, (struct ucred)->cr_groups is a pointer to a dynamically-allocated array, and NGROUPS is now 1024 by default (tuneable at boot). Don't put a gid_t[NGROUPS] on the stack for the FBSD80_ENV case. Also avoid keeping a function-local ucred structure (in afs_osi_proc2cred()), by bypassing that function entirely (though this accesses the process credentials directly, which may require locking; thread credentials accesses can be safely done lock-free). Add an osi_Panic() to ensure that it stays that way. Don't pretend that we have a useful afs_osi_cred to export. Don't blindly overwrite NGROUPS past cr_groups. Change-Id: I76295164a24bddf2782ab2fa662acd0e1b4855d6 Reviewed-on: http://gerrit.openafs.org/1665 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 326ff2aa68082a804ffef7fb1187a26962be924e Author: Davor Ocelic Date: Wed Mar 24 22:45:20 2010 +0100 Initial; add state_analyzer manpage Change-Id: I5dd43e6ea5764421a6e44f372f4e9c9576de627e Reviewed-on: http://gerrit.openafs.org/1655 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5d5da6eb4d5db9323ad0b89417d17ea577a0eb98 Author: Jeffrey Altman Date: Sat Mar 27 16:13:27 2010 -0400 Windows: buffers whose offsets are beyond EOF should be zero filled and locally allocated When a buffer is being allocated for an offset that exceeds the file length as known to the file server, that buffer should be zero filled and it does not require server validation. Previously all buffers were populated with a FetchData call. This is wasteful of time and server resources when there is a valid callback registration because the serverLength is known to be valid. LICENSE MIT Change-Id: I13f9a8dbd6387c3ba71638a682e995d7a7d0862f Reviewed-on: http://gerrit.openafs.org/1664 Tested-by: Jeffrey Altman Tested-by: Asanka Herath Reviewed-by: Asanka Herath Reviewed-by: Jeffrey Altman commit 1bb3522983ec7ee8e99ca28bb744601f1c15837c Author: Claudio Bisegni Date: Wed Mar 24 23:27:05 2010 +0100 GUI Update for Kerberos Ticket Renew Now the NSEditText for Renew Time is replaced by NSStepper for Days:Hours:Minutes:Seconds Change-Id: If696f456faada6762def192ab0887539d55bc5d4 Reviewed-on: http://gerrit.openafs.org/1656 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5436264d0c1347e0f8ed8f650d5fc4cc4dd0dd71 Author: Derrick Brashear Date: Sat Mar 27 12:45:40 2010 -0400 aklog pt error table warning fix include the header file that prototypes the pt error table Change-Id: Ibd1a7cb04d8084a50d3a429fa69cfb2967874c9b Reviewed-on: http://gerrit.openafs.org/1663 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c44a69b3379a736274be3045d77d5946efa64869 Author: Derrick Brashear Date: Thu Mar 25 09:01:23 2010 -0400 aklog more error tables initialize the rest that we might need Change-Id: If4e02add67994ae5397c60de3e64c072c3512a2e Reviewed-on: http://gerrit.openafs.org/1661 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7d69cfbc20f1354b1dd9094b5ad496c8beaa5c58 Author: Chas Williams - CONTRACTOR Date: Thu Jan 7 18:35:37 2010 -0500 LINUX: you dont need to memset() after allocating credentials If you wanted to create a blank credential, you wouldn't want to make it uid = 0. Anyone allocating a credential SHOULD properly fill in all fields making this blanking operation moot. Regardless, this memset() is before the allocation failure test and would/could panic. Change-Id: Ia182a874a5e1bf28a2cd94898f67d81e5588d58c Reviewed-on: http://gerrit.openafs.org/1080 Tested-by: Simon Wilkinson Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4b3f3169cb89c80acc0cc70d51cf47ed32c22ab2 Author: Jeffrey Altman Date: Thu Mar 25 01:23:23 2010 -0400 Windows: afslogon.dll vs windows 7 In Windows 7 the GINA is no longer used. As a result, when a non-Heimdal realm is used for logon, the LogonDomain field is no longer populated during the NPLogonNotify call. Instead we must obtain the Kerberos realm from the UPN specified in the Username field. Change-Id: I838e0a5b19d560dd2fed6ccccf1e136fe1c4e0c2 Reviewed-on: http://gerrit.openafs.org/1660 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit fda5f9a37364b09ef0965d5512989f44aed880d7 Author: Jeffrey Altman Date: Thu Mar 25 00:40:29 2010 -0400 Windows: aklog must reset viceId to 0 before pr_CreateUser call If the viceId is not reset to 0, the ptserver believes the client is attempting to request the anonymous id value and fails the registration request with permission denied. LICENSE MIT Change-Id: I82cc6105ad9d08b2f460b0c08cf7de500cea8537 Reviewed-on: http://gerrit.openafs.org/1659 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 114ed05d8d163eed1622750dc024c69a513bc9d8 Author: Jeffrey Altman Date: Wed Mar 24 22:07:29 2010 -0400 Windows: output pt error messages as strings Build and link in ptserver/pterror.c so that aklog can output pt error messages as strings. LICENSE MIT Change-Id: I93d966e0e62bb693612c6310781aadbfa6c09988 Reviewed-on: http://gerrit.openafs.org/1658 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit af415156080a979b30375f11482465e6cf7a1d91 Author: Derrick Brashear Date: Wed Mar 24 14:49:11 2010 -0400 growl agent should handle port busy if the port can't be bound, die cleanly. FIXES 126812 Change-Id: I6523f18c2b5f5bacfbd11d08736b9af14fa666e2 Reviewed-on: http://gerrit.openafs.org/1651 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 37eeead346a6933e9d2af2d5da1cb8f9fcf311c1 Author: Derrick Brashear Date: Wed Mar 24 17:18:24 2010 -0400 avoid double-free cell name canonicalization if we free the cell name, so note it so we don't try again. FIXES 126813 Change-Id: I4149fac057c587123f6bf6da8a42a4cd5e590716 Reviewed-on: http://gerrit.openafs.org/1654 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 165bd14126ea4ec2cf6563f865ab9d6bd7477d77 Author: Simon Wilkinson Date: Wed Mar 24 16:48:35 2010 +0000 Linux : Apply more dget_parent() pixie dust Replace another dentry->d_parent->d_inode lookup with a dget_parent() - accessing d_parent directly is potentially racy. Change-Id: I2c21cd6ef5c1b4b601c830836590705b397915e4 Reviewed-on: http://gerrit.openafs.org/1647 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 81e03e005aa73ba6c58e3aadfea91e685df1ece3 Author: Derrick Brashear Date: Wed Mar 24 12:54:30 2010 -0400 afsdump warning killing a couple legit bugs here but mostly i used my parentheses shaker. Change-Id: I645a239ca584fbb5759d885d42c058c757a35731 Reviewed-on: http://gerrit.openafs.org/1648 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6fc97184468348187675f723f79ebb32433d25d2 Author: Derrick Brashear Date: Wed Mar 24 00:19:56 2010 -0400 make 1.5.73 relnotes release notes for 1.5.73 Change-Id: I4fd8d0b40f97311f42ee77f9245bd9e9cb87188f Reviewed-on: http://gerrit.openafs.org/1642 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e4dfa3a48228f7d465c406831ad0d7eaa31bd5e2 Author: Derrick Brashear Date: Mon Mar 22 23:44:52 2010 -0400 openafs 1.5.73 version strings make windows and unix 1.5.73 Change-Id: Ice7fb6bab06ab6b5a1e6d5309f13d242289d2b0a Reviewed-on: http://gerrit.openafs.org/1620 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit fc145e7162ef5b2280f25840c8bcb5649bdafa72 Author: Booker Bense Date: Fri Mar 5 10:11:41 2010 -0500 Updating UserGuide with Kerberos v5 authentication This patchset contains updates to the OpenAFS UserGuide that explains how to authentication OpenAFS using kinit/aklog and uses language describing Kerberos outside the context of the kaserver. References to applications such as telnet have been replaced with more modern equivalents such as ssh. Change-Id: Ifae779b04a26beb9be9cf58b450958acdc477c06 Reviewed-on: http://gerrit.openafs.org/1521 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 37f3aabd9f6f41dd722014ace146014b1340c0a1 Author: Asanka Herath Date: Fri Mar 19 22:13:41 2010 -0400 Windows: Use a timestamp for the minidump filename Set the name of the minidump file to : %TMP%\afsd---
-__.dmp This prevents new minidump files from overwriting older ones. Change-Id: I057963bedf618eb23720f17d62c8473790569273 Reviewed-on: http://gerrit.openafs.org/1633 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 1146d25df63cbf90b4a31e001227f5bd59acd6ea Author: Asanka Herath Date: Thu Mar 18 21:13:35 2010 -0400 Windows: Monitor requests and gather diagnostics before a timeout This patch monitors SMB requests that are being serviced and automatically enables logging if a request takes longer than one minute to complete. If the requst hasn't completed by the two minute mark, the code generates a minidump. Once a minimump is generated, no more minidumps will be produced for another 5 minutes. SMB monitoring can be enabled/disabled using the new registry parameter 'SMBRequestMonitor.' Change-Id: I5aae22f6bfa635cec4a803089b483698641080eb Reviewed-on: http://gerrit.openafs.org/1632 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 7ca634f7f8bf63ff62a5aed24c6251d4e7ee774b Author: Derrick Brashear Date: Tue Mar 23 21:49:26 2010 -0400 add missed release notes these are the release notes available via the web but not here. Change-Id: Ieb4af99a4d6a1dfdaabccdac79d03f7d328de675 Reviewed-on: http://gerrit.openafs.org/1641 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 766c7e4cdf10f040304a7141cc126cd4d4a321ed Author: Jeffrey Altman Date: Tue Mar 23 18:01:45 2010 -0400 Windows: changelog for 1.5.73 Change-Id: I83ab533c7ec52b82e76a857f3ac4a12e1d8b1939 Reviewed-on: http://gerrit.openafs.org/1636 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 58990545c12b0ebf746b8c8cd6a21993f5b1e9f0 Author: Jeffrey Altman Date: Tue Mar 23 19:00:27 2010 -0400 Windows: cm_attrs_t requires inclusion of cm_vnodeops.h Include cm_vnodeops.h before reference to cm_attrs_t. LICENSE MIT Change-Id: Ic6d2a505d4f30c75d16d5c99eef306af7563ba4c Reviewed-on: http://gerrit.openafs.org/1639 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 88305c306530bb17cd850f9a2582f83ba8ff7fb3 Author: Jeffrey Altman Date: Tue Mar 23 18:57:19 2010 -0400 Windows LWP and UNIX LWP do not have the same lwp_cpptr structure Windows LWP uses Windows Fibers. There is no 'stack' field. Change-Id: I8ebc7b355642f9e3ad6f2953345b9858ab9c151a Reviewed-on: http://gerrit.openafs.org/1638 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 7f1441b9e64bac9931abeffca4b37a9d8d8565eb Author: Marc Dionne Date: Tue Mar 23 18:36:17 2010 -0400 Warning fix: print burstWait fields burstWait is a struct clock with two int fields, but we try to print it as a %u. Print the fields separately like we do for timeout. Change-Id: I42ab3e4557af96cacae00b89841b1fcdfa832d4b Reviewed-on: http://gerrit.openafs.org/1637 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 71b3dd155cc958ae818cc37b96c976a2965e2640 Author: Marc Dionne Date: Tue Mar 23 17:49:22 2010 -0400 Fix #ifdef typo Fix ifdef typo. The compiler complains that the variable is undefined. Not sure what effect this may have had on the intended preprocessor output. Change-Id: Idef3f4ac42a96a096be25d31ff416f7a23560d70 Reviewed-on: http://gerrit.openafs.org/1635 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b835b487377304338ce97e82b8541eb3ab7c511d Author: Marc Dionne Date: Tue Mar 23 17:32:11 2010 -0400 Define __USE_XOPEN conditionally Only define __USE_XOPEN if not already defined. In this part of the code it might now already be defined since we enabled AC_USE_SYSTEM_EXTENSIONS. Change-Id: I0651658d82550ee9be593d281bf50205815f9ef7 Reviewed-on: http://gerrit.openafs.org/1634 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b0a3d581a6cd20f3ac77212685b1645431bcb7ef Author: Asanka Herath Date: Sat Mar 20 16:46:05 2010 -0400 Windows: Make default mode bits configurable Mode bits aren't directly exposed by the Win32 API. We were leaving them to default to 0777 when creating new files and directories. This patch introduces two configuration parameters; 'UnixModeFileDefault' and 'UnixModeDirDefault' which are DWORD registry entries that are used to set the initial mode bits. If the values are set to 0, then the behavior is identical to what we had before. Change-Id: I7822141aab1e12cc8e151be771f779284fa68465 Reviewed-on: http://gerrit.openafs.org/1602 Reviewed-by: Derrick Brashear Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit afa12e265dbf4c7dd83b85b2b6f532992da46e5f Author: Derrick Brashear Date: Tue Mar 23 16:06:38 2010 -0400 remove vnop needs discon lock right now, the discon lock never happens over a remove. fix that. restructure the code to allow one unlock and exit. Change-Id: I88fefa30c9ba8ad4a4ccce1a5b02e9fb8403b99d Reviewed-on: http://gerrit.openafs.org/1629 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 464b99b8ffa4ee8c7a33cd34609ba2f6885f6b01 Author: Claudio Bisegni Date: Mon Mar 22 23:35:22 2010 +0100 Develop Kerberos renew system for ticket - In Preference pane has been added a tab called "Option" where are showned the option for kerberos renew - In AfsBackgrounder has been implemented the NSTimer that will call the krb5 renew action according to user preference value Change-Id: Ica4b705018722488613ac09586e60c69303d1076 Change-Id: I79ce1334d99f926544e865fbb563a1ffecaa969c Reviewed-on: http://gerrit.openafs.org/1606 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6f52f9493a99974b88b7526287c8e291786e52b8 Author: Derrick Brashear Date: Tue Mar 23 16:53:31 2010 -0400 kill MultiBreakVolumeCallBack too this is also now unused. kill it. Change-Id: Ie2f3edef4dc74ee874eb5aedaf2c0d2ee548ae6d Reviewed-on: http://gerrit.openafs.org/1631 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 368e07f7367252d8877e86b3a3df9c559622e90e Author: Andrew Deason Date: Tue Mar 23 14:27:28 2010 -0500 Remove BreakVolumeCallBacks prototype BreakVolumeCallBacks was a dead function that was removed from viced. Remove the prototype for it. Change-Id: I12a4d69719163d3e7be7dcae6f39df17b245c807 Reviewed-on: http://gerrit.openafs.org/1628 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6448d4edc8fc7e8ca581f608e2b98a257bd20251 Author: Andrew Deason Date: Tue Mar 9 14:48:36 2010 -0600 vos: correct syncvldb -verbose server byte order 'vos syncvldb -verbose' outputs the before/after VLDB entries for altered entries, but the 'after' output shows server addresses in NBO. EnumerateEntry expects server IPs to be in NBO, so correct one location where they were passed in HBO. Change-Id: I332fe83b45b2b595e091c8eb9bdc57d89d5e36a8 Reviewed-on: http://gerrit.openafs.org/1550 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 189a99e8944c338ec57168cb88f6c700abbc2370 Author: Russ Allbery Date: Thu Mar 18 13:18:27 2010 -0700 vldb_check man page should say -vheader, not -pheader The option was given correctly in SYNOPSIS but not in the OPTIONS section. Thanks, Rod Widdowson. FIXES 126771 Change-Id: Ibd9694c066b6750ad04273c22e66c84fb7b4a1c6 Reviewed-on: http://gerrit.openafs.org/1589 Reviewed-by: Rod Widdowson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 51362aba7b22a44cb601fb5c7d8800d55cd4f7b6 Author: Derrick Brashear Date: Tue Mar 9 14:13:50 2010 -0500 make tryevalfakestat really not block turns out this VerifyVCache can end up hitting other lockers. move it out of the try path. Change-Id: I073318a44b4da519413905b677fd439f1edd6c54 Reviewed-on: http://gerrit.openafs.org/1547 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4d1bc8e9980660e2952a231e97a0dedd8596e86c Author: Derrick Brashear Date: Mon Feb 15 16:34:43 2010 -0500 viced remove dead BreakVolumeCallBacks function this is no longer used. trash it. Change-Id: I0ad5aa203924c6a16afd68bc8ef55663951917c3 Reviewed-on: http://gerrit.openafs.org/1315 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9af8d46e7794c323a69bed4a84dd73d5a8d05a8c Author: Andrew Deason Date: Wed Mar 10 14:15:58 2010 -0600 vos: Avoid LWP stack overflow error on SIGINT vsproc's method of longjmp'ing out of a signal handler can thoroughly confuse LWP. At the very least, the information on our stack becomes incorrect, since we're no longer using the stack supplied by LWP. At the very least, we seem to (almost) always fail the sanity check checking for stack overflow. To prevent the test from happening, NULL the stack pointer before the longjmp so we can attempt recovery. FIXES 33360 Change-Id: Ie910cb1cc8564ac119c3b751fd8295bf312a3ce7 Reviewed-on: http://gerrit.openafs.org/1559 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bf2d0db680f16394df6f0b9c4ee0c0738862276c Author: Andrew Deason Date: Wed Mar 10 11:58:04 2010 -0600 vos: Use IOMGR_SoftSig for signals When vsprocs tries to longjmp from the signal handler, use IOMGR_SoftSig first, so sleeping processes are woken back up. Without this, IOMGR can bail out since it finds no processes READY when we attempt to do anything with RX. Change-Id: I9089bc4d003786d4a2205cd97f722fbf85fd1aa8 Reviewed-on: http://gerrit.openafs.org/1558 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fe3ff8e91237f35fed33d6d417830e0fe44c6479 Author: Andrew Deason Date: Tue Mar 9 18:07:18 2010 -0600 vos: Mark longjmp-used variables as 'volatile' vsprocs tries to do error recovery by calling longjmp from a signal handler. Although this is quite error-prone since we call a ton of non-async-signal-safe functions, make it a bit more likely to work by marking variables that are used after the longjmp as volatile. This reduces how often (depending on the platform) these values will be completely worthless after a longjmp since they were cached in a register or similar. FIXES 125535 Change-Id: I8566f8cffde6cfdffd99a11d637645494e0a0514 Reviewed-on: http://gerrit.openafs.org/1557 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f2db78a346112f5320efc6f0b6b9fe4ae0d893d3 Author: Russ Allbery Date: Mon Mar 22 15:00:39 2010 -0700 Fix strict aliasing problems or add -fno-strict-aliasing Create a new CFLAGS_NOSTRICT Autoconf substitution variable which is set to -fno-strict-aliasing if we're using gcc to compile. Add @CFLAGS_NOSTRICT@ to the C compiler flags for source files that have significant strict-aliasing issues. Fix minor strict-aliasing issues elsewhere in the tree by using memcpy to copy the data into a properly typed variable. Change-Id: I43afdb5e33e06cb249b7db385a65daf8d2133a19 Reviewed-on: http://gerrit.openafs.org/1617 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 129b6954a6f491c6f3c3e417055bdc68d4726408 Author: Andrew Deason Date: Mon Mar 15 12:41:11 2010 -0500 Use AC_USE_SYSTEM_EXTENSIONS Instead of defining various symbols like _XOPEN_SOURCE, _BSD_SOURCE, and the like, just use autoconf's AC_USE_SYSTEM_EXTENSIONS to define all of the appropriate symbols for us. Deal with some fallout by removing some of the existing defines. Change-Id: I1c1968c89cc2dfda1293fd2566dac8e266325a72 Reviewed-on: http://gerrit.openafs.org/1582 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ac85550c9008baeba5cfdb400afb660fa85b6917 Author: Derrick Brashear Date: Thu Mar 18 20:17:02 2010 -0400 aix mount failure unlock and seterror set an error usefully and drop the vfs lock Change-Id: I9d901b50722c09e1b131077f0b19e2831e6a44c8 Reviewed-on: http://gerrit.openafs.org/1590 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 42a3eaae931e209377f765d736e64a802b5e9731 Author: Derrick Brashear Date: Wed Feb 24 14:16:48 2010 -0500 update link order librx needs libsys on irix to get afs_syscall libsys needs librx for xdr_mumble for rmtsys Change-Id: I2e4d9771807546c14f8b16b8805c222d79aab8c1 Reviewed-on: http://gerrit.openafs.org/1386 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 7293ddf325b149cae60d3abe7199d08f196bd2b9 Author: Simon Wilkinson Date: Thu Feb 18 00:04:22 2010 +0000 XDR: Stop the madness We currently attempt to align our XDR implementation with what may be provided by the host system. This leads to a huge amount of parameter fudging, and general pain and misfortune. However, the only place that we still actually use the system XDR is for UKERNEL builds. Change this so that we use our XDR everywhere. Fix all of our type and function definitions so that they're standard. Remove the warning inhibitions. Change-Id: I53f4539e50eacb4e0691d8d3d6546bbfb7438358 Reviewed-on: http://gerrit.openafs.org/1340 Reviewed-by: Chaz Chandler Tested-by: Chaz Chandler Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Reviewed-by: Simon Wilkinson commit 162cf1c51d167c43da49539c3956f5b94ba3c5e3 Author: Russ Allbery Date: Mon Mar 22 12:56:09 2010 -0700 Use sigset_t and sigfillset instead of memset Rather than using an arbitrary array memset to ones as our signal mask, use the POSIX sigfillset function and eliminate the static variable. Fixes strict aliasing errors with --enable-checking and gcc 4.4.3 on Linux x86. Change-Id: Ic3e0499d03657d94f60808ed12e090dc62cce6fc Reviewed-on: http://gerrit.openafs.org/1616 Tested-by: Russ Allbery Reviewed-by: Andrew Deason Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9dbe48ac2d14742d2acefb9cb4138b810a1a128e Author: Russ Allbery Date: Mon Mar 22 12:42:48 2010 -0700 Move non-executable stack assembly code to end of file The non-executable stack annotation used for Linux works by adding an additional section to the generated object. The annotation added in 9bfd03d723a9cf17673f40513a7adde1d503bcbc was added to the beginning of each assembly file. This caused build failures on Linux s390 because the remainder of the assembly code was then put in that section, which was discarded during linking. Add the annotation to the end of each assembly file instead, following the instructions at: http://www.gentoo.org/proj/en/hardened/gnu-stack.xml Change-Id: I5bd2d8d0ac31932b59757dcec0a942c459d61cac Reviewed-on: http://gerrit.openafs.org/1615 Tested-by: Russ Allbery Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 393820794c45b72a530b30bfd96aac982310eb7e Author: Derrick Brashear Date: Sat Mar 20 10:59:20 2010 -0400 multibreak callbacks add host marking to deal with refcounts, we have to mark hosts in a way other than holds. do so. all other h_Enum callers don't use this feature. FIXES 126497 Change-Id: I0fc008495b93d2c361d476c7fcb6b355c0dab825 Change-Id: I61128261b2e8c64fafbf7425d6a65dd48fd7e177 Reviewed-on: http://gerrit.openafs.org/1599 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a724dc31d85b082d7337dd0fa399df72dc5d9afc Author: Derrick Brashear Date: Sun Mar 21 13:49:21 2010 -0400 salvage variable initialization root vnode creation change caused a new warning i missed. fix it now, set rootvnode to NULL Change-Id: I06fe7a60f2fcc48c498249142220f65291188baa Reviewed-on: http://gerrit.openafs.org/1610 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 38fd7259202d098fe7b142438fddc0b5270efa50 Author: Derrick Brashear Date: Sun Mar 21 13:48:48 2010 -0400 aix vfs table entry in rc script add an entry to the aix vfs table so umount works Change-Id: I29a27ca350b948da0283ae09df0acd30eb6384c4 Reviewed-on: http://gerrit.openafs.org/1611 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 32ebc44f42aad7dd77d42d07bfd891e8be6f1fff Author: Andrew Deason Date: Wed Feb 3 13:02:23 2010 -0600 Create missing root directory when ORPH_ATTACH When we are salvaging with ORPH_ATTACH, orphans are normally attached to a volume's root directory. If the volume is missing a root directory, however, nothing is attached, and the volume can appear empty or unusable. So, to make it possible to get a useful volume out of a volume that lost (only) its root directory, create a new root dir, and attach orphans to that root. FIXES 94658 Change-Id: I946a60485b5793952707f44ac369ee243e8dc076 Reviewed-on: http://gerrit.openafs.org/1235 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 88a40ffd3b82f3ca1a1b2d57f32859a9d57b922e Author: Derrick Brashear Date: Sat Mar 20 10:40:32 2010 -0400 comment assumptions in lih0_r previously, we checked for (!held && !h_OtherHolds_r(host)) now, we want to confirm only we hold it, so comment that that's how this works Change-Id: I98a65fbb4f2d0532054c71699dc2168e4592668b Reviewed-on: http://gerrit.openafs.org/1598 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c9761464e7d8f1446862a3c94d900c74403b0f07 Author: Derrick Brashear Date: Sun Mar 21 12:49:34 2010 -0400 aix krb5 error message handling handle krb5 error messages for aix in aklog and lam plugin Change-Id: Iac96dc62e7889d375db111d5c96d86cf09715ab6 Reviewed-on: http://gerrit.openafs.org/1609 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a68104340b5d3768e533a7503deb068fdf06d72b Author: Derrick Brashear Date: Sun Mar 21 11:42:15 2010 -0400 panic prototype for aix 6 aix does need a prototype for the lame version of the function Change-Id: I636b734bb725c425b2b4c6e4ae3e9473e087c21d Reviewed-on: http://gerrit.openafs.org/1608 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c4537f0442ac7ecbf8c946de45004992e17d535f Author: Simon Wilkinson Date: Wed Mar 17 11:56:12 2010 +0000 Don't count root session keyrings against quota AFS PAM modules can call setpag() as root, regardless of the UID being authenticated. This leads to the session keyring being created using roots quota - on some systems (RHEL5) this quota is both small, and of a fixed size. Modify our keyring allocation code so that when a keyring is created by root, we don't do any quota checks. Change-Id: I2ee151ec1166a78475047bffd2c1d31f45e8dbdf Reported-by: Rainer Toebbicke Reviewed-on: http://gerrit.openafs.org/1577 Tested-by: Rainer Toebbicke Reviewed-by: Derrick Brashear commit e2134caed1812d523dc7c07a5307fd3ec53485f5 Author: Derrick Brashear Date: Thu Mar 18 15:27:35 2010 -0400 macos fsevents hinting add support for faking it. no exported interface exists, sadly. currently does only authentication events, and is best-effort only, however for people who get tokens after viewing directories in finder, this is a drastic improvement. also adds needed setting to afssettings plist FIXES 23781 Change-Id: I46d5a6cf103c30a2134decccc929e1ef85a26726 Reviewed-on: http://gerrit.openafs.org/451 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 65dcd0a7dabea704973d7f67c1733d2a47559f1b Author: Jeffrey Altman Date: Sat Mar 6 17:32:57 2010 -0500 afsadminutil: translate krb5 error messages on Windows util_AdminErrorCodeTranslate() is used to translate error code messages within the libadmin library set and is used by translate_et. This has in the past not translated krb5 error codes. This patchset conditionally adds support for using krb5_get_error_message() or error_message() on the Windows platform if KFW is installed. This is accomplished by adding new functions to afsutil.lib: initialize_krb5() fetch_krb5_error_message() which are used within util_AdminErrorCodeTranslate() only if AFS_KRB5_ERROR_ENV is defined. Support for Unix is not provided at the present time because doing this "right" will lead to a dependence on kerberos libraries from this library, which we might want to avoid. Change-Id: I7caf7b8e41cfd806f4defc175aa45afb165ec244 Reviewed-on: http://gerrit.openafs.org/1531 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 7595adc20b9ae1807cf720c72917eb6d133c765f Author: Andrew Deason Date: Fri Mar 19 09:31:04 2010 -0500 volume_inline.h does not need sys/file.h src/vol/volume_inline.h does not need sys/file.h; at one point, it was using macros from sys/file.h for locking constants, but now we use the lwp/lock.h constants. So, include that instead. Also, only include it for DAFS, since we only use the constants in the DAFS case. Thanks, Jeffrey Altman. Change-Id: I114b438d7fb1fbb3a35bdfa0717ac334c7f80355 Reviewed-on: http://gerrit.openafs.org/1596 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman commit e55f39053a7a26648ad94fae7fa7eaf4e9fb0725 Author: Derrick Brashear Date: Fri Mar 19 01:13:26 2010 -0400 macos uninstall redux the rest of the uninstall changes. git add, sigh Change-Id: I69e4f4a870e08b1796b4546776e373f0a82e0e8e Reviewed-on: http://gerrit.openafs.org/1594 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9c39116015ffd53e532656146ab984c4294bdf65 Author: Derrick Brashear Date: Fri Mar 19 00:57:13 2010 -0400 update macos uninstaller make the uninstaller cope with the new receipts format and location FIXES 125634 Change-Id: I6cf0cd3e979a34115f391477657ec37f0c3d8faa Reviewed-on: http://gerrit.openafs.org/1593 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 105481d3348a93d33695fb705f9fa5c8af210e7e Author: Dan Hyde Date: Tue Feb 2 10:37:47 2010 -0500 VOL_LOCK needed when traversing DiskPartitionList VLockPartition sets VOL_LOCK, opens (perhaps creating) the lock file for a partition, and flock's it. VUnlockPartition, sets VOL_LOCK, and closes the lock file fd. VLockPartition is called from the salvager. Nothing ever calls VUnlockPartition. VPFullUnlock is called every 30 seconds, does NOT set VOL_LOCK, and happily closes any lock file fd it finds, breaking any lock set with flock. Other routines use the VOL_LOCK when traversing DiskPartitionList. Change-Id: I683547f574b1f760e72014f5d44ce3987f07b5df Reviewed-on: http://gerrit.openafs.org/1213 Reviewed-by: Dan Hyde Tested-by: Dan Hyde Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 028240329c09b6a311cb85736f41d75f7ee7a01f Author: Ben Kaduk Date: Wed Mar 17 01:55:41 2010 -0400 Catch up with FBSD80's removal of thread argument to VFS calls FreeBSD SVN rev 191990 removed the thread argument to filesystem-dependent VFS calls. Curthread is always assumed. There is a __FreeBSD_version bump that we could check if we felt like being precise, but FBSD80_ENV is probably good enough. Change-Id: I4534f01999b61eaeaa014c41473c693e6d432fef Reviewed-on: http://gerrit.openafs.org/1587 Reviewed-by: Derrick Brashear Tested-by: Benjamin Kaduk commit 4bcd24e190ae1a69e7acd60d2e74d5c5a9383e63 Author: Derrick Brashear Date: Mon Mar 15 13:15:34 2010 -0400 aix vnode hold simplification instead of special-casing aix's AFS_FAST_xxx *and* calling VREFCOUNT_INC for AIX, make it all consistent; side effect, remove now-superfluous AIX ifdef'd code Change-Id: Ic6a91429aad26e17fd9e12884ba0eba86564c377 Reviewed-on: http://gerrit.openafs.org/1572 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 46099b6d0b3f3ecec58b679518c9a267f71dfd49 Author: Derrick Brashear Date: Wed Mar 17 14:25:38 2010 -0400 regain glock on storedata error exit if we bomb out with EFBIG, we must regain the GLOCK before returing Change-Id: I3aec92f90abd665d86dcf413dad0e9cbb251a0af Reviewed-on: http://gerrit.openafs.org/1584 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit da68c39de16257b329f470c42c2d4cd8165340f6 Author: Derrick Brashear Date: Wed Mar 17 13:23:30 2010 -0400 kill apsl afssettings and fstab replace both afssettings with something patterned from webdav's (BSD-licensed) mount program with general plist reading code. the lists of valid oid objects of course have to be the same. eject old darwins. add the new one. fstab with something from freebsd umount Change-Id: I28f6765475314b9b78102c762daec19cda4988c3 Reviewed-on: http://gerrit.openafs.org/1583 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b772bd7e3c1305710eb3c18b2fe4108e467bd383 Author: Evan Broder Date: Tue Nov 3 23:50:39 2009 -0500 Increase the maximum number of sysnames Change-Id: I8438ca19649730260370d8b00fb0157e808abe31 Reviewed-on: http://gerrit.openafs.org/778 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3cffaee790feef2b80915e9a247e0d5c3c1948da Author: Andrew Deason Date: Fri Feb 19 17:13:01 2010 -0600 DAFS: Replace partition locks with volume locks In DAFS, replace uses of the VLockPartition_r partition-level locks with the approprivate VLockVolume*NB volume-level locks (and sometimes FSYNC_VerifyCheckout). This allows for greater parallelization of volserver attachment / volume creation, for volume operations to occur during salvages, and for multiple salvages on a single partition to occur simultaneously. More architectural details of volume-level locks can be found in the changes to doc/arch/dafs-overview.txt. Change-Id: I4e8ef4c864002d7e7c976691824c53dfa9cfaf91 Reviewed-on: http://gerrit.openafs.org/1406 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 57984286f3d96cb2dbf0038dbc67d2f3c069e22e Author: Andrew Deason Date: Fri Feb 19 17:02:08 2010 -0600 Add code for locking individual volumes on disk This adds the necessary APIs and associated changes to lock (on disk) an individual volume on a particular partition. Nothing yet calls these new functions. Change-Id: Ibfa00293e7411f3f48eabdecb13b7e80e126a1ff Reviewed-on: http://gerrit.openafs.org/1405 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e42e0912d774cbfc309250052631c6e60c83164d Author: Ben Kaduk Date: Tue Mar 16 17:07:04 2010 -0400 Avoid panic on shutdown with memcache and INVARIANTS When running with memcache, the filesystem cache is not initialized, so the file-local struct vnode *volumeVnode is never set to non-NULL. However, shutdown_cache() unconditionally calls vrele(volumeVnode), which triggers a KASSERT that the argument to vrele() is non-NULL. For certain kernel configurations, this results in a panic. Change this so that vrele() is only conditionally called if the volumeVnode is non-NULL. Change-Id: I80235f0d45ae11f26e9a09854bb34439f89bbb40 Reviewed-on: http://gerrit.openafs.org/1576 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c9a4e11bbac143f7e44af4eb1e6fae1653679e33 Author: Ben Kaduk Date: Thu Mar 11 00:13:12 2010 -0500 Allocate and free backing store for event mutices Actually get memory for the event mutex. With this and a locking tweak, afsd actually starts (with memcache; the UFS cache still has some locking issues). Note that struct mtx is small enough that we may want to just include it inline in afs_event_t and avoid having to do a separate allocation/free step. However, Derrick wants to merge the FBSD and DARWIN versions of this file, so stick with the more compatible version for now. I find that without the memset(), mtx_init() will (sometimes?) complain that the mutex is already initialized. The glock should ensure serialization here, though, so that we only allocate and initialize one mutex per event. Also remove an unnecessary cast while here. Change-Id: Ib304f4301a478a82f0fb8c9ae3bfee98a2a28acd Reviewed-on: http://gerrit.openafs.org/1560 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d9cf88428aa542d1cd304e82f02333eced0194ae Author: Derrick Brashear Date: Mon Mar 15 14:31:49 2010 -0400 rx nat event connection reference hold a conn ref for the nat ping event. don't renew if the connection is being garbage-collected. Change-Id: I45ebf7b8d0362e409094666f186e6b4d58cc906a Reviewed-on: http://gerrit.openafs.org/1573 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit be2c1ea5ef4a7afb315c2220c4de4b73cfb10894 Author: Marc Dionne Date: Mon Mar 15 21:34:28 2010 -0400 growlagent: remove generated Makefile with make distclean Add the growlagent Makefile to the list that gets cleaned with the distclean target. Change-Id: I6c3385f3b839c436efb50d0fc7239c181e027be6 Reviewed-on: http://gerrit.openafs.org/1575 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8ba939e12636d573404d2777505a61608a4f3bd8 Author: Antoine Verheijen Date: Mon Mar 15 13:49:31 2010 -0600 Remove return of value for afs_MarinerLogFetch() afs_MarinerLogFetch(), a void routine, attempts to return a value. While gcc (amongst others) merely issues a warning about this, the Sun Studio C compiler gets cranky (at least on x86) and treats it as a hard error, thereby aborting the build. Since there actually is no value to return, this update simply removes the attempt. Change-Id: Ic89fb05380a25a433f9c3b9fa57962f215348d95 Reviewed-on: http://gerrit.openafs.org/1574 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6bfca9c06c1ddcf2cb238a821463dce91e4f2146 Author: Derrick Brashear Date: Wed Mar 10 02:03:25 2010 -0500 freebsd per-event mutexes use the same system for event mutexes macos does. this time for sure. Change-Id: I18be653607490ba42f40a0b069460ece2f6ab416 Change-Id: I7e0a2f6042ef7f31612072c6625579de42b17f9b Reviewed-on: http://gerrit.openafs.org/1554 Reviewed-by: Benjamin Kaduk Tested-by: Benjamin Kaduk Reviewed-by: Derrick Brashear commit 19670781ba6d3d9258786319e98003e7afd887df Author: Andrew Deason Date: Tue Feb 9 13:03:06 2010 -0600 vlserver: make rxinfo threadsafe The vlserver has a function 'rxinfo' used for printing out information about an RX call for logging purposes, which used a static string. Change it to use a caller-passed buffer, so it is safe to use in multiple threads. Change-Id: I186010792e743bc9676ddd5b4c99f011b64988e6 Reviewed-on: http://gerrit.openafs.org/1545 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Reviewed-by: Dan Hyde Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 81b7f1b010789cc6a345454c677e69bf2e5c8a3b Author: Derrick Brashear Date: Mon Mar 8 15:58:42 2010 -0500 afsdb lookup shouldn't leak memory on realname lookup when looking up the "real" cell name, avoid leaking memory. the strdup is inside a loop and would leak memory for each host returned above one. Change-Id: I36cc9bd27ddc831121f47046daaab11f752012fe Reviewed-on: http://gerrit.openafs.org/1538 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dfa356732fd10073c3b777ccf48f753fcd528c93 Author: Michael Meffie Date: Sun Feb 28 13:02:40 2010 -0500 squash warning in db_verify Fix warning from the prdb_verify -rebuild with supergroups fix, fa2536c02cf26f7db30bf623e95f42be88138d14 Change-Id: I584cba07287660c9e560a2ba931545cbc5b4843f Reviewed-on: http://gerrit.openafs.org/1570 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 808cebbf45101c512480350ce373ac95c08fa57b Author: Jeffrey Altman Date: Sat Mar 13 11:47:51 2010 -0500 Windows: warnings removal for afskfw.c Use StrSafe string manipulation functions in place of most instances of strcpy, strcat, sprintf, etc. With the use of StringCbCopy, StringCbCat, StringCbPrintf, etc. there is no longer a need to manually assign a NUL to the end of a C string buffer as was required with strncpy or strncat. There is one strcpy instance remaining due to the inability to know what the length of the destination buffer. The API needs to be altered to make the destlen available and that is not an appropriate change for this patchset. A deprecated warning is a reminder to revisit this in the future. Several int to unsigned int type changes to avoid signed vs unsigned warnings. Shuffle the order of header files to avoid macro redefinition warnings. LICENSE MIT Change-Id: I4b5d15b60918cc8dc6ab205f1a7d45e17d14de43 Reviewed-on: http://gerrit.openafs.org/1567 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 17f9444be39cb520efa09011f0f18db5b90e87f3 Author: Jeffrey Altman Date: Sat Mar 6 17:30:17 2010 -0500 Windows: afskfw - conditionalize use of krb5_get_error_message for KFW 3.1 and earlier KFW 3.1 is supported by OpenAFS but does not contain krb5_get_error_message or krb5_free_error_message. As a result it must be loaded at run-time and conditionally used. LICENSE MIT Change-Id: I803b4af726605dc49baf2c2d45fae3ecafe2ccf9 Reviewed-on: http://gerrit.openafs.org/1529 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit d4340c0da4574d61f25d7ebfba6afb352d1113bf Author: Jeffrey Altman Date: Sat Mar 6 17:32:22 2010 -0500 Windows: netidmgr - conditionalize use of krb5_get_error_message for KFW 3.1 and earlier KFW 3.1 is supported by OpenAFS but does not contain krb5_get_error_message or krb5_free_error_message. As a result it must be loaded at run-time and conditionally used. LICENSE MIT Change-Id: Ic2ad16bb5c2d905e30ec814951b5253e2ef888da Reviewed-on: http://gerrit.openafs.org/1530 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 5026d73c8624e3eb36908ce16cc2bb6509eb4e37 Author: Derrick Brashear Date: Thu Mar 11 12:10:38 2010 -0500 macos dropbox fix for finder sadly this can mean we lie and say delete will work when it will fail, but finder looks for KAUTH_VNODE_DELETE_CHILD along with KAUTH_VNODE_ADD_SUBDIRECTORY and KAUTH_VNODE_ADD_FILE, not as one-offs. Change-Id: I4079b89e188992ee33594cad5bd15f7bf6106203 Reviewed-on: http://gerrit.openafs.org/1561 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f1bfc6674e143a29ca6cc68621c22a6b8dd2cd36 Author: Derrick Brashear Date: Tue Mar 9 16:51:56 2010 -0500 dkms configure correctly push the correct configure options for dkms Change-Id: I18e33c693fa4c32e39cee08844312e67cb280443 Reviewed-on: http://gerrit.openafs.org/1551 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2d7e83dccc4c7c90221ece5bc5f46e0620068b03 Author: Andrew Deason Date: Wed Mar 10 10:16:04 2010 -0600 Squash pthreaded vos warnings Trying to build vos in src/tvolser can produce a warning, at least on amd64_linux26, since we cast to an int of the wrong size in SendFile and ReceiveFile. Use intptr_t like we do everywhere else instead. Change-Id: Ic624bf90ab7338b63f8177b762e1deddbe7fb73d Reviewed-on: http://gerrit.openafs.org/1556 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit d32b40ee7db535d36f4c167c7c3a2ea5855f6bf3 Author: Simon Wilkinson Date: Wed Mar 10 15:40:50 2010 +0000 Don't always use the local cell for db clients Commit d008089a79ef268bbca91d660a840f32cb416865 broke things so that we were always trying to use the local cell, rather than the one specified by the user. Fix this so that the command line cell is used, unles -localauth is specified, which restores the existing behaviour. FIXES 126716 Change-Id: I2ce34e764780d5a22c67474d5ae1076d52b04113 Reviewed-on: http://gerrit.openafs.org/1555 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 5383e6a330e45d3a2e6fb1ff0f80e4a50d2763ec Author: Simon Wilkinson Date: Tue Mar 9 22:17:05 2010 +0000 Update RPM CellServDB Update the CellServDB in the RPM packaging to 2010-02-28 Change-Id: I03d062a6c9b53edd6865932df5a93b42cd46e708 Reviewed-on: http://gerrit.openafs.org/1552 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 63fe055ecd13c93a3a6070a15a745ace2e420817 Author: Andrew Deason Date: Fri Mar 5 17:07:47 2010 -0600 udebug: Fix byte ordering of last yes host Udebug gets the last 'yes' host in HBO, but afs_inet_ntoa wants it in NBO. So convert it to NBO. Change-Id: I5524d8086d5ac08875306fee923cb297c971cda8 Reviewed-on: http://gerrit.openafs.org/1549 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 97b69af9255d2aca0f858588cc957c05690e387e Author: Andrew Deason Date: Tue Mar 9 11:43:42 2010 -0600 vldb_check: do not ntohl u_chars vldb_check was ntohl'ing fields like serverNumber when reading in a VL entry. Since this is a u_char, ntohl'ing will just always result in 0, not the actual value. Remove the ntohls so we read in VL data correctly. FIXES 126661 Change-Id: If5117e1750d6dacd9bbe18bc936e0a1ba3d44340 Reviewed-on: http://gerrit.openafs.org/1548 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 861cdf82de9f7fbaa28e87c5f26e97ddc30f3f9a Author: Andrew Deason Date: Fri Feb 19 17:04:29 2010 -0600 Add FSYNC_VerifyCheckout Add the function FSYNC_VerifyCheckout, which can be used to verify that a previous checkout of a volume is still known by the fileserver, and hasn't been forgotten about (by e.g. the fileserver restarting). Change-Id: Ie3ec63d155fe16ca4929b370bbe55850075cec83 Reviewed-on: http://gerrit.openafs.org/1404 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit aa8c114454f0825adcf03bd29377c052a3e4719a Author: Andrew Deason Date: Tue Feb 23 15:43:11 2010 -0600 Add DAFS documentation overview for developers Add some developer documentation for DAFS. This isn't comprehensive or extremely detailed, but is intended to provide a larger-picture overview of some of the pieces of DAFS. More detailed docs are intended to exist in source comments (doxygen and such), and should already be there for the most part. Change-Id: I167b52c3bfb9e6b4b7111b3548ca8b1dafe305ea Reviewed-on: http://gerrit.openafs.org/1376 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 797fe86a8e6f7b6306e9dc2c3de1432e5fcbc0c2 Author: Andrew Deason Date: Fri Feb 19 16:48:30 2010 -0600 Add VLockFileReinit Add a VLockFile function, VLockFileReinit, to close all locks on that particular lock file. Change-Id: Ie1e4af21a486fb0451b6d613117027a522c9bb5a Reviewed-on: http://gerrit.openafs.org/1358 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7d7e2f2af801b734c1cb7fd3f84be419ad851348 Author: Andrew Deason Date: Fri Feb 19 16:48:06 2010 -0600 VLockFile: add a couple of asserts Add a couple of asserts to make some mistakes very obvious, such as passing in an invalid 'locktype' or unlocking more times than locking. Change-Id: Ie6e707ea515d5a6527dedc8875f0a4694b7b93c9 Reviewed-on: http://gerrit.openafs.org/1357 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 9aa09f5e634db8a8b2dedf3a749f2a90ef206e2f Author: Andrew Deason Date: Fri Feb 19 15:17:56 2010 -0600 Schedule all salvages via VScheduleSalvage_r Change I03ecf6302436c35fec705cd6c84a40b7cdbf6f97 allowed non-fileserver programs to schedule salvages via FSSYNC, making the FSSYNC call directly in VRequestSalvage_r. This isn't as safe as making the call in VScheduleSalvage_r (as is done when the fileserver schedules a salvage via SALVSYNC), since we may not have relinquished all of our handles and such for the volume by the time the salvager starts. So instead, make this path a bit more like the fileserver, and make non-fileserver programs actually make the FSSYNC call in VScheduleSalvage_r. Consequently, make VScheduleSalvage_r conditionally hit FSSYNC or SALVSYNC. Add a VCheckSalvage to attach2 failures, so non-fileserver salvage requests actually get scheduled. Also, reorganize the attach2 error handling a bit to make this a bit easier. Change-Id: I786a7953e860a132575caad8fe12168f6841442b Reviewed-on: http://gerrit.openafs.org/1356 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b550276579f929512a5fa3cf1d9482df914f67be Author: Andrew Deason Date: Thu Feb 18 14:22:39 2010 -0600 Add FSSYNC debug logging Add logging for what FSSYNC commands are being received by the fileserver, so it is possible to see what's going on with FSSYNC. Log at level 125, since this isn't interesting unless you knows some FSSYNC details, and it can get quite verbose. Change-Id: Ia067d3ba5084a919332989aac437ae4d4082e2e4 Reviewed-on: http://gerrit.openafs.org/1349 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit faefa0dc8e40e9e4c81a30a6fe687173b3327725 Author: Andrew Deason Date: Wed Feb 24 09:47:03 2010 -0600 Move *SYNC string translation out of fssync-debug Move the routines for translating ProgramType codes, and SYNC command codes, response codes, etc out of fssync-debug, and into header files anyone can use. These routines are useful especially for SYNC-related debug or error logs. Change-Id: Idc5ffe0dd798a9f18ca733e94d0bb4d740ad0836 Reviewed-on: http://gerrit.openafs.org/1390 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e67e4405b713840dc4b4fec2337462948c55aa4f Author: Andrew Deason Date: Thu Feb 18 12:21:45 2010 -0600 Do not rely on vol header for V*VolumeHandles_r VCloseVolumeHandles_r and VReleaseVolumeHandles_r were using V_id to get the id of the volume; just use vp->hashid so we can call these even if we lack a header. Change-Id: I0f0bc0ae82a7b86135aebe194c79a223a6f25094 Reviewed-on: http://gerrit.openafs.org/1348 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 804a29034ffcabaf0009b3f41d4acd4f9ba0b056 Author: Derrick Brashear Date: Tue Mar 9 11:02:13 2010 -0500 darwin report kext load address also report unload. in event of panic after module is unloaded (which *shouldn't* happen but i have evidence it might) you can retcon where the module was Change-Id: I07f89d2393605c4b7cac853cbe09b5a4a52ea4cd Reviewed-on: http://gerrit.openafs.org/1544 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2724e9ee8544ad5bf598e6552ab9a42ed615aa88 Author: Ben Kaduk Date: Mon Mar 8 23:38:15 2010 -0500 Export prototypes for osi_fbsd_{alloc,free} for use in rx Include prototypes for osi_fbsd_alloc() and osi_fbsd_free() in osi_machdep.h, since afs_prototypes.h is not included when compiling the rx code. afs_osi_Alloc_NoSleep is #defined to be osi_fbsd_free, and is used in the rx code; if the prototype for the latter is not included, then int is assumed for all parameters and return values, which breaks the calling convention for 64-bit pointers. Change-Id: I3d7575525f159097d1f8ca9ecb22af9f27b63111 Reviewed-on: http://gerrit.openafs.org/1541 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0eb19d67f6848cd0216d079d66487b5c1b2a95fb Author: Ben Kaduk Date: Sat Mar 6 15:37:50 2010 -0500 Use correct types for UFS devices For the FreeBSD 5.3 release, UFS (and everything else) took a "dreaded s/dev_t/struct cdev */" change; we need to keep up with this when comparing mountpoints' devices. Change-Id: I47d3f874be05b16fc2da89dac2bb1b64c573ab8e Reviewed-on: http://gerrit.openafs.org/1540 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b6a3d7c9da9a0bfcd3e24698e083919ef72de768 Author: Ben Kaduk Date: Sat Mar 6 15:20:18 2010 -0500 Use the correct API for msleep() in FBSD's afs_osi_TimedSleep() msleep() does not take a struct timespec*, it takes its timeout value as a multiple of the kernel's HZ parameter (tuneable at startup). Since the afs_osi_TimedSleep interface is documented to take a timeout in milliseconds, we must correct for the (sometimes) different units (currently HZ defaults to 1000). We prefer to multiply the timeout by HZ before dividing by 1000 so as to not lose precision; overflow is assumed to be unlikely. Change-Id: Ic101f3bf54213eebe249cb6c40a6d8cbd3d722f0 Reviewed-on: http://gerrit.openafs.org/1539 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 430c68eb2ada1559c0b775e2e82cbf9c98a25b99 Author: Ben Kaduk Date: Sun Feb 28 17:07:15 2010 -0500 FBSD build finishes for me Declare the fd variable. Also a preprocessor tweak, as e2b65732 seems to have gotten the sense of the AFS_FBSD50_ENV check wrong. Change-Id: I7e498a8276586af5afe0483380d00ef83266c316 Reviewed-on: http://gerrit.openafs.org/1526 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 84eee2ed411cab64b136ccea3a6c29f1313e2ecc Author: Derrick Brashear Date: Mon Mar 8 14:06:50 2010 -0500 afsconf srv lookup fill cellname pull out the cellname from the reply Change-Id: I8e0dbb5b82e353ecd29a9cce25eaee1255062cd9 Reviewed-on: http://gerrit.openafs.org/1537 Tested-by: Derrick Brashear Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 7aca59c2f6c8097fbc0cafab18fe4cdfe28e89c2 Author: Antoine Verheijen Date: Wed Mar 3 11:57:29 2010 -0700 Begin support for OpenBSD 4.7 Add config param header and sysname number for OpenBSD 4.7 (currently in beta). Change-Id: I6537bd352becd9a8c3937e95f79911c8bc08bcfb Reviewed-on: http://gerrit.openafs.org/1533 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a31bbd3123dd7bd5c0f73c1bcd89548d489930a8 Author: Antoine Verheijen Date: Sun Mar 7 14:50:06 2010 -0500 OpenBSD: eliminate use of VREF() macro OpenBSD 4.7 (currently in beta) removes the (dummy) VREF() macro from the system header files. For at least as far back as OpenBSD 3.6, all this macro does is expand to a call to a system routine by the same name in lower case. This patch therefore replaces the single OpenBSD use of VREF() with a direct call to the routine to which it expanded. Change-Id: I44888ed1ba7ba8e7150202798def10bed2ab3158 Reviewed-on: http://gerrit.openafs.org/1532 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2f9df771bbe418b9d1a3797a844c6965d0c1325f Author: Ben Kaduk Date: Sat Mar 6 14:51:17 2010 -0500 Be type correct in osi_ThreadUnique() for FBSD Formerly, in AFS_FBSD50_ENV, we used curproc for the ThreadUnique value; however, curproc (#defined as curthread->td_proc) is a struct proc *, not an actual pid. (As such, it suffers from a 32/64-bit mismatch on 64-bit systems.) Use the correct value, curproc->p_pid, instead. Change-Id: If07ef3b0814c0fee63b62d2f36fa94d6e45573b9 Reviewed-on: http://gerrit.openafs.org/1528 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cb37b133d4f186c6325ea16ad01210fe45145492 Author: Ben Kaduk Date: Sun Feb 28 20:08:52 2010 -0500 FBSD module loads now Actually declare the global afs_global_owner, in afs_osi.c. This allows all symbols to resolve, so that the loader will accept the module. There are still significant issues, though. Change-Id: I705178cfa152f4ceaf59f008f53c1f62fb92826f Reviewed-on: http://gerrit.openafs.org/1527 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit db13984fb2dd2f882be36b7055d89c5e1c992021 Author: Jeffrey Altman Date: Fri Mar 5 09:49:12 2010 -0500 Windows: use krb5_get_error_message instead of error_message krb5_get_error_message() can return more descriptive errors based upon the context in which the error occurred by extracting the cached error message from the krb5_context. Since aklog has a krb5_context, use that instead of error_message(). Use GetProcAddress to load krb5_get_error_message and krb5_free_error_message function pointers because versions of KFW prior to 3.2 do not export them. LICENSE MIT Change-Id: I12043ec1890bcf0f4d9566f35bb1228e579c49fe Reviewed-on: http://gerrit.openafs.org/1520 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit d9410aba89c5a257635fa33dbd78db2c0cb32ac8 Author: Simon Wilkinson Date: Sat Mar 6 00:13:06 2010 +0000 Linux: Make keyring destructor remove all tokens The keyring destructor on Linux was only destroying the first unixuser structure found for the PAG being destroyed. In environments where each PAG contains tokens for multiple cells, this led to us leaking unixuser structures, and eventually grinding to a hault due to the length of the resulting hash chains (and some horrific O(n-squared) performance in the PAG statistics code). Add a utility function for the keyring destruction function to call which will mark as deleted all unixuser structures for a particular PAG, and use it. Change-Id: I355465c43cc2cf9d70f613d6f97cd65552260157 Cc: Eric.Hagberg@morganstanley.com Reviewed-on: http://gerrit.openafs.org/1524 Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit b7b0b4dea74e829ce0e36edd87a881a6f11df472 Author: Simon Wilkinson Date: Sat Mar 6 11:21:06 2010 +0000 Linux: Fix builds on RHEL4 RHEL4 has a very old 2.6 kernel (2.6.9), which predates the start of the Linux git tree. When I started using page_offset, I mistakenly assumed that everything in the initial commit to that tree was available in all 2.6 versions we care about. That isn't the case, sadly. Secondly, the new readpage code uses zero_user_segments, which has only been available in the mainline kernel since 2.6.25 (RHEL5 appears to have a backport) Implement local wrappers for both of these functions when configure can't find them in the kernel we're building for. These functions have been created independently of the Linux tree. page_offset is a copy of the code we used before we replaced it. zero_user_segments() is a first-principles implementation of the function (which zeros a pair of memory ranges within a single page) FIXES 126678 Change-Id: I622aec4d653567d5234e7a127b981e97468bbe7c Reviewed-on: http://gerrit.openafs.org/1525 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 80481fb14ea9301b0f6b3503d07ecaef39aef0d8 Author: Marc Dionne Date: Fri Mar 5 17:54:42 2010 -0500 Linux: replace invalidate_inode_pages This helper has been deprecated for a while, and gets removed with 2.6.34. Replace it with invalidate_remote_inode, which has been around for all of 2.6's life, according to Chaskiel in RT #124377. Change-Id: I8658b454e1c997c041f654ba55d06f713ea25459 Reviewed-on: http://gerrit.openafs.org/1523 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e4ac68692d7c5db84d9edfaa45c36440e4f98e4d Author: Jeffrey Altman Date: Fri Mar 5 09:47:43 2010 -0500 Windows: use krb5_get_error_message to translate krb5 errors in afskfw library Use krb5_get_error_message to translate krb5 errors to strings in the afskfw library. This provides error translations to afscreds and afslogon.dll. LICENSE MIT Change-Id: Idd4c15b3719be517a79947f6af52a4bdf50b1155 Reviewed-on: http://gerrit.openafs.org/1519 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 99875245107ba25c9a43210d8c123be379d7ce8f Author: Jeffrey Altman Date: Fri Mar 5 09:46:08 2010 -0500 Windows: use krb5_get_error_message in netidmgr_plugin Use krb5_get_error_message to translate krb5 error messages to strings. LICENSE MIT Change-Id: Ia2fd5d655e4b0fa894ce724d4c123d2df433bb32 Reviewed-on: http://gerrit.openafs.org/1518 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 198096887ba88b4ab6acf3bc5ef79399a16f8152 Author: Jeffrey Altman Date: Fri Mar 5 09:43:13 2010 -0500 Windows: Add krb5 error message functions to loadfuncs header Add krb5_get_error_message and krb5_free_error_message to loadfuncs-krb5.h so that they can be used in conjunction with LoadFuncs to obtain function pointers when available. LICENSE MIT Change-Id: Ice7c2f6384c480570fcec4810bd86f4d0c525227 Reviewed-on: http://gerrit.openafs.org/1517 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 03d529681c1e3fb2211250f0a75c52832a0712b9 Author: Jeffrey Altman Date: Thu Mar 4 16:23:36 2010 -0500 Windows: reset local mount point count during freelance re-initialization When a re-initialization is taking place, be sure to reset cm_noLocalMountPoints to 0 in case someone deletes the "Freelance" registry key out from underneath the service. LICENSE MIT Change-Id: I2c3edd0d617d8fb7d670036510ca2a22eece0e6d Reviewed-on: http://gerrit.openafs.org/1514 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit eaccbc942e6f82f4549dc6c4e5d30d27fe4b0c39 Author: Simon Wilkinson Date: Fri Mar 5 15:40:55 2010 +0000 Linux : Don't leak GLOCK when writing CellServDB Don't leak the GLOCK when we're iterating over the CellServDB in response to a read of /proc/fs/openafs/CellServDB Change-Id: I2ed08b9d7f93c7513b49708d009e8acaa478b5f8 Reviewed-on: http://gerrit.openafs.org/1522 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e49f42f2830945be940d28f145eab1db1d92d713 Author: Derrick Brashear Date: Thu Mar 4 16:07:14 2010 -0500 add growl agent for macos a userspace monitoring helper for mac users Change-Id: If81c0b9d2c7606e81f271465491f0a0eb5db62b3 Reviewed-on: http://gerrit.openafs.org/1513 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 08aec0182a888f38fa50ca4e1dbd9ed83e022a2a Author: Derrick Brashear Date: Thu Mar 4 14:16:04 2010 -0500 darwin afshelper fix startup check make the launchd check run as root without whining about passwords repeatedly Change-Id: Ib4bac7c9ddf1837a8e86bf17a8a66b6ba1247272 Reviewed-on: http://gerrit.openafs.org/1511 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ee340811a6f225d1cc81f651530fb9bfc892e916 Author: Derrick Brashear Date: Thu Mar 4 12:23:14 2010 -0500 evalmount copy out volid for sure make sure we really have a volid and avoid dereferencing tvp if there's none Change-Id: Iec6e7cba4d43e2d9c9af296bd6a1574e290bd118 Reviewed-on: http://gerrit.openafs.org/1512 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 92428f6f59c872be1e8b57681a984362ef0d58ed Author: Derrick Brashear Date: Tue Mar 2 23:14:47 2010 -0500 macos shutdown consistent behavior on every other platform, we check for afs unmounted before allowing shutdown. do the same here. Change-Id: Ic8c287be3ae39ad2d2ecb633748813f7f07b16e3 Reviewed-on: http://gerrit.openafs.org/1507 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5faeff77b0c9f551cd6d36daa2cbc12a41d8508d Author: Derrick Brashear Date: Tue Mar 2 06:53:53 2010 -0500 add user warning facility via mariner for macos existing mariner clients treat fetch$ and store$ special and otherwise just blat out a string. use this to our advantage Change-Id: Ib218918abe6038a08af58ea58405b2856ba1da9f Reviewed-on: http://gerrit.openafs.org/1505 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 73ea71b2d37443edd0d86b819e0a43ab3cf26df9 Author: Derrick Brashear Date: Tue Mar 2 06:42:41 2010 -0500 support mariner messages sans vcache if a mariner message is passed in without a vcache, print it as-is Change-Id: I1791102826db3cde484e0809ba79d54f22220be1 Reviewed-on: http://gerrit.openafs.org/1504 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c0056a01d70e7fd14de97d9f37c847f2680a0f7a Author: Derrick Brashear Date: Tue Mar 2 06:36:02 2010 -0500 rewrite marinerlogfetching marinerlogfetching and marinerlog have a lot of code duplication. fix that. Change-Id: I52624ab8d1a6310c92a580990c45cc9313ea7a1c Reviewed-on: http://gerrit.openafs.org/1503 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 958f7a28303175c1b4fcf2605afd0d19918f53fe Author: Derrick Brashear Date: Tue Mar 2 06:28:52 2010 -0500 restore mariner storing message sometime after afs 3.3, the mariner log "storing" message was lost in code restructuring. restore it. Change-Id: I7832718973bf6378e643aea5391a0fd4940b5d3f Reviewed-on: http://gerrit.openafs.org/1502 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 73f0f34bd4b5c4335d721238d8072fb8c3eb8fa7 Author: Derrick Brashear Date: Tue Mar 2 06:14:19 2010 -0500 de-printf the cache manager put most printfs into either afs_warn or comment out entirely move a couple uprintfs to afs_warnuser (and allow them to trigger on macos) Change-Id: If67a09287fcfbe44cc76961dd59d2aad3299e887 Reviewed-on: http://gerrit.openafs.org/1501 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 5fae0f0b9afd2396458d3dd9496a90eebd0cc626 Author: Jason Edgecombe Date: Sat Feb 13 11:31:09 2010 -0500 Add a section on how to tune the AFS cache using xstat_cm_test The cache tuning section covers how to use xstat_cm_test to measure the cache miss percentage. LICENSE BSD Change-Id: I895dbbecd7e16d44e18fa65e5e1aa1da5c567a06 Reviewed-on: http://gerrit.openafs.org/1308 Tested-by: Jason Edgecombe Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 62bb20951e125274b29183f95481e7a519efe791 Author: Marc Dionne Date: Fri Feb 26 17:00:58 2010 -0500 Remove duplicate make targets in tubik, cleanup dependencies Eliminate a few duplicate targets in the tubik Makefile, and clean up some dependencies that could cause the same source file to be compiled by different threads simultaneously when building in parallel. At least on my current gcc this would consistently result in a gcc internal error. The duplicate targets generate make warnings. Change-Id: I807debae67c04b00a88ec798b966628e10c5f316 Reviewed-on: http://gerrit.openafs.org/1506 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f73145a3e4478a32d9a12266888b241a6c5a9dee Author: Derrick Brashear Date: Tue Mar 2 05:59:30 2010 -0500 darwin vfsops ansification kill off the old k&r prototypes in osi_vfsops.c Change-Id: Ifd9bb9bd7f303f0f05f0776bb94222c3b138e808 Reviewed-on: http://gerrit.openafs.org/1500 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cfa2f3bac1a6c04c026110c2cf2150750eb49ddc Author: Derrick Brashear Date: Tue Mar 2 05:54:12 2010 -0500 afs_util don't use printf afs_warn and printf are ideally not interchangeable. fix it. Change-Id: Ib1b064549ef723fcac61e5ad89abe53a8ad76a51 Reviewed-on: http://gerrit.openafs.org/1499 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ede82a2eb1c8180a117dbe78b3c42959f0efe0ec Author: Derrick Brashear Date: Sat Feb 27 15:30:06 2010 -0500 BOP_MOVE and userspace move EXDEV helper turns background daemons into afsdb helper-like processes, which can exit and do work. for macos, add BOP_MOVE and implement mv in afsd: (macos EXDEV move is cp+rm, literally) run cp + rm and pass the return back in. if it fails, just give the client the error it had already Change-Id: Ia0d5d49725f6aa28b5c58d0b7c61cc22329a3bc1 Reviewed-on: http://gerrit.openafs.org/1371 Tested-by: Derrick Brashear Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit b7b51cb22c56cb7304a9d6c9c9b12eaaa470db49 Author: Claudio Bisegni Date: Mon Mar 1 20:41:48 2010 +0100 OSXPreferencePane checkAfsStatusForStartup method modification for search /afs volume for determinate if afs is on has been transfered into checkAfsStatus. checkAfsStatusForStartup method is used to check when afs start axitn system startup. Anyway these are only workaround we must use osx api or afs api to make this job. Change-Id: If9be5a91418eccc0c58a69b566af140d619d3057 Reviewed-on: http://gerrit.openafs.org/1492 Reviewed-by: Claudio Bisegni Tested-by: Claudio Bisegni Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f0ce809181d19e865817200dab4fb8370bceeb59 Author: Derrick Brashear Date: Sat Feb 27 20:09:42 2010 -0500 macos prefs pane more reliable running indicator instead of grepping ps output, look for AFS in df output. not happy with this either but it's way more reliable. Change-Id: I73ff53bc1cc24c9484011a870546b6334ff66b49 Reviewed-on: http://gerrit.openafs.org/1410 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d2645b0ba07148926aeba319f33db048dce66a07 Author: Ben Kaduk Date: Sun Feb 28 16:42:22 2010 -0500 More help for the FBSD build Remove extra #endif that was introduced in 6c628445. Change-Id: I8c42bfb15aadacc2b7d5a1d07e70b1181fc2f65c Reviewed-on: http://gerrit.openafs.org/1491 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 19eeb297c8eb1df6267cd392e92e4b9afb1827cb Author: Ben Kaduk Date: Sun Feb 28 16:15:05 2010 -0500 Make build progress farther Add a prototype for afs_global_owner in the AFS_FBSD50_ENV case. Change-Id: Ie9104af3e02e08cc46c479ff56f9e09aa3603e74 Reviewed-on: http://gerrit.openafs.org/1490 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 375fdd4f866398a9d931408d0c40e6e782e291e1 Author: Marc Dionne Date: Sun Feb 28 11:08:11 2010 -0500 Don't pass NULL to strcmp A recent gcc update gives me a series of warnings from the NULL argument to strcmp. We should be passing an empty string instead of a NULL pointer. I suspect this was unintentional from a search/replace operation in commit 8229e668. Change-Id: I9677d80d32e5bd54ca1b560788a430c8cf40dae9 Reviewed-on: http://gerrit.openafs.org/1489 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8ade30f3f14cb88151f2f5f47f044831c9ccc0ae Author: Jeffrey Altman Date: Sat Feb 27 21:54:47 2010 -0500 Windows: rx lowlevel nat ping sha1 d24078658d183ea2e72e61c1888e9900bac0ec32 added support for a low-level nat ping using rx version replies. Export rx_SetConnSecondsUntilNatPing from afsrpc.dll. Add NatPingInterval registry value to HKLM\SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters to permit Nat Ping to be enabled. The default value is 0 seconds. Change-Id: I5122ea81e1a61934eba3c836632039c76f6c45e3 Reviewed-on: http://gerrit.openafs.org/1487 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 8b898af1b34054d18f8a33b4a9c608614fec15b5 Author: Derrick Brashear Date: Sat Feb 27 23:00:31 2010 -0500 magic mount parser fix parse vnodes from magic mount objects correctly Change-Id: Id46afa7e6b1fa260d56ce54c8bffe2662b7c447d Reviewed-on: http://gerrit.openafs.org/1488 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 42d3d08b2285812ded74856c8e7d8f8253c3cab6 Author: Derrick Brashear Date: Sat Feb 27 17:48:19 2010 -0500 macos prefs pane krb5 auth setup when we configure krb5-at-login, don't inadvertantly reorder the list. replace inline. FIXES 126628 Change-Id: I23de38dadeae6a01d6f97d84e7bb6d9e75e99510 Reviewed-on: http://gerrit.openafs.org/1408 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d459825b233a55d51e2218f2546e28eb12468316 Author: Derrick Brashear Date: Tue Feb 23 19:45:21 2010 -0500 irix syscall arg fix for rx rx uses the afs syscall to get network info in userspace. fix things to pass a useful set of args in Change-Id: I541f90d43ff79ba7a026832403d485b7738a53b8 Reviewed-on: http://gerrit.openafs.org/1379 Reviewed-by: Chaz Chandler Tested-by: Chaz Chandler Reviewed-by: Derrick Brashear commit fb79f1265826ae7eee6c70b62e9ef0caf3105958 Author: Derrick Brashear Date: Sat Feb 27 11:52:03 2010 -0500 institute afsdb dns lookup timeout if we can don't be willing to wait more than about an rx timeout period for afsdb retries. Change-Id: Idca642ff7abe6b9233c7501b0f06fd353567bb04 Reviewed-on: http://gerrit.openafs.org/1407 Tested-by: Derrick Brashear Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit d24078658d183ea2e72e61c1888e9900bac0ec32 Author: Derrick Brashear Date: Wed Feb 24 22:34:28 2010 -0500 rx lowlevel nat ping for rfc 4787, do a minimal impact nat ping. this uses an rx "version request" reply debug packet, which will simply be discarded by the receiver, to keep the port mapping open. Change-Id: Ic2180bfa5c467e33c72e3f19d62488bd6a2dc61a Reviewed-on: http://gerrit.openafs.org/1393 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 23e600ae10db87da1c112b313631fcdbbc89d697 Author: Andrew Deason Date: Thu Feb 18 11:36:10 2010 -0600 Convert ObtainSalvageLock to the VLockFile API Make ObtainSalvageLock use the VLockFile API, to consolidate platform-specific locking code, and to make it possible to acquire a shared lock on the salvage lock file. Create the ObtainSharedSalvageLock function to acquire such a lock. Change-Id: Ieadd77ac8d4030b31c48fff1c98712a6c95f93ad Reviewed-on: http://gerrit.openafs.org/1347 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b6408585b51322600460f0cbdf251a12a2391680 Author: Marc Dionne Date: Fri Feb 26 16:15:37 2010 -0500 Enable parallel build for tubik Allow tubik to benefit from parallel make. Change-Id: If4e7e1a603ef88f03bcc271ec6d742ba3387c61a Reviewed-on: http://gerrit.openafs.org/1402 Reviewed-by: Simon Wilkinson Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 00d56c519be35f690e4cf26eddc8143304d38bdd Author: Derrick Brashear Date: Wed Feb 24 00:57:23 2010 -0500 background daemon genericization previously only "just enough" of the background daemon request object was exposed. expose the rest of the generic pointers Change-Id: Ifcadf53675598bc102208700ff34a768474174ec Reviewed-on: http://gerrit.openafs.org/1384 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5b12214cef06758fee19a6e7afc4e461e7303574 Author: Derrick Brashear Date: Wed Feb 24 00:59:16 2010 -0500 hush another afsd warning we can't prototype call_syscall fully yet, but at least hush some warnings Change-Id: I4e5f77037700f82ebfa87bd4fee4f52a59e3479a Reviewed-on: http://gerrit.openafs.org/1385 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3d81e4c1f00735e5a8b0f4217f80e84a96ba91bf Author: Derrick Brashear Date: Thu Feb 25 16:58:31 2010 -0500 darwin vnops code cleanup simplify ifdef structure by moving code around. remove dead code and nonsensical code (darwin80 inside !darwin80) no actual code changes here Change-Id: Ifa7a5afa3bff731d73e7b4a5ee861c2cb48b71a3 Reviewed-on: http://gerrit.openafs.org/1382 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 518b3abb737fd02245c4400491388d15f5cb9e1f Author: Derrick Brashear Date: Wed Feb 24 00:30:28 2010 -0500 darwin afscall syscall should set retval because of how the ioctl based syscall works, passing back a real return value should be done this way, as it is for the other other afs syscall subcalls. matters for userspace handlers. Change-Id: I894b4bd633ce4823b1ce906861251fcbb3949af2 Reviewed-on: http://gerrit.openafs.org/1381 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 93e9964039a1b627f991e796495be49ea0b6fdb1 Author: Derrick Brashear Date: Thu Feb 25 16:52:02 2010 -0500 macos bulkstat cleanup after racing stats if someone else stats it before we finish, make sure we clean up after ourselves properly Change-Id: I4a7257a403cccb02a114c60f5bb340dba6bb16cb Reviewed-on: http://gerrit.openafs.org/1399 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 726e1e13ff93e2cc1ac21964dc8d906869e64406 Author: Rainer Toebbicke Date: Wed Feb 24 12:02:08 2010 +0100 Do not leak information on partial success in RXAFS_InlineBulkStatus Initialize all RXAFS_InlineBulkStatus return parameters in case portions remain unset on FetchStatus failures. Also ensure VolSync info is set even if the first FetchStatus fails. Change-Id: I8c502d25ef1362675fed2871dbd8c3c4e76af55b Reviewed-on: http://gerrit.openafs.org/1396 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 70c975728382557669d6f76b1b465efc54c3e216 Author: Derrick Brashear Date: Wed Feb 24 00:41:48 2010 -0500 correct magic vnode volumename parsing if /afs/.:mount/cell:volume:vnode is passed in, don't pass the :vnode into the volume id lookup Change-Id: If877b467cd37f06dcb090c34560bf76f8e4b0d10 Reviewed-on: http://gerrit.openafs.org/1383 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d1923139e6d0fbe00dcde483810e56abef8bf66b Author: Derrick Brashear Date: Wed Feb 24 00:19:20 2010 -0500 irix kill efs and start pruning pre-65 we haven't built on irix 6.4 in a while. likewise, no efs anymore. just remove the extra code Change-Id: I559f4bca5bf52f9a0344472ccf60b93751282a2b Reviewed-on: http://gerrit.openafs.org/1380 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 14ff060627f5c4b64121f9f7978966bc53486e18 Author: Derrick Brashear Date: Tue Feb 23 23:57:14 2010 -0500 irix cachemgr inode abstraction correction if the XFS function takes a dcache_id_t, pass that and not its child Change-Id: Ic68ae440be0df05320fe0a0b24e2ffa8e4de45b9 Reviewed-on: http://gerrit.openafs.org/1378 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8940eb9dcf79e803449eb437d1f7076ceddba021 Author: Derrick Brashear Date: Wed Feb 24 16:02:26 2010 -0500 freebsd initglock endif fix when initglock hit freebsd it was broken. fix it. make it obvious that such is being done Change-Id: Iac716302061be91a43f168c9a1fe56cdbbb4227d Reviewed-on: http://gerrit.openafs.org/1391 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 142883cae8de203822c8be4f975e691b57be2834 Author: Derrick Brashear Date: Wed Feb 24 11:13:23 2010 -0500 remove dropbox attribute leak fix change 6ec18461649d3e4f44b2476f886bcc480c456500, avoid leaking stat info, appears to have side effects on at least macos, crashing the system coreservicesd. revoke the change until the exact behavior we want is better understood. Change-Id: I2a270750f9cef5ac6ecf1144d86988f030f78efe Reviewed-on: http://gerrit.openafs.org/1388 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7f4a67b8f0e91f013c840fe15b9cd0e0fb672d36 Author: Andrew Deason Date: Thu Feb 18 11:52:33 2010 -0600 Make VLockFile not DAFS-specific The VLockFile API does not require DAFS functionality, so make it available to non-DAFS code, as well. Change-Id: I3d9bebb5d4034f0af739ccee37f64e2254be38cb Reviewed-on: http://gerrit.openafs.org/1346 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c43625d91bc104759666629e5a78dff7f74a14fd Author: Andrew Deason Date: Thu Feb 18 14:41:24 2010 -0600 VLockFile: init fd to INVALID_FD, not zero Zero is a valid file descriptor; initialize lockfile fd to INVALID_FD instead, so we know it's invalid. Change-Id: Iacb549ec4ed821763d20cb0e4f25882b4151bf3a Reviewed-on: http://gerrit.openafs.org/1345 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cbf5f6341c389b0ae85f797ee7c73ba430a8b8f1 Author: Andrew Deason Date: Thu Feb 18 11:42:27 2010 -0600 VLockFile: Do not close fd on lock failure When we fail to acquire a lock in _VLockFd, do not close the fd if we fail to acquire the lock for any reason, since VLockFile does that for us already. There also may be other locks on that file, and we clearly do not want to release them when just one lock fails. VLockFile takes care of the necessary refcounting and fd closing, so don't do it in _VLockFd too. Change-Id: I65f27837dad033e0e84faf4aa0fb71ff26feda83 Reviewed-on: http://gerrit.openafs.org/1344 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c5e5790661cebdf2b45c7218d238bf18af01f99c Author: Derrick Brashear Date: Mon Feb 15 16:12:44 2010 -0500 viced avoid global pruclient during acl ops acl_Internalize and acl_Externalize used the global pruclient use the ones we use elsewhere in viced FetchAcl/StoreAcl also Change-Id: Ia2b8d29035ed48a6aab8c9df243c9082bfacd201 Reviewed-on: http://gerrit.openafs.org/1314 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c7c742afa07d3056b153fbe2529d709804532f03 Author: Chaz Chandler Date: Tue Feb 23 17:20:39 2010 -0500 add limits.h to sysincludes.h on IRIX xdr_mem.c wasn't including limits.h on IRIX when KERNEL was declared, so i INT_MAX was undefined. this adds limits.h to sysincludes.h so it's included for all other places where it might be needed. Change-Id: I718f5bf4dc5d82e2ce74ecc30ab3bf5492b82e29 Reviewed-on: http://gerrit.openafs.org/1377 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 91e50aa81bdeecbdf351088b3b5510fe3c8e848e Author: Anders Kaseorg Date: Sat Feb 20 13:36:22 2010 -0500 Linux: autoconf.h is moving in 2.6.33 In 2.6.33, is moving to . Signed-off-by: Anders Kaseorg Change-Id: Ib97031728b89cf8e17581f3c425216ae4b5538ec Reviewed-on: http://gerrit.openafs.org/1351 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 660c7a3952f36fc892e12aa6b11eda3295b1416d Author: Anders Kaseorg Date: Sat Feb 20 13:28:59 2010 -0500 Linux: Use kbuild to check for UML is automatically included by kbuild; you aren’t supposed to include it directly. That breaks in 2.6.33 because is moving to . Signed-off-by: Anders Kaseorg Change-Id: I56c90dfe90ef72408620793fcd4e927ea3d8f468 Reviewed-on: http://gerrit.openafs.org/1350 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 99e704c791bbedd9aa3fc1a0feb9493b0eaefd7d Author: Anders Kaseorg Date: Sat Feb 20 20:52:06 2010 -0500 Adjust afs_lockctl to compensate for byte-range lock fixes As of commit 49b7bbdd3b45df694fadbef48f9ed99d9bfe07b9, l_len is no longer 1 less than it should be. Update afs_lockctl to expect this. Signed-off-by: Anders Kaseorg Change-Id: I3fb7665457d489e56564b14933795084a0958d6f Reviewed-on: http://gerrit.openafs.org/1353 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d3abbebcb0651c5d2c7a3094270fd4f86bea3c1e Author: Anders Kaseorg Date: Sat Feb 20 20:28:42 2010 -0500 Linux: Fix conversion of whole-file locks An overflow bug in commit 49b7bbdd3b45df694fadbef48f9ed99d9bfe07b9 caused whole-file locks to be treated as byte-range locks, which fail to be propagated to other machines. Fix this by setting l_len = 0 for locks that range to the end of the file. FIXES 126561 Change-Id: Ie2dc9d04f33559c73b3b86b64152c549b785f8ad Signed-off-by: Anders Kaseorg Reviewed-on: http://gerrit.openafs.org/1352 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2cd1335257f069d534603c755fa18c4ee2cb4b5e Author: Andrew Deason Date: Wed Jan 27 15:08:34 2010 -0600 Abstract /vicepX header traversal The code for examining all of the headers on a vice partition now exists in two places: the VGC scanner, and the salvager. Create the VWalkVolumeHeaders function that contains the common logic so it's in one place, and take a couple of function callbacks for the differences. Change-Id: I12c71b3344ffbd0b22ddf5418f9ff0509734f42b Reviewed-on: http://gerrit.openafs.org/1264 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit eb7d90fd0db68ea49ec1820adda599b5922c7de2 Author: Andrew Deason Date: Mon Feb 15 16:22:56 2010 -0600 Allow GetSomeSpace_r to select an optimal host Previously GetSomeSpace_r would never find an 'ideal' host for which to clear callbacks, since lih0_r and lih1_r required a non-NULL rock to do anything. Remove the requirement for the passed-in host rock to be non-NULL, and make lih*_r more threadsafe, by passing in a parameter struct for the rock. Also attempt to make the GSS_r code a bit more clear with some descriptive variable names and such. FIXES 126451 Change-Id: Id754f4fa4b830896c5b03fc7ba0906950991a3b7 Reviewed-on: http://gerrit.openafs.org/1317 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 380bd77c328d8d83a007cd97f6564fcb5b990a73 Author: Andrew Deason Date: Tue Feb 16 11:08:38 2010 -0600 h_TossStuff_r: make sure host does not go away When h_TossStuff_r h_NBLock_r's a host, it is not only possible for someone else to grab a hold on the host, but in theory it's also possible for someone to hold a host, release it, and for the host to be deleted again (assuming some callers hold HOSTDELETED hosts, which they should not be doing). To make this safety check a bit more robust, hold the host in h_TossStuff_r before h_NBLock_r'ing, to ensure that it does not go away while we're waiting for H_LOCK. Change-Id: I018a611143d6dccba79cc627803cce74aa830c77 Reviewed-on: http://gerrit.openafs.org/1330 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 1e731a22ae954900af036d1ade014a07418ae4ea Author: Derrick Brashear Date: Mon Feb 22 13:58:58 2010 -0500 analyze warning fix initialize variable. warnings caught this in the other compiler Change-Id: Iae2ae5c1aefe29603bbf5d9952f65b0119f4db9b Reviewed-on: http://gerrit.openafs.org/1363 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1e744d5e56106093924869924fffde3a9093d140 Author: Andrew Deason Date: Mon Feb 22 11:56:07 2010 -0600 Prevent deadlock if fs_stateSave panics fs_stateSave can call ShutDownAndCore(PANIC) if it detects host list corruption. Right now this will deadlock the shutdown thread, since we're still holding a read lock on the FS state when we do so, and ShutDownAndCore will attempt to acquire a write lock. Do two things to make this a bit better: -- Unlock the FS state before calling fs_stateSave, sine we're no longer looking at the FS state (the 'state' in fs_stateSave refers to the host list and callback lists, not the state locked by FS_STATE_*LOCK) -- If ShutDownAndCore detects that it was called inside of ShutDownAndCore, skip shutting down the volume and host packages, since they have already been shut down Change-Id: I24a994ff85a6d866a5800b777c0cf5ab2ba466e4 Reviewed-on: http://gerrit.openafs.org/1362 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b8c3c6add90ea3face9a16ff04a1024be3d8f32d Author: Andrew Deason Date: Fri Feb 12 17:44:31 2010 -0600 Check for HOSTDELETED before h_Hold_r A few places h_Hold_r a host and later drop and reacquire H_LOCK without checking if the hostFlags contains HOSTDELETED. This can cause a race with h_TossStuff_r where we later reference a host that is about to be freed or already has been freed. Add checks for HOSTDELETED in these places, and skip over the deleted hosts. FIXES 126454 Change-Id: I5a61831f5afdbc908b82e4cf63cf14a34a36e275 Reviewed-on: http://gerrit.openafs.org/1305 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4dfbbd34ce66c09593a0b1a88831ec0f36848fe8 Author: Andrew Deason Date: Fri Feb 12 16:30:44 2010 -0600 Correct the h_Enumerate_r hostList safety check Ide1e5aca7c2c4a4af3f62bc07821db694f2f9999 added safety checks for a few traversals through hostList, including the traversal in h_Enumerate_r. Unfortunately, h_Enumerate_r may not hold H_LOCK over its entire traversal (h_Release_r can drop and reacquire it), so the value of hostCount is not guaranteed to stay the same. A host may be deleted during the loop, or right near the end, decreasing hostCount to below our current running 'count' of hosts, triggering the panic unnecessarily. Also, we break out of the loop if the H_ENUMERATE_ISSET_BAIL test succeeds, making the panic also incorrectly trigger then. So instead, remember the value of hostCount, and ensure that we've actually exceeded that count in the post-loop check. Change-Id: I7c13bbf111b592df6860e5852807fa463c3ebd7e Reviewed-on: http://gerrit.openafs.org/1304 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 45aceee9842265fb0ccdb5e8f3f6d32c8d2b99ea Author: Andrew Deason Date: Mon Feb 15 10:55:33 2010 -0600 h_TossStuff_r: check held-ness after lock h_TossStuff_r checks if a host is held or locked by another thread before trying to delete the host. Unfortunately, it checks if it is locked before checking if it is held, and the lock check drops H_LOCK. Thus, another thread could hold the host while we don't have H_LOCK, and we could delete a host that is being held. Although it is a bug if any thread holds a host that is being deleted, some instances of this still exist, so make the check more robust. Reverse the order of the tests, so we detect if someone held the host while the lock check dropped H_LOCK. Also log when this happens, as it indicates a bug occurring. FIXES 126454 Change-Id: I8fa972c430e63fc46ca4fadcc3429173ac91a947 Reviewed-on: http://gerrit.openafs.org/1312 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 48908e2a932420fe67fe1065d55f7e458b5cd1c2 Author: Derrick Brashear Date: Mon Feb 22 12:15:15 2010 -0500 analyze paranoia don't pass a null pointer to FindVolume in case one shows up Change-Id: I76258d8f8ca18c536e3faa776df3e06005fe2bc2 Reviewed-on: http://gerrit.openafs.org/1360 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 01f42cad663cc860e451f694f973ca46f03289ff Author: Derrick Brashear Date: Sun Feb 21 17:15:26 2010 -0500 idledead client dont interrupt writes allowing failover is nonsensical, there's nothing to fail to. keep trying to write. if we want to change this, we need to handle it better than just this. Change-Id: Ibed4c63182f44ed9e659895e4868b4192d004688 Reviewed-on: http://gerrit.openafs.org/1355 Tested-by: Stephan Wiesand Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fa8601f9c579746d7247bdbe159fbd3affe8e3de Author: Rainer Toebbicke Date: Fri Feb 19 10:26:57 2010 +0100 Init ih_synced for new ihandle One small step towards a valgrind-tolerant universe: ih_synced indicates that an inode should be synced which better be deterministic. Change-Id: Id6a09a07c6f90c59445b82fdceeba3c905cbae7e Reviewed-on: http://gerrit.openafs.org/1343 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ae0e8fc066c6046052d82bf4df2800faccdd3fb2 Author: Marc Dionne Date: Thu Feb 18 21:20:20 2010 -0500 Avoid dprintf conflict Rename dprintf to afs_dprintf to avoid potential conflict with system headers on some platforms. Change-Id: I2aef6a55c00ddf8a312531cc1203b3baaca4cd73 Reviewed-on: http://gerrit.openafs.org/1342 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a9951410e1cb1a713f9d26a24d6b3cf485f94ac6 Author: Simon Wilkinson Date: Thu Feb 18 23:09:40 2010 +0000 Linux: bdi doesn't always have a name The 'name' element of the backing_dev_info structure is new in 2.6.32 - add yet another configure test, and #ifdef to protect our setting of it. Change-Id: I0a3e411e571e05771619381bf621d299482c695b Reviewed-on: http://gerrit.openafs.org/1341 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1b4f1648e925dab43cbad53c31d56be355de233a Author: Simon Wilkinson Date: Wed Feb 17 13:46:23 2010 +0000 Unix: Fix objdir builds Make some changes to the Unix build system so that object directory builds work again. In particular, change the way that we call xcodebuild on Darwin, so that source and binary can live in different places. Change-Id: Ib2ab6182deaf7f344603cb5618707d3f212a5b86 Reviewed-on: http://gerrit.openafs.org/1339 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 84167a86d407165a7b7007431f6cd0f95e7420d5 Author: Simon Wilkinson Date: Sun Feb 14 00:45:19 2010 +0000 Add xdrmem and xdrlen to shlib builds Another day, another set of forgotten build objects ... Change-Id: I1e449e0c71bd60ca4605cd5d0770f596fc2ac64f Reviewed-on: http://gerrit.openafs.org/1338 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d750c28ac23535524c9406ead4fa479451ff0e12 Author: Andrew Deason Date: Wed Feb 17 12:05:53 2010 -0600 Add support for amd64_obsd46 Change-Id: I41a9ad46cac3af1e02c64683e893c9547598e867 Reviewed-on: http://gerrit.openafs.org/1337 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1e53da39f57777792eb9431a6c553db3e1f6b96c Author: Andrew Deason Date: Wed Feb 17 12:56:51 2010 -0600 Include stdint.h when using intptr_t Some platforms such as OpenBSD require including stdint.h before you can use intptr_t. So, include stdint.h (if it is available) whenever we use intptr_t. Change-Id: I6da005755752e8d52f62e78d15103b19a951e50a Reviewed-on: http://gerrit.openafs.org/1336 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 62016280224d6532f0807e9637b3c38cf025c7fe Author: Derrick Brashear Date: Wed Feb 17 13:26:43 2010 -0500 kill macos prior to panther we haven't had a 10.2 machine to build on in quite a while... might as well pull it, it probably doesn't work anymore Change-Id: Iad809e83dadb0e7fa8c61b3f37f574a571042fc8 Reviewed-on: http://gerrit.openafs.org/1335 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f96ca93b733ef27cd8a58fcc7462ce4a2f4b2f4a Author: Andrew Deason Date: Wed Dec 2 13:37:27 2009 -0600 salvager: avoid needing temp files to stay around The salvager makes use of a couple of temporary files to store some information while doing a salvage. Instead of referring to these files by path name everywhere, pass around file handles instead. That way we can unlink the files immediately, and they will be deleted on close. This removes one of the roadblocks to allowing multiple salvages on the same partition to occur at once (since otherwise other salvagers would remove the temporary files on startup), and also makes it much less likely that old temporary files will be left lying around in the first place. Change-Id: Idfc696c2c75e21db717c720bd950af6e2766b9aa Reviewed-on: http://gerrit.openafs.org/1263 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 60e8dcb4e66c6edc90a0448221b7d1818bd5cafb Author: Andrew Deason Date: Thu Feb 4 16:47:19 2010 -0600 DAFS: Maintain viced volume group hierarchy cache When salvaging a volume (with DAFS or not), it is required to read the volume headers of all volumes on the partition, so we know what volumes are in the same volume group as the salvaged volume. Currently with DAFS, this requirement can make demand-salvages very slow, since each demand-salvage must read each volume header on the partition. So, instead of having each demand-salvage read the volume headers itself, have a demand-salvage request the required volume group hierarchy information from the fileserver. The fileserver will scan the partition's volume headers, and will keep the hierarchy cached in memory. Any modifications to this hierarchy from volume creation/deletion will update this volume group cache (VGC) via FSSYNC commands. This results in a dramatic salvaging speedup when many demand-salvages are requested, and eliminates the cases where DAFS salvaging can be significantly slower than non-DAFS salvaging. FIXES 124488 Change-Id: Ie9ae655593ad8a90ca6ad8f63e6b6e799f283988 Reviewed-on: http://gerrit.openafs.org/880 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ab32b23806b840a67e9423865d594992b41a0602 Author: Andrew Deason Date: Thu Feb 4 16:08:48 2010 -0600 Add a general file-level locking API Add an API for acquiring and releasing file-level locks. This abstracts away the platform-specific aspects of file locking, and also makes the locking work when several threads attempt to acquire a lock within the same process. This commit just adds the functions and datatypes; nothing actually uses them. The users will be added in (hopefully nearby) future commits. Change-Id: I6bffb6a7dd47ffb5c8a9942b16cd5ef6bc7eb62e Reviewed-on: http://gerrit.openafs.org/1237 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8f1e1199a2ef65ac0c5f00dcb30aeb8114c95551 Author: Derrick Brashear Date: Tue Feb 16 13:10:09 2010 -0500 linux bdi allocate memory allocate bdi with osi_Alloc (and free with osi_Free) seems to fix an oops FIXES 126514 Change-Id: I667391710c5fd2b6712117471247f1cd7c20aa9b Reviewed-on: http://gerrit.openafs.org/1332 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 86acebb1233b82e82fbb5b0d7106ff13864a9111 Author: Simon Wilkinson Date: Sat Feb 13 01:14:07 2010 +0000 aklog: Refactor token management operations Pull the token management operations (get, set and compare tokens) out into their own functions. Again, this is purely a refactoring exercise - no behaviour changes are anticipated as a result of this change. Change-Id: I9c64a319fcaa2edeb492c7822f9bae64c91cc20c Reviewed-on: http://gerrit.openafs.org/1326 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 725f0a63a36545fa9a6dae50362a936fd4b77ab2 Author: Simon Wilkinson Date: Fri Feb 12 23:38:09 2010 +0000 aklog: Refactor token acquisition code This change refactors all of the rxkad specific token acquisition code out of the common auth_cell loop, and into a number of functions of its own. There should be no functional changes. Change-Id: I61314588ba4db6b85db03314d4524322f74c9230 Reviewed-on: http://gerrit.openafs.org/1325 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 267ccb986c850b2a8f4431fa210b6c7f1c09021b Author: Simon Wilkinson Date: Fri Feb 12 11:54:17 2010 +0000 aklog: Use a function to print debug statements aklog was scattered with things like if (dflag) { printf("Oh no, the world is ending\n"); } Simplify these by adding a dprintf() function, which only prints its arguments if dflag is defined. Use this throughout the code. Change-Id: I673942e9ea6a8b96ea9d11a608cfaeaf00098b88 Reviewed-on: http://gerrit.openafs.org/1324 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7cdc89edca112870f5e9dcb27cbb4cd5551ae7a4 Author: Simon Wilkinson Date: Wed Feb 17 14:01:14 2010 +0000 aklog: Actually use new get_realm_from_cred fn An earlier patch added the new get_realm_from_cred function, but failed to update the callsite to use it. Fix that. Change-Id: I9e9d7545b20df041400d140e80c7f018b033043e Reviewed-on: http://gerrit.openafs.org/1334 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f7b5d7153cbac34b9411728c1c53d9c0064f5857 Author: Simon Wilkinson Date: Fri Feb 12 11:13:16 2010 +0000 aklog: Tidy realm handling Assorted small changes to the way realms are handled by aklog: * Remove static buffers when realms are passed between functions * Add cleanup for all dynamically allocated strings to auth_to_cell * Create an extract_realm helper function to handle extracting realm information from principals. * Add a function to handle extracting realm information from decoded tickets Change-Id: I320389033f4862d30774b40103e536fd5bac841b Reviewed-on: http://gerrit.openafs.org/1323 Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f8c6bfffd3a32f41d24a171026b985974a5cc7b3 Author: Simon Wilkinson Date: Fri Feb 12 10:29:00 2010 +0000 aklog: Dispose of the pointless confname string confname makes a static copy of the AFSDIR_CLIENT_ETC_DIRPATH string. As pr_Initialize takes it as const, there's no need to maintain our own copy, and so this is superfluous. Remove it. Change-Id: I64b13aae80b15f6b7511a040f39467bca76186b8 Reviewed-on: http://gerrit.openafs.org/1322 Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 60ea6a23ab98698351de4b0592dd5df2ac8eebc0 Author: Simon Wilkinson Date: Fri Feb 12 10:19:26 2010 +0000 aklog: Clean up cell handling Clean up the aklog get_cellconfig routine, so that it is no longer reliant upon global variables. * Tidy the handling of local_cell, and use dynamically allocated, rather than fixed length buffers. * Use the cell name contained within the afsconf_cell structure, rather than a local copy * Access linked cell information from afsconf_cell, rather than explicitly returning it * Don't use globals for linkedcell Change-Id: I6ad42c70dcac7f285997be7c95a77dc67bf63679 Reviewed-on: http://gerrit.openafs.org/1321 Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 05d667e59bbf5e32efa08d5dd7156db20a56f9d9 Author: Simon Wilkinson Date: Fri Feb 12 09:48:44 2010 +0000 aklog: Cosmetic cleanup Fix indentation so that code lines up correctly, Fix function declarations so they match the house style. Remove some dead code and comments Move comment blocks so they're above the code that they're describing. Remove unused 'lastcell' string Change-Id: Ief924675384e28885e4b7b88c4d5932279c9b26e Reviewed-on: http://gerrit.openafs.org/1320 Reviewed-by: Marc Dionne Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 481098e04c686c351fee02221fbe6d890dc1a767 Author: Simon Wilkinson Date: Sun Feb 7 21:51:55 2010 +0100 Unix CM: Tidy up the statistics interface Sort out the function call statistics interface. Whilst it's still wretched, this makes it a little less so. *) Add some warnings at the start of the afs_CMStats structure about what needs to be done when adding things there *) Remove the conditionals around the CacheBypass counters, so that stats clients don't need to be built with the same options as servers *) Add all of the stats entries added after IBM to the xstat_cm_test routine *) Add a warning to xstat_cm_test if the data returned from the server differs in size to the local stats structure. Change-Id: If1ffb68c84bca972f685ae619febba8c6f8b5e17 Reviewed-on: http://gerrit.openafs.org/1319 Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fa2536c02cf26f7db30bf623e95f42be88138d14 Author: Jason Rogers Date: Mon Feb 15 17:19:12 2010 -0600 prdb_verify -rebuild with supergroups fix This change eliminates the redundant iteration over the supergroup[] array in DumpRecreate. By iterating over both this array and entries[], duplicate au lines are created and the count variable becomes incorrect. Furthermore, the au lines created in the supergroups[] section were incorrectly in the form of au instead of au . FIXES 126500 Change-Id: I087772b63934406273f153f4b8a581d965f1e4d5 Reviewed-on: http://gerrit.openafs.org/1316 Reviewed-by: Michael Meffie Tested-by: Michael Meffie Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear commit 4bc04a79e75ffa5ad852dfb475bfcb3b263b4e57 Author: Derrick Brashear Date: Fri Feb 12 16:46:33 2010 -0500 macos bulkstat support add KPI-based bulkstat support for macos Change-Id: I6d9afa968db5930d392a6298dc5094f3cb500a1b Reviewed-on: http://gerrit.openafs.org/1303 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a0c8c3da0d059df7bc0c6fad98ad55e7cc2f9aed Author: Derrick Brashear Date: Mon Feb 15 23:51:52 2010 -0500 xdrmem for ukernel fix up the build for ukernel when warnings are enabled Change-Id: I2520f77e043f2e75297ef66a4c44b6e456d30892 Reviewed-on: http://gerrit.openafs.org/1329 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 000c665881f8941d62d236550727f886298e54e2 Author: Simon Wilkinson Date: Sun Feb 14 00:45:19 2010 +0000 Unix CM: Add xdrmem and xdrlen to kernel builds Add the new xdrmem and xdrlen XDR sources to kernel space. Make some changes to the xdrmem header file to permit it to build in kernel space. Change-Id: I2ab32f67287df28d4ffded651d3d49d1211dd40e Reviewed-on: http://gerrit.openafs.org/1328 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8cf4b945b93bfb7ba09a73fcec32a898efbc3ee2 Author: Simon Wilkinson Date: Sun Feb 14 00:38:47 2010 +0000 Add xdrlen and xdrmem to pthread build Add xdrlen and xdrmem to libafsrpc, so they're available to pthreaded binaries. Change-Id: I55ed54a3fb87865d286bf2019858afb037c967ea Reviewed-on: http://gerrit.openafs.org/1327 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 06f6dc8dc70c0c9cdd875896eadf158b88a429ac Author: Simon Wilkinson Date: Sat Feb 6 14:20:34 2010 +0100 Remove the old new token interface ktc.c has had for a long, long time a 'new' token interface, which was only enabled if KERNEL_KTC_COMPAT is set. However, this is never defined in our tree, relies on a syscall that just won't work on platforms such as Linux, and won't support any of the new token formats we're planning. So, just remove this interface from our code - it's in version control should we want to revisit it in the future. Change-Id: Iab3dd04498799f061449a50bdac39c6407a9fdd7 Reviewed-on: http://gerrit.openafs.org/1318 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 79ad82ccde98391ba59dc1234c10def78520b680 Author: Adam Megacz Date: Sun Feb 14 17:30:42 2010 -0800 Have bosserver catch SIGTERM and shut down gracefully. Many modern process supervision systems (runsv, daemontools, sysvinit) expect to be able to terminate a process gracefully by sending it a SIGTERM; although SIGQUIT is nominally used for this purpose it seems to have fallen into disuse as a matter of practice. Therefore, to integrate as smoothly as possible with the outside world, bosserver should catch SIGTERM and interpret it as a request to shut down gracefully. When used with process supervision (runsv or daemontools), the previous behavior would cause bosserver to die but leave its children running, and then bosserver would get restarted by the supervisor. The result is a situation where there would be two copies of every bnode process. Mayhem ensues. Change-Id: I8690fba0af6c2b9f9613527254af915be9e76dfc Reviewed-on: http://gerrit.openafs.org/1310 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8ea6c727aa60dc60d5bc18a476f673554aaffff5 Author: Jason Edgecombe Date: Sat Feb 13 09:16:22 2010 -0500 Some minor rewording and grammatical tweaks of the CellAlias man page Added some text that the CellAlias file is only used on Unix. LICENSE BSD Change-Id: I913d6a0774240ffc16cf92cfa92c4b2d06f41fd6 Reviewed-on: http://gerrit.openafs.org/1307 Tested-by: Jason Edgecombe Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c892043b9545ce6c87a062546b9cdab48f32186e Author: Derrick Brashear Date: Fri Feb 12 16:37:19 2010 -0500 add bulk newvcache method let NewVCache return a vcache which is already configured for bulkfetching takes the bulkstatus "sequence number" and sets the flags and length Change-Id: Ife67c3deccda2ceefb4a0f1c98a837a3b6401cd2 Reviewed-on: http://gerrit.openafs.org/1302 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9a2741d001d89e7e828b547a05e9d89cd59733b0 Author: Marc Dionne Date: Fri Feb 12 19:23:52 2010 -0500 Initialize variable that can potentially be used uninitialized Some compiler versions complain that "code" might be used uninitialized here. If opening the configuration files fails, conf would be null and the condition would indeed test an uninitialized variable. Change-Id: I1d4da49a5afc94ac6617201110be84a0e5548f38 Reviewed-on: http://gerrit.openafs.org/1306 Reviewed-by: Simon Wilkinson Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 029b470e673ecc2d4448aa6a46fd10b6d8de4e7e Author: Derrick Brashear Date: Fri Feb 12 16:16:56 2010 -0500 darwin vn hold dead code removal pull out the unused code which tries to cope with a failed vnode hold. if we become able to do so, we can do so later Change-Id: Ib53f469feaba4c6ec6b15730315e87e75f8f9eb8 Reviewed-on: http://gerrit.openafs.org/1301 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e78f6f33b53798e4c742641746d3df9e7435eeff Author: Derrick Brashear Date: Wed Feb 10 15:57:48 2010 -0500 irix stdarg printing use icmn_err facility to print error (and panic for osi_Panic) note that solaris vcmn_err is basically the same, but there may be issues per some commenters. Change-Id: I56e825e16d69a232a2cdc5108071a00858ecf45c Reviewed-on: http://gerrit.openafs.org/1287 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 769be238b07897e94e77fa9b7743a53d8f887535 Author: Andrew Deason Date: Thu Feb 4 13:00:47 2010 -0600 Document FSSYNC commands Provide some explanation for the various FSSYNC commands, and what they are there for. Change-Id: I572300b66cc8b6a1b0f2aa185edd198c237f7225 Reviewed-on: http://gerrit.openafs.org/1236 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 344ba58a0785dff50dba8d232895ff7399abb92e Author: Derrick Brashear Date: Fri Feb 12 00:07:02 2010 -0500 irix test kernel cleanup add missing paren for irix test kernel case Change-Id: I1374cac568f5632c3bc29f492a47ea665abb9ef7 Reviewed-on: http://gerrit.openafs.org/1300 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 135c5668f9197aae6d29b1575e76323dd147f521 Author: Jeffrey Altman Date: Thu Feb 11 21:45:40 2010 -0500 Windows: Prevent explorer shell extension from crashing if symbolic link add fails The explorer shell extension was passing the wrong parameters to the MessageBox API when a symbolic link add failed. The end result was stack corruption. FIXES 126406 Change-Id: I59b8b71d947525adccbd817cd5b6d4de5bf082b7 Reviewed-on: http://gerrit.openafs.org/1298 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 3b15ac44990095a694e5f9707c5de5619fdf22d1 Author: Derrick Brashear Date: Thu Feb 11 00:30:54 2010 -0500 remove erroneous disabling of darwin rx event scheduling hook the hook added to force reschedule to be noticed was disabled in the course of testing. re-enable it. Change-Id: Id9018b66c9adfc39709b3739510987402dc1fb18 Reviewed-on: http://gerrit.openafs.org/1294 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 23848b4b742e13b8630f8ff25f5ed63094e6d01d Author: Jeffrey Altman Date: Wed Feb 10 23:57:57 2010 -0500 Windows: 1.5.72 Change-Id: Ifef2538d2020e9ecb17bc1ac7176c99f2651a96a Reviewed-on: http://gerrit.openafs.org/1292 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 70052370b7d7d87da9474bc02bfb8f6d330a3824 Author: Derrick Brashear Date: Wed Feb 10 23:41:58 2010 -0500 make unix 1.5.72 update version for next release Change-Id: Idb0eeac9e5883f99ba787a41ab38081fcdabd855 Reviewed-on: http://gerrit.openafs.org/1291 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b5cf121d6bfa5d8539354ca455c2de68534c598f Author: Derrick Brashear Date: Wed Feb 10 22:12:04 2010 -0500 set minimum darwin kernel rx sleep never be willing to sleep less than 500ms. additional tweaks to the rx scheduler may be needed however before we always slept for 500; now we'll sleep longer if no events are pending (but not forever) Change-Id: I7fdb02dd7a383131fffcfae532d71c8fbeb97545 Reviewed-on: http://gerrit.openafs.org/1290 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bcdb5220e2db2bf0cd22c6316682046425048d87 Author: Simon Wilkinson Date: Tue Feb 9 19:53:40 2010 +0000 Linux: Use current_creds() if stashed creds fail If we can't use our stashed credentials (because SELinux hates us, most likely), then fall back to trying the processes current credentials instead of just oopsing. Change-Id: Ib3676ff66f8400e86cccb97fb207a5f094ceb4ad Reviewed-on: http://gerrit.openafs.org/1283 Tested-by: Derrick Brashear Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear commit 762c8b41edf3bec9dc4dfc7ec972af3a432b2b1a Author: Jeffrey Altman Date: Wed Feb 10 16:45:33 2010 -0500 Remove warnings in src/ptserver/ptclient.c 1. Signed vs unsigned warnings. 2. Casting of struct prentry * to struct prdebugentry * for ubik_PR_DumpEntry call. 3. Casting of char * to struct in_addr *. 4. ANSIfication of PrintHelp() and skip(). 5. Inclusion of ptuser.h to avoid missing prototypes. Change-Id: I7d4c10c5df784c1b9fecc83e21d92bdc0b7ca0ae Reviewed-on: http://gerrit.openafs.org/1288 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 734bb14468cb071e22b45895e7bad21dda70fb2a Author: Derrick Brashear Date: Wed Feb 10 13:52:43 2010 -0500 tweak osi_Panic until all platforms can grok stdarg for now, just move it to the end of the file Change-Id: I7bab901be76fabb75f688096e9637caada883816 Reviewed-on: http://gerrit.openafs.org/1286 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 64c24e84f9a0a96deac62cb3377577eadd582811 Author: Derrick Brashear Date: Tue Feb 9 23:45:23 2010 -0500 remove osi_Panic prototype on irix just don't prototype this on irix Change-Id: If9f6e6ef1eb4fcfcfbc81f7d69af00f72acfd517 Reviewed-on: http://gerrit.openafs.org/1285 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fe246be823772262eb7f89415d5b8fb11798dc42 Author: Derrick Brashear Date: Tue Jan 5 01:50:49 2010 -0500 darwin rxevent sleep instead of polling use an interruptible sleep (and wakeups on shutdown or schedule) instead of polling, on macos Change-Id: I25934efac63ccaf9015f79c6711d09c693f0ad51 Reviewed-on: http://gerrit.openafs.org/1066 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d0f083feb0415f7ab68ecdcd58fde2c9856043e6 Author: Derrick Brashear Date: Tue Feb 9 15:07:09 2010 -0500 reclaim CCore1 vcache state and the one place it was used it seems to have been used wrong anyway it's a relic from osf1 Change-Id: Iae72030dcbb812422431d3d23737f6c8fb5f0ca3 Reviewed-on: http://gerrit.openafs.org/1284 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7b6ccc1b9199d3787ea5457860fcb1c873a19a5c Author: Jeffrey Altman Date: Tue Feb 9 00:42:41 2010 -0500 Windows: Permit Windows to build Recent changes added a new dependency of afspioctl.lib to all server binaries. Export new afsconf_ functions from libafsauthent.dll Fix afsconf_* usage in afsio.c Change-Id: I03e377a3d28b4efbea4a799e6ca63606eab699c9 Reviewed-on: http://gerrit.openafs.org/1273 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a1616e2c93b0922a47958d2c4dc8db41202adca0 Author: Andrew Deason Date: Thu Feb 4 16:26:21 2010 -0600 Consolidate code for reading/writing vol headers The code for reading in and overwriting/replacing volume headers is duplicated many times throughout the volume package. Consolidate the code into the functions VReadVolumeHeader, VWriteVolumeHeader, VCreateVolumeHeader, and VDestroyVolumeHeader. This makes it easy to change the semantics of how headers are read/written, though this commit should not change them. Change-Id: Id395ee25fc2db92de9301b9cdbe18f30830e18d3 Reviewed-on: http://gerrit.openafs.org/1238 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3913aa55eed10f9d6316910ef950f5c3242e20d7 Author: Rainer Toebbicke Date: Mon Feb 8 15:18:04 2010 +0100 afs_TruncateAllSegments() make sure correct afs_size_t comparison is used when selecting dcache entries for truncation Insure that afs_TruncateAllSegments() uses the correct [64-bit] comparison when deciding whether to truncate chunks: alen - AFS_CHUNKTOBASE(tdc->f.chunk) for a file > 2GB would fail to be recognised negative with an "afs_int32 newSize", even with alen = 0 and big tdc->f.chunk. Change-Id: Id77109fb8238234dae725bd876f70ea0fbd403fc Change-Id: If0120e21a52316e536d03241c83e8f0d36614c13 Reviewed-on: http://gerrit.openafs.org/1252 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 880d35f8370ffc978bbcff3b3218f31a945d8555 Author: Derrick Brashear Date: Tue Feb 9 13:54:30 2010 -0500 ensure secObj is initialized in afs_ConnBySA NULL it so we don't compare against garbage Change-Id: Id80ab21a9a227ec8fd09dbc9a822fd1ce873b333 Reviewed-on: http://gerrit.openafs.org/1281 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6c628445ebc3203ddcb8167914d61ef3711380c7 Author: Derrick Brashear Date: Thu Feb 4 03:22:15 2010 -0500 provide afs_osi_TimedSleep this interface works how osi_Wait *should*, except on some platforms Wait appears to wake up all waiters(!) by using a single wait channel in the backend. rather than change that and risk problems, introduce an interface using the same system of events we use for osi_Sleep Change-Id: Ic91726b138bd2512282896ec48c542063ef000cf Reviewed-on: http://gerrit.openafs.org/1233 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 01d8b61c7f7a9b5bb7c38f62ae432986d2ef3bee Author: Derrick Brashear Date: Wed Feb 3 10:16:53 2010 -0500 internationalize comerr reuse the Heimdal method for internationalizing comerr. as a side effect provide heimdal-compatible com_right. LICENSE BSD Change-Id: I6e699125ad3af1d402f14f9462e434c30ad4d1fd Reviewed-on: http://gerrit.openafs.org/1225 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d9af80b0bbc1a43a8da02cadb2d8841fe54bf0de Author: Simon Wilkinson Date: Sat Feb 6 14:04:50 2010 +0100 Unix CM: Make cache bypass build again My recent afs_pioctl changes broke the build when cache bypass is enabled. Fix this. Change-Id: I515ff3c743d8f63c086ead86991ad6cd9faaab93 Reviewed-on: http://gerrit.openafs.org/1280 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6011b3a325b64b2f9527b3e492b77b879ce2ec0b Author: Simon Wilkinson Date: Fri Feb 5 13:49:27 2010 +0100 Unix CM: Just use Bogus for VenusLogging The VenusLogging function no longer exists - instead of having a stub the returns EINVAL, just use the existing Bogus stub (which returns EINVAL) instead. Change-Id: I9cc1746577c19ff2e4087e16e8e2b56c0070c75d Reviewed-on: http://gerrit.openafs.org/1279 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6361d650490ead617e7acd9e798ba65dd872195f Author: Simon Wilkinson Date: Fri Feb 5 12:18:42 2010 +0000 Unix CM: Wrap afs_pioctl.c at 80 columes Much of the documentation in afs_pioctl.c spanned many many lines. Wrap it all at 80 columns for a more pleasant reading experience. Change-Id: Iae15a792a4cd6fa54eda65d43157ca3f7910ca2b Reviewed-on: http://gerrit.openafs.org/1278 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e2b65732c09c4d1097fd54addf6596aaba9043c4 Author: Simon Wilkinson Date: Thu Feb 4 17:27:32 2010 +0000 Refactor afs_ioctl code The ioctl code was a nightmare of #ifdefs. This patch reworks it so that there is a single function for each operating system, which makes it much easier to see what's going on. Eventually it should be possible to move these reworked functions out into the osi directories Change-Id: I61f70b23ad0c7ea137e6aa843be6f75c83c02843 Reviewed-on: http://gerrit.openafs.org/1244 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 92946910e205252c23e435ff8fef2a3f29ea9592 Author: Simon Wilkinson Date: Thu Feb 4 16:08:26 2010 +0000 UKERNEL: End the #define u insanity UKERNEL redefines the character 'u' to do a function call. This hurts other kernel developers in all sorts of interesting ways. Remove the definition, and instead explicitly reference the get_user_struct() function in those places that we need to. Change-Id: I64be2eb527c779df0a3d4508444ed68f3634667d Reviewed-on: http://gerrit.openafs.org/1243 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d5622d03196762bd8a60404fea98b4bb044e076d Author: Simon Wilkinson Date: Thu Feb 4 15:09:34 2010 +0000 Add rx security index enum Add a enumerated type for rx security indexes, initially containing the values reserved for null, kad, gk, and k5. Start to use this type, and related names, rather than hard values throughout the code. Change-Id: Ic71e5da28b4270abf7b6688b2c6438f17268f1da Reviewed-on: http://gerrit.openafs.org/1242 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d914ad4c75716b4870e22e8b43629057e35e2eee Author: Andrew Deason Date: Mon Feb 8 15:03:08 2010 -0600 salvager: alias -f to -force DAFS added the -forceDAFS flag, which made the '-f' flag ambiguous, when it used to be short for '-force'. Restore the previous meaning of '-f' to reduce backwards incompatibility. FIXES 124916 Change-Id: Ieb864b35a91000960f9d9c503c28db56602df13e Reviewed-on: http://gerrit.openafs.org/1254 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8459dc317bc6393d23f1afee0b211bcbdb9a5601 Author: Simon Wilkinson Date: Thu Feb 4 12:23:58 2010 +0000 Unix CM: Simplify #ifdef ladder in lock.h Hugely simplify the ifdef ladder in lock.h, by using #elif, rather than multiple levels of nested ifdefs Change-Id: I8fc730242decab0a0f864a9814c6c47c9974b496 Reviewed-on: http://gerrit.openafs.org/1241 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8e1d140d107b46ac0a88c544289b8d29f1542ede Author: Simon Wilkinson Date: Thu Feb 4 12:18:30 2010 +0000 Unix CM: Indent #ifdef ladder in lock.h The ifdef ladder in lock.h was a pain to read. Indent it to make it clearer. Change-Id: I673a85785e1e6207dae55616845d5cb982694189 Reviewed-on: http://gerrit.openafs.org/1240 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 04adcfc78b038303d273f64ba756e9ecda478436 Author: Simon Wilkinson Date: Wed Feb 3 16:00:47 2010 +0000 Unix CM: Reorganise security object code Reorganise the code which creates a client security object for the Unix CM into its own function. Change-Id: Ic92ca4022b000c5cd48bbe6318bf83379626e890 Reviewed-on: http://gerrit.openafs.org/1239 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ad4adb4aa2e458b744474931b0458d2146fb6f3a Author: Simon Wilkinson Date: Tue Feb 9 16:26:57 2010 +0000 Initialise ptuser to NULL Fix fallout from d008089a79ef268bbca91d660a840f32cb416865 - sc wasn't being initialised when it was declared, and some code paths would fail to set it. This led to the == NULL check failing, and a new rx connection being created with an invalid pointer as a security context. Disaster ensued ... Change-Id: Ibae3c72408d1145bc771bd07e573427d9f427679 Reviewed-on: http://gerrit.openafs.org/1277 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6219c84243706ed46b922c2e037cceab2684d645 Author: Antoine Verheijen Date: Mon Feb 8 14:57:51 2010 -0700 OpenBSD: don't use AFS_GLOBAL_SUNLOCK on single processor system Put back the header directives that only turns on AFS_GLOBAL_SUNLOCK when compiling for multiprocessors system. When enabled on a single processor OpenBSD system, it is possible to put the entire system into a lengthy (minutes) lock state when performing multiple AFS activities. The system behaves MUCH better when AFS_GLOBAL_SUNLOCK is not set (no problems encopuntered). This whole locking mechanism needs a bit more examination on OpenBSD before this is useful in single processor mode. Change-Id: I19813b78ad8d705b4f043ccb3a38c83e278972e9 Reviewed-on: http://gerrit.openafs.org/1276 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5f39ae64bafe1e2073ff419fe62c2d5a86fc98f5 Author: Antoine Verheijen Date: Mon Feb 8 15:33:38 2010 -0700 OpenBSD: allow for more graceful shutdown A shutdown or unmount of AFS on OpenBSD will invariably result in a kernel panic. This is because the afs_unmount() routine does not (can not?) force vnode releases if the vnode is still busy. However, it continues on nonetheless and dies a horrible death a little later. This update causes a return from afs_unmount() with EBUSY if all the vnodes weren't released. This results in error messages on shutdown but the overall process continues more reliably and reboots, for example, work. There is likely a better solution to this but at least this is no worse than a system crash and it doesn't require console (or power button) intervention so it should do until I have the chance to explore further. Change-Id: Ia70f83bda748ea3d0b81b341a292e83121446567 Reviewed-on: http://gerrit.openafs.org/1275 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d06bc699f2e3848da8ce9a7fa20ac99db630bd1b Author: Antoine Verheijen Date: Mon Feb 8 15:23:03 2010 -0700 OpenBSD: fix lookup of network interfaces Starting with OpenBSD 4.2, the interface list returned by sysctl using NET_RT_IFLIST contains multiple versions of the data. This really messes up the rx_getAllAddr_internal() routine that returns a list of valid interfaces for the system (to the point where none are returned). This change adds a routine that cleans up the data returned by sysctl so it returns only a single (the most current) version of the data. That stops afsd (among others) from being cranky when it starts up. Change-Id: Ief1df0d2c3eb241c45b439a785ddb67d3afe992c Reviewed-on: http://gerrit.openafs.org/1274 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1d2735c0a85ab0544cf60be9f832cab2d0e434cf Author: Jeffrey Altman Date: Tue Feb 9 00:40:20 2010 -0500 Windows: add xdrlen Adds xdrlen.c to librx.a and libafsrpc.dll Exports xdrlen_create from libafsrp.dll Change-Id: I Change-Id: Ia3754f73f44f2c842b7aefa3104c8143f8a2b78d Reviewed-on: http://gerrit.openafs.org/1272 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 03ac7bd100d93f2f47b5e3724c61e3d93a9eca56 Author: Antoine Verheijen Date: Mon Feb 8 15:07:09 2010 -0700 OpenBSD: move AFS memory type offet The internal malloc memory types for IPv6 (M_IP6OPT, ...) conflict with the type numbers used to designate AFS memory (M_AFSFID, etc.). This change moves the AFS memory type to a new number that does not conflict. This is not a serious issue but can create real confusion when trying to debug or track memory issues, among other things. Change-Id: Icccaa7c06443cab008013414cb3c2ab4ea08889e Reviewed-on: http://gerrit.openafs.org/1271 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4221d7acc8595a052dbc5fbb4366050c00d6ef37 Author: Antoine Verheijen Date: Mon Feb 8 16:01:46 2010 -0700 Fix segmentation fault in vsu_GetVolumeID When determining the volume type of a volume, vsu_GetVolumeID() checks to see if the volume name ends in '.backup' or '.readonly' by backing up the appropriate number of characters from the end of the name. It does not, however, check to see if it skips past the beginning of the volume name. This can result in a segmentation fault (which it has for me on many occasions during a vos release) depending on where memory is allocated or how/if memory is protected. This patch corrects this behaviour by checking the volume name string length prior to doing the string comparison. Change-Id: Ia27fcac76b86ae2707663caa6bff365a4e8dd0da Reviewed-on: http://gerrit.openafs.org/1269 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 267c22e77197ebeed1a4d61041a60cd99dac7dcd Author: Chaz Chandler Date: Mon Feb 8 20:59:10 2010 -0500 irix label changes rx subdir no label support in non-c99 irix cc, xdr_len.c and xdr_mem.c changed accordingly Change-Id: I9f9780254cd7e80649d40b3df6bcdd84a2f90404 modified: src/rx/xdr_len.c modified: src/rx/xdr_mem.c Reviewed-on: http://gerrit.openafs.org/1266 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 87af0e4cb603218417a04e203b5182929f7c5a0e Author: Chaz Chandler Date: Mon Feb 8 21:42:35 2010 -0500 fix AFS_ASSERT_GLOCK on irix and aix irix and aix do not have a vararg version of osi_Panic, fixed AFS_ASSERT_GLOCK macro definition in afs/afs_osi.h for those two platforms Change-Id: I0b541d2c1edad1364ef1c91dec84b9d4319c4e62 modified: src/afs/afs_osi.h Reviewed-on: http://gerrit.openafs.org/1267 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ab17ebef16a04180b2ede8c8ed07cd9c1871ae42 Author: Antoine Verheijen Date: Mon Feb 8 15:45:25 2010 -0700 Add support for OpenBSD 4.6 Add config param header and sysname number for OpenBSD 4.6. As well, add an additional parameter to a call to ifa_ifwithnet() when looking up the MTU for an interface to indicate that the call should use the default routing table. With the advent of OpenBSD 4.6, the system has started to make provisions for multiple routing tables which included a change to the calling sequence for this routine. Change-Id: Idb53efef0e229ca26bd587f2f8cd9df8a0248227 Reviewed-on: http://gerrit.openafs.org/1265 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 80151fdfcacf8c2d673bf79ac9276b30979de976 Author: Steven Jenkins Date: Mon Feb 8 14:38:49 2010 -0600 tubik: Initialize mutexes and cvs Initialize some mutexes and condition variables for pthreaded ubik. FIXES 124977 Change-Id: I95833c5e277183e3c912e1b2fde2b02f88cff0c9 Reviewed-on: http://gerrit.openafs.org/1253 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a5c733d0cfd61cb34ca99446c546629d059fc968 Author: Derrick Brashear Date: Sat Feb 6 22:36:18 2010 -0500 darwin vnodeops cleanup remove dead code, and retabify Change-Id: Ia11ec13773688a0fd7987dc777905364e1354e15 Reviewed-on: http://gerrit.openafs.org/1251 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 80a1130612a68d14e1beda90013bd90d5523aa25 Author: Derrick Brashear Date: Sat Feb 6 19:48:44 2010 -0500 macos package allow backrev in order to go back versions, tell the install not to enforce "no backrev" Change-Id: Ifb4bee86344560d63c9b8ab3cd789f25ed8629b8 Reviewed-on: http://gerrit.openafs.org/1249 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7e14ccf1cd1598a8ae851fcb942578141675e49c Author: Derrick Brashear Date: Fri Feb 5 20:40:22 2010 -0500 fetchstore reorg shift the functions around to avoid forward decl Change-Id: I50a8280674745a5ccf0f01863ce5d0351f62366b Reviewed-on: http://gerrit.openafs.org/1248 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 57d8e4544713170dc31afede27a1d6e2f94f5b95 Author: Derrick Brashear Date: Fri Feb 5 19:54:22 2010 -0500 set storeproc for non-linux forgot to push this with 0683c04a Change-Id: Ifce009ed8b2877befc364b831a185126bf692ede Reviewed-on: http://gerrit.openafs.org/1247 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b80efa48f48ddfafe0ad2bdb9d00b6774de17357 Author: Derrick Brashear Date: Fri Feb 5 15:01:31 2010 -0500 decode-panic deal with kextload kextload won't handle -arch. deal appropriately. Change-Id: Iac7dac9b484e44b9610da028027aadbd94cfe151 Reviewed-on: http://gerrit.openafs.org/1246 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 521b3363aa1aa5530a83be3a7c55302c557e7818 Author: Jeffrey Altman Date: Fri Feb 5 13:45:48 2010 -0500 Windows: Remove use of AFS_AFSDB_ENV from kauth/user_nt.c AFS_AFSDB_ENV was removed from the rest of the source tree. Now remove it from kauth/user_nt.c so that DNS lookups can be performed from the ka_ authentication routines. FIXES 126366 Change-Id: I99cf6ada8b672398c0cfc6c8251cfc8dfdae9a31 Reviewed-on: http://gerrit.openafs.org/1245 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 0e8beecff3bffc0aa6f10d342cd4d100412ca29f Author: Derrick Brashear Date: Wed Feb 3 21:46:06 2010 -0500 macos prefs pane spelling fix spelling of link to the usual unix spelling Change-Id: Id8464a22c049200526c6ffe471ea6dc6d4b0ed9a Reviewed-on: http://gerrit.openafs.org/1230 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 604471a3f881a7895cda218a823692a63044dd2e Author: Marc Dionne Date: Wed Feb 3 21:34:24 2010 -0500 Don't clear afs_stats_cmperf too early during shutdown Commit 21cbf7fee0a089d94f62baa7df2422e7bc8293f7 activated some previously unused cleanup code. Part of this clears afs_stats_cmperf, but these stats are used later to check for leaks of chunks allocated with afs_AllocSmallSpace and afs_AllocLargeSpace. The result is a message about unfreed blocks in the syslog with negative counts. Since the structure is already cleared later in the shutdown process, just remove this instance. Change-Id: I6bf2ab37752d2623d072469fb87fa6d06e85b9ec Reviewed-on: http://gerrit.openafs.org/1229 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 682db4d64d550af86dc5a09786e050c6a98ffb0c Author: Derrick Brashear Date: Wed Feb 3 19:01:28 2010 -0500 fakestat should preclude afsdb lookups too macos tries to look up ._foo stuff. correctly identify those (mvstat 2, not 1) and also use tryEvalOnly to preclude AFSDB lookups Change-Id: I490fe98d695c4d230210bc4e4645ea20cd4d8fa2 Reviewed-on: http://gerrit.openafs.org/1228 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8419da9ffec8297759e2e4198eb3963d1d1ed843 Author: Derrick Brashear Date: Wed Feb 3 16:49:23 2010 -0500 macos installer scripts shouldn't echo remove the other echoes from these scripts Change-Id: I46b43aabc0f6080f776e2ec610d748920bc18d3b Reviewed-on: http://gerrit.openafs.org/1227 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9bea0fbf816744330863974d7ccb2d89cc2ccae0 Author: Derrick Brashear Date: Wed Feb 3 16:40:29 2010 -0500 format fallout this was missed somehow in my verification. fix it now. Change-Id: I35b16ed8dcb35b153d7bfb2360673a0f1323f03e Reviewed-on: http://gerrit.openafs.org/1226 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d72846bb0a0650f96362ba190fa8f1fed90ba7d5 Author: Simon Wilkinson Date: Wed Feb 3 00:37:20 2010 +0000 Fix fs storebehind on files with 2 or more servers fs storebehind didn't allocate a large enough buffer for its call to VIOCWHERIS. This meant that when it was called on a file with more than one server (one in a readonly volume), it would error out with E2BIG, rather than a more appropriate message. Fix this, by using the generic 'space' buffer for the VIOCWHERIS call. Change-Id: Ida0d40175f07ad528720ca700db5b5027b975095 Reviewed-on: http://gerrit.openafs.org/1224 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 718f85a8b69a78ac77beb5c8471af20657be2a53 Author: Simon Wilkinson Date: Wed Feb 3 00:31:32 2010 +0000 Fix pioctl input and output handling Pioctl input and output handling was being handled in an adhoc manner, with little or no detection of input and output buffer overflow. Whilst overflow is difficult to provoke on a real system, due to the size of the buffers being allocated for output, the code was difficult to read, and fragile to maintain. This patch adds an XDR like abstraction for marshalling and unmarshalling pioctl data. Whilst the real XDR can't be used and maintain backwards compatibility, this gives a similar elegance. Input and output pointers are replaced with instances of struct afs_pdata, which store both a pointer to the current position in the data stream, and a note of where the stream ends. All access to a data stream is now performed through a set of helper functions, which handle the reading and writing of integers, strings, and arbitrary blocks of bytes. An 'inline' function is provided for those cases where direct access to the stream is required. Change-Id: I6ed2e8e80cebde2abc6a517f4dbef09042b47037 Reviewed-on: http://gerrit.openafs.org/1223 Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a1fd212bc6b05d4b6fe74b9c0e5258165cea41d4 Author: Simon Wilkinson Date: Wed Feb 3 00:25:17 2010 +0000 Make twiddle build Update the twiddle utility (for manipulating rx settings in the Unix CM) so that it builds with error checking enabled. Also, add the binary to the gitignore file in that directory. Change-Id: I5c19832579db139e5c558b3488d7c49fdb7c08c4 Reviewed-on: http://gerrit.openafs.org/1222 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e501c45c4ab30bb8409d0dd1e4c7ebabed1e9669 Author: Simon Wilkinson Date: Sat Jan 30 22:28:47 2010 +0000 Add xdr_len, to work out required buffer size Currently, code which uses xdr_mem needs to take a guess at the buffer size required, allocate that guess, and error out if the data being encoded actually exceeds the guess. This adds a new XDR mechanism - xdr_len, which can return (using xdr_getpos) the length of the buffer required to XDR encode a given structure. Change-Id: I6e04c051118a26441caebdbcb2b5768d3c4389b6 Reviewed-on: http://gerrit.openafs.org/1221 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fa033c6beae5a8c912ea440385e1b7d16c1443d3 Author: Simon Wilkinson Date: Sat Jan 30 21:56:57 2010 +0000 Add xdr_mem to the Unix build A number of forthcoming attractions require xdrmem, which is currently not part of the Unix build. Fix it so that it builds without warnings, and add it to the standard RX build. Change-Id: I5a21b2c7cd837c317f16dc35bf12cdac69d10167 Reviewed-on: http://gerrit.openafs.org/1220 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0b234aa57f6b3de37bd167d1efad1c8987db7bc2 Author: Simon Wilkinson Date: Sat Nov 7 23:48:14 2009 +0000 Add printf format checks to the rest of tree Add printf format checks to the remaining va-arg printf-style functions in the tree. There are no error fixes required from this change. Change-Id: If774532a3ac5d8b611ec9f47576e933a57907185 Reviewed-on: http://gerrit.openafs.org/796 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a150df6107c07955a3a2fd97ddb94d401649e4e1 Author: Simon Wilkinson Date: Sat Nov 7 23:43:25 2009 +0000 Add printf format checks to rx Add gcc printf format checks to rxi_DebugPrint() and osi_Panic() Deal with the small amount of fallout. Change-Id: Ic356028613087bda02beb9907886421d80a227c3 Reviewed-on: http://gerrit.openafs.org/795 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d008089a79ef268bbca91d660a840f32cb416865 Author: Simon Wilkinson Date: Fri Jan 29 17:52:17 2010 +0000 Add interface to select client security objects Add a pair of interfaces to support the selection of a security object by the client. The idea of these interfaces is to abstract out the job of selecting an interface from the client code itself, and into a common library. This reduces duplicated code, and makes it easier to add new security objects in the future. Change-Id: I2bf411e6b56534070c827d009d36fa8a618c4511 Reviewed-on: http://gerrit.openafs.org/1219 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d302f1e193f631abb1c17253e8e3558f9c4a528c Author: Simon Wilkinson Date: Sat Nov 7 21:19:42 2009 +0000 Add printf format checks to the cache manager Add printf format checking to the afs_warn and afs_warnuser functions and fix the fallout. Change-Id: I81ed776308a31706bf307246c470ee409797f044 Reviewed-on: http://gerrit.openafs.org/792 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8229e668deee3eb00a295a8c9ea96a66b7049687 Author: Simon Wilkinson Date: Sat Nov 7 22:31:08 2009 +0000 Add printf format checks to afs_com_err() Add gcc printf format checks to the afs_com_err() functions Deal with the fallout, in particular change callers which pass an empty format string to pass NULL instead - the com_err functions already permit this alternate use. There's a couple of real bugs here - in one case, we attempt to print a NULL pointer, rather than a security index, and in the other we supply a NULL format string, rather than the string we meant to print. Change-Id: Icd48f92a4447d4af3dba9a4caa2ff73c1657ad47 Reviewed-on: http://gerrit.openafs.org/794 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 68463b6ab9c664303692ac264871723c27bfc524 Author: Simon Wilkinson Date: Sat Nov 7 21:21:00 2009 +0000 Add printf format checks to util's log functions Add gcc printf format checks to all of the logging functions defined in src/util/afsutil.h Deal with the fallout, in particular create cast functions to go from VolumeId and VnodeId to (unsigned int) Change-Id: I28181b73cfeac22cf869d34e75a8335e65125e36 Reviewed-on: http://gerrit.openafs.org/793 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dac001a0a04f54a76f254200ee24ab09f5ad22f7 Author: Simon Wilkinson Date: Fri Jan 29 15:12:42 2010 +0000 Don't pass tokens around the backup system The backup system has a global ktc_token, which is used to work out when its credentials are about to expire. This leads to an unfortunate dependency throughout the code on the format of this token. Replace this with a global time_t which stores the expiry time, and copy the required field from the token into this when we get the token. This limits the exposure of the token, and simplifies the code. Change-Id: Ia2929c2c0a4c1ba9ca5db881865f33af5a732d2f Reviewed-on: http://gerrit.openafs.org/1218 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a82f8591a174f22529f1fa9a1a68c4030abd56c9 Author: Simon Wilkinson Date: Thu Jan 28 23:50:54 2010 +0000 Common interface for server security objects Add an interface for creating arrays of server security objects. This collects all of the various daemon code for initialising security objects into one place, reducing duplication and making it easier to add new objects in the future. Change-Id: I9df20afccdbac4a610cb5bde32f01069272f27a2 Reviewed-on: http://gerrit.openafs.org/1177 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 61af204cf386deaeebf295dda5f9b58ea25fa225 Author: Simon Wilkinson Date: Tue Feb 2 22:13:45 2010 +0000 Document the extra options to fs getcacheparms Write some documentation for the -files and -excessive options to fs getcacheparms Change-Id: I769f8c0cf6d9d100a1687ae73a337132befb2449 Reviewed-on: http://gerrit.openafs.org/1217 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7533adaf34ef76324b971a211bcbf3fba5b40627 Author: Simon Wilkinson Date: Tue Feb 2 15:59:12 2010 +0000 Add a set of strings for the InstallationCheck InstallationCheck needs a strings dictionary to turn its errors into human readable content. Add such a dictionary, and use the correct product name and version for each Mac OS X release. FIXES 126322 Change-Id: I8401a1163ea078e690152215c20db6970969ee04 Reviewed-on: http://gerrit.openafs.org/1208 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 289d06650d0e3c7c0a308a275cf229d671135bf5 Author: Andrew Deason Date: Mon Jan 25 16:56:13 2010 -0600 Squash pthreaded ubik warnings Fix/ignore some warnings with --enable-pthreaded-ubik: - ubik/ubik.c: move rx_stackSize decl to non-pthread code, since it's only used there - budb/db_dump.c: move 'code' decl to non-pthread code, since it's only used there - ubik/recovery.c: move return to outside the ifdef, so we still have a return statement in the pthreaded case - Add -Wno-error to beacon.c in tubik, to match the ubik case Change-Id: I614f2425c36e77bb1a08838b45166d8edb080c73 Reviewed-on: http://gerrit.openafs.org/1211 Tested-by: Andrew Deason Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6beb32f0e059d1dbfbf82260a9103665aba88565 Author: Andrew Deason Date: Mon Jan 25 17:05:09 2010 -0600 Use -A and -u in pthreaded ubik rxgen Use -A for rxgen in tvlserver and tptserver to generate ANSI code, so we don't generate warnings. Also use -u in tubik rxgen, so we generate the ubik_* functions that new code uses. Change-Id: Id13168e65e36aeebf48610c28e7b3df2164fc073 Reviewed-on: http://gerrit.openafs.org/1210 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 61afb03fddcb21bfc83b277074784b31bc6739bb Author: Andrew Deason Date: Mon Jan 25 17:08:36 2010 -0600 Build utst_client for pthreaded ubik Build utst_client in src/tubik, as it is in src/ubik. Change-Id: I655445905efbaaa9e578a9e2061091679813a768 Reviewed-on: http://gerrit.openafs.org/1209 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c0724584680562330347026ee9ec72f74066bc51 Author: Simon Wilkinson Date: Tue Feb 2 15:47:02 2010 +0000 Don't echo from the InstallationCheck script Return codes from InstallationCheck are turned into errors by the GUI - don't echo them out to stdout as well. Change-Id: Iee9c1ff4687ea42ab8c18566493a8a92b6d51fed Reviewed-on: http://gerrit.openafs.org/1206 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 642e380ac10f1f249dc75b3656a6b82c3df9ace4 Author: Simon Wilkinson Date: Fri Jan 29 14:17:46 2010 +0000 Remove internal vldbClientInit prototype vldbClientInit is used by other modules in the backup suite, and is already prototyped in bucoord_prototypes.h. So, remove it from the internal header. Change-Id: I2688426189c3aeaacc8db4f815ede466caa5dde0 Reviewed-on: http://gerrit.openafs.org/1205 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 248da50aa56f19bdc8b2b322f5e17b3d2a363dce Author: Derrick Brashear Date: Tue Feb 2 00:36:58 2010 -0500 icl 64 bit platform rationalization be consistent about how we apply 64 bit longness. right now we were doing 3 different things. oops. Change-Id: Ie48816852d5db916e3023ae6e3cd2f6298802668 Reviewed-on: http://gerrit.openafs.org/1200 Tested-by: Derrick Brashear Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 44147f3c0265ed257fcc8dc459a7fbad224ebc14 Author: Derrick Brashear Date: Tue Feb 2 00:16:54 2010 -0500 icl trace code deduplication right now we have 2 copies of the same code for dealing with traced objects. it's the same code! make a function, and call it 4 times. Change-Id: I1c8b6d7b2cff59108eada1522ba1ec76efeba421 Reviewed-on: http://gerrit.openafs.org/1199 Tested-by: Derrick Brashear Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 837fb322e57c80aac5e5dee43fc7220727c1049f Author: Simon Wilkinson Date: Fri Jan 29 14:13:47 2010 +0000 Fix USS to use volser prototypes Fix the uss_vol.c file to use the volser prototypes. This clears up the list of the warnings in this file, so drop the warning supression from the Makefile, and remove the entry from README.WARNINGS Change-Id: I9e4ec8bdfa39e3a7adafea454a4c6d96c5fc9d0f Reviewed-on: http://gerrit.openafs.org/1204 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0d17a5a209ae80d880720fcd85b7555853605178 Author: Simon Wilkinson Date: Tue Feb 2 13:14:28 2010 +0000 xdr_proc_t really is different on linux26_i386 i386 Linux uses a register based calling convention within the kernel, but uses the stack for va_args based functions. This means that the hack of prototyping xdrproc_t as a va_args function doesn't work, as you end up with arguments being in the wrong place. Restore the Linux only xdrproc_t prototype that 167e1aa21f5bbea1272b239dc6518a7bdbfc3ee6 removed, add a warning to explain why its there, and modify xdr_free() so that it works without error. Change-Id: I789d387b01fcb892b187fe05f961f01c2c1f55e4 Reviewed-on: http://gerrit.openafs.org/1202 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cad1df43d89d829f36c9aa72e648bab827a2ea53 Author: Simon Wilkinson Date: Mon Feb 1 14:12:05 2010 +0000 Darwin: Stop CM builds when errors occur Make the kernel module build on Mac OS stop when errors are encountered, instead of just ploughing on regardless Change-Id: I489357c04cb7c78663f593af2c2adbc50ebfffff Reviewed-on: http://gerrit.openafs.org/1203 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7d3398f48d15fc4e334e4f1acbf6b7156f0ab522 Author: Marc Dionne Date: Mon Feb 1 19:31:05 2010 -0500 Linux: warning fix in osi_file.c Cast printed variable to avoid a warning about a mismatch between %d and long int. Change-Id: I3245cbb5e4780a258e8756b4210c1078f4fbc51c Reviewed-on: http://gerrit.openafs.org/1195 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c75396e23a50a144de6d08d57304c1803722ead2 Author: Simon Wilkinson Date: Tue Feb 2 00:03:04 2010 +0000 Linux: Fix breakage in llseek error handling Commit 7a5cee30cc5f0e6d5780387633ce2b46608fd5fb changed the way that errors from llseek are dealt with. Unfortunately, it is missing some all important bracing, and so we end up going down the error path, even when the llseek succeeds. My fault. Sorry. Change-Id: I03061ba0663b610a8fb73a08d257f6d786795076 Reviewed-on: http://gerrit.openafs.org/1194 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a97fffc08a02ad8583c7f7b50d41fe07c93520b8 Author: Jeffrey Hutzelman Date: Mon Feb 1 16:59:14 2010 -0500 call afs_osi_suser correctly in PNewUuid we were using the wrong level of indirection on acred. fixed. Change-Id: I00ab1a97b42717adc2d9d26e885b91c44103ab1d Reviewed-on: http://gerrit.openafs.org/1190 Reviewed-by: Jeffrey Hutzelman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 43bcd4db710cec13e14e3e53a3e5ce1f995153d7 Author: Derrick Brashear Date: Mon Feb 1 00:00:39 2010 -0500 make 1.5.71 for unix version updates for unix Change-Id: Ia7901e3969b3afb72b870e7bfaf1be931c2fb0c5 Reviewed-on: http://gerrit.openafs.org/1185 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e1fd1f60d37bdb37e79883045caf17b7ecbd07ba Author: Jeffrey Altman Date: Sun Jan 31 23:27:32 2010 -0500 Windows: ChangeLog and Version Number for 1.5.71 Change-Id: I0969e2b3fcff98489aef1b0e660ef12149a4b96c Reviewed-on: http://gerrit.openafs.org/1184 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0683c04a61ab8946fe715500888a983172298972 Author: Chas Williams Date: Wed Jan 6 16:48:41 2010 +0000 Unix CM: Always use ->storeproc() Always use ->storeproc() and avoid branching "do or do not -- there is no try" Change-Id: Idbcf0c80930d6a433b4c921b44db28cb6fbbf9bb Reviewed-on: http://gerrit.openafs.org/1073 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d52213fcc5dae5095d660e1861f77e90c07bb2ab Author: Derrick Brashear Date: Sat Jan 30 13:54:20 2010 -0500 rx idledeadtime don't track window wait if we're in writer mode and waiting for more window, don't consider it idle. Change-Id: Id1e80f297929eef363ffe88bfe181b74bb331515 Reviewed-on: http://gerrit.openafs.org/1182 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b85929698b496baee34c7d9e0a7ad654a7f5ae33 Author: Simon Wilkinson Date: Fri Jan 29 17:47:12 2010 +0000 Darwin: Don't use ARCHFLAGS to determine arch The Darwin build uses ARCHFLAGS to control the architectures it builds binaries for. However, this causes problems for standalone builds which just do ./configure && make. So, if ARCHFLAGS is undefined, ask gcc which architecture it thinks that it is building for, and use that. Change-Id: If9e7dc3c41ded5ac0593ae20ddd741690914a699 Reviewed-on: http://gerrit.openafs.org/1181 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8b395497d5a464c57c65ba73ca757d47e4ff109a Author: Derrick Brashear Date: Fri Jan 29 12:59:59 2010 -0500 macos prefpane fat binary arch selection correction don't choose 64 bit arches for the prefpane if we're not on macos 10.6 sadly, this is the best i can do to conditionalize Change-Id: I31fb2e10fbef5c66a27e0170e8925513a1b63050 Reviewed-on: http://gerrit.openafs.org/1180 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b1d57791d4eadd3e0bc5de5b8654e7964b662b3e Author: Derrick Brashear Date: Thu Jan 28 11:35:56 2010 -0500 linux cache file open fail print error if we're going to oops, print a little more info about why. in this case, knowing why dentry_open failed would help Change-Id: I78a3c97d67c7c29110de975465cce0edd6367496 Reviewed-on: http://gerrit.openafs.org/1173 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 167e1aa21f5bbea1272b239dc6518a7bdbfc3ee6 Author: Derrick Brashear Date: Fri Jan 29 00:03:07 2010 -0500 xdrproc_t probably not really different on linux26 for some reason we prototype it differently. makes xdr_free sad. Change-Id: Icd6060acd922314fc400aa2fe360c662ec705fa6 Reviewed-on: http://gerrit.openafs.org/1179 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 008eb3c011d58375180f150b1591a0c0c4d07a24 Author: Chaz Chandler Date: Thu Jan 28 23:59:12 2010 -0500 further irix updates updating for non-c99 and for no vprintf in the irix kernel Change-Id: Id7239dae35ff195007c615319522827d06395f8f Reviewed-on: http://gerrit.openafs.org/1178 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 054e853922b98984ed25b5482fb4f5cd4e5efdf5 Author: Derrick Brashear Date: Thu Jan 28 18:12:44 2010 -0500 afsd missing close brace fallout from the open-by-path-only unification Change-Id: I06f6a7bbb45368b5ab8c336e93ffae11af6b3fac Reviewed-on: http://gerrit.openafs.org/1176 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2ca0c2828d48cd377e9cfc2e325a1ff6011ce18b Author: Derrick Brashear Date: Thu Jan 28 00:35:36 2010 -0500 ignore generated macos packaging description file added ignore for OpenAFS.Description.plist as it is now generated Change-Id: Icbad9f8bbbdd5be6604838366d14f648eec05ee4 Reviewed-on: http://gerrit.openafs.org/1171 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a340dc7981cb75cee66defd4cec5becdb4b7dfea Author: Derrick Brashear Date: Thu Jan 28 14:22:53 2010 -0500 irix cc defaults to pre-c99 no xdr labels for irix Change-Id: I4e1ca001d62a0a3d1f2f6ddef4b6419d1b2b2c13 Reviewed-on: http://gerrit.openafs.org/1174 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fca5ace4da5e685fdf665ff8f6e70bcab76eeaae Author: Derrick Brashear Date: Thu Jan 28 14:25:32 2010 -0500 irix can't have vprintf in the kernel vprintf doesn't exist for irix either. deal Change-Id: I60f78feaf36dbbb086e2ea9e6f7a839c76074647 Reviewed-on: http://gerrit.openafs.org/1175 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9e4477fbfb212bcaaa6c9324ed992dd769502737 Author: Jeffrey Altman Date: Tue Jan 26 10:23:03 2010 -0500 Windows: drop cm_Freelance_Lock before call to cm_FreelanceAddMount The cm_Freelance_Lock must not be held before calling cm_FreelanceAddMount(). cm_InitLocalMountPoints() was violating this requirement. It is safe to drop the lock because the only time the lock would be dropped is if the "Freelance" registry key does not exist. This should only be true during the initial startup of the application the first time afsd_service.exe executes on the machine. At this point in time there is only one thread that is executing that could be initializing the Freelance mount point list. LICENSE MIT Change-Id: Ib49cf8bc830836c8e08446073e64ccf30086d354 Reviewed-on: http://gerrit.openafs.org/1164 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 3a986e9b8aeacf1a23f6f06e301999d4a2dd2cb5 Author: Jeffrey Altman Date: Wed Jan 27 14:09:19 2010 -0500 Windows: export xdr_serverList and xdr_Capabilities from afsrpc.dll Required by new xdr_free() usage. Change-Id: I585947f110204c9043f92fc573d5d7263a46fd64 Reviewed-on: http://gerrit.openafs.org/1170 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit a3812f211a56c0d6e0a7ff8a97f157707d3d8c28 Author: Marc Dionne Date: Tue Jan 26 19:48:24 2010 -0500 Linux: don't count pag keys against root's keyring quotas Keys associated with PAGs are created with root ownership for security reasons, which means that they count agains root's keyring quotas. The default configuration used by most distros restricts root to the same quotas as a regular user, so a single user can potentially fill up the quota and prevent new pags from getting created system-wide. This can also be an issue for busy multi-user systems where the default maximum number of keys (200 currently) can easily be reached. Change-Id: I37e3f3d881facff9b14f2057b404d4b441e72305 Change-Id: Id1ef2d5a7109d8ee7c08aa81dfd98ecf951c8ba8 Reviewed-on: http://gerrit.openafs.org/1167 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c51e2661835b4499f1125eb2d677a06260159dbc Author: Derrick Brashear Date: Wed Jan 27 12:58:49 2010 -0500 init pthread mutexes only if an initializer exists and windows has none Change-Id: Iaff3047abde197791e3fbb42c12066f896e540d1 Reviewed-on: http://gerrit.openafs.org/1169 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 900dc5b31baea50370fba93b1f96002ad6652c8d Author: Derrick Brashear Date: Wed Jan 20 11:38:43 2010 -0500 switch to always attempting cache-config-by-path solve the "are we built for linux fh or inode" problem: just always use path. Change-Id: I076ee495b29e4a2dc964ce04001f86e100528fb6 Reviewed-on: http://gerrit.openafs.org/1133 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f02f2e80267fb45c22ab199dee0e0c15425674b6 Author: Simon Wilkinson Date: Wed Jan 27 02:30:09 2010 +0000 XDR memory management fixes Change the xdr_free function so that it matches in signature and behaviour the xdr_free that is available in other xdr packages, and update all callers. Don't use xdr_alloc where the data we're allocating isn't freed by xdr. The only place where xdr_alloc is required is in server stubs when filling OUT parameters. Change-Id: Ice231f163726afc374cb25a89302e3d82fa1e093 Reviewed-on: http://gerrit.openafs.org/1168 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0559a23d38f98280e2eb1c1e2fc91ae7a1798537 Author: Derrick Brashear Date: Tue Jan 26 13:32:03 2010 -0500 initialize pthread mutexes to avoid compiler common variable stupidity instead of worrying about ranlib versus ranlib -c, -fno-common, etc, just initialize the variables if an initializer exists Change-Id: I6ed28df4d2134f84359a1bc55706e75d54e6e083 Reviewed-on: http://gerrit.openafs.org/1166 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f3da1f9e1af4daa5b6f3ec46bad3db5226377fc4 Author: Derrick Brashear Date: Mon Jan 25 16:49:53 2010 -0500 rx ResetCall should wait if it says it will We set TQ_WAIT... and then don't bother to wait. uh. Change-Id: Ia7d3e52c8880db53fcf26b7d79ad349720018701 Reviewed-on: http://gerrit.openafs.org/1160 Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit f0b1d7ccbbc4056338dde92c8b131ad2070351ad Author: Derrick Brashear Date: Mon Jan 25 16:02:23 2010 -0500 rx avoid discarding packets while tq is busy we don't check here that no one else is working the tq *after* getting the lock. do so. Change-Id: I91d1ac020334b038a6a045734911335299613875 Reviewed-on: http://gerrit.openafs.org/1159 Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 14e050033f40272a919bb54e981d8165d927240a Author: Derrick Brashear Date: Tue Jan 26 12:27:11 2010 -0500 viced detailed stats should record stored bytes correctly if we get an error reading data, don't subtract it from the length stored statistic Change-Id: I2fec260a9f677c0747ff2c6f975745ccb1e58447 Reviewed-on: http://gerrit.openafs.org/1165 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 73392259ec523fd9648e2c589d491050066d84d7 Author: Derrick Brashear Date: Mon Jan 25 12:36:25 2010 -0500 darwin80 if changes cleanup fix the indirection here to be correct. ifnet_list_get needs a pointer to a pointer for the ifnet structure Change-Id: I81bd7c383c63cc1e312fcfd482d7162d50f6f1d3 Reviewed-on: http://gerrit.openafs.org/1158 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0b7669d937ca7a34b69163963be8cbfa6db31094 Author: Derrick Brashear Date: Mon Jan 25 10:44:54 2010 -0500 darwin rx if structure fix link kernel to correct ifaddr symbol for withnet Change-Id: I384974bef73b9cc44eba7ddba43f28f65c03f39b Reviewed-on: http://gerrit.openafs.org/1157 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e58f77fe56b69e82ab82698b93ee011d272676cf Author: Derrick Brashear Date: Sun Jan 24 11:25:00 2010 -0500 pagsh dependencies don't get to include system libs we'll never be able to "build" -lresolv revert this part Change-Id: I2b1caa5bffc3d826412967fb70d9eadf8223f1f8 Reviewed-on: http://gerrit.openafs.org/1154 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7a5cee30cc5f0e6d5780387633ce2b46608fd5fb Author: Simon Wilkinson Date: Mon Jan 25 00:02:11 2010 +0000 Linux: Handle llseek failure If llseek fails, then we return immediately, potentially leaving the wrong address space configured for this process, and without resetting the processes saved limits. Fix this by creating a common exit point for osi_rdwr, and using it. Change-Id: Ifff8cb0155f92a4130d21828d5ee2d2a55c09195 Reviewed-on: http://gerrit.openafs.org/1155 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a16e6f396464bd860d08b9fec1f37f96ea8ac30a Author: Derrick Brashear Date: Sun Jan 24 10:09:41 2010 -0500 unix 1.5.70 make 1.5.70 for unix Change-Id: I84ed384e9cd38e49a2c002a4ffe19a6ff5ba633d Reviewed-on: http://gerrit.openafs.org/1153 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit aacc766252aacadf8f6e3ab234ba77bfeb61714e Author: Jeffrey Altman Date: Fri Jan 22 14:24:17 2010 -0500 Windows: 1.5.70 ChangeLog updates Version number updates Change-Id: I16fd2d2ef507cc862417eef8d221ea5ba58567a1 Reviewed-on: http://gerrit.openafs.org/1146 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 0caf14224a9153bb488be9e52d67892a2c441a5a Author: Marc Dionne Date: Fri Jan 22 20:03:58 2010 -0500 Linux Keyrings: don't ignore error code from session keyring creation Creating a session keyring can fail, for instance if the user's keyring quotas are reached (number of keys/keyrings or data size). Instead of ignoring errors, return them so they can be passed back to the caller. FIXES 126230 Change-Id: I745abeef4b3b8e4c3ab1b90667c6a5478c1e0ad2 Change-Id: I4b0ce6423ee493fbbcbdac1c580e3a157d3c11f4 Reviewed-on: http://gerrit.openafs.org/1151 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8462b1a1b2272eab004ed266a1bd9ffaf51266f3 Author: Marc Dionne Date: Fri Jan 22 20:05:34 2010 -0500 Add missing dependencies for pagsh in Makefile Make pagsh and pagsh.krb depend on the libraries that are used to link them, and on the source file pagsh.c Without this dependency, modifying pagsh.c would not trigger a rebuild of the executable. Change-Id: I9ed20ce69f10916f97d6c335be9bb8374fb9ecd1 Reviewed-on: http://gerrit.openafs.org/1150 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b1eb6a7a3f80500f0187cc6a1dd2013e1a5e154a Author: Simon Wilkinson Date: Fri Jan 22 20:11:21 2010 +0000 Don't throw data away in afs_StoreMini afs_StoreMini had some interesting error handling. Instead of returning the error code from StoreData, it would return the error from EndCall, potentially masking the StoreData error. When it encountered an error it would discard all of the cached data. StoreMini's only caller is afs_StoreAllSegments. If StoreAllSegments is called from DoPartialWrite, then it squashes the error code. This combination could lead to the user's data being disposed of, without an error being reported. Fix all of this by not invalidating segments in StoreMini. Make StoreMini static to make it clear its only used by StoreAllSegments, and fix the error handling in StoreMini so that StoreData errors always take priority. Change-Id: I41f0c753655fac343485d2a473ad70b6ae96bb78 Reviewed-on: http://gerrit.openafs.org/1147 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 637e1eac97c2e9c0f0354cfff1a83deddb4ae24f Author: Simon Wilkinson Date: Fri Jan 22 21:50:44 2010 +0000 Revert "Fix afs_AccessOK for dropbox case" This reverts commit 3f89c0feae89e9a255afb8a7f08995412a3f1b79. That change broke the expected semantics of a drop box, by opening up read() access to users to whom it would usually be denied. The expected dropbox behaviour is that whilst anyone can write a file there, only those who are specifically given r permissions may read it. Change-Id: I025cef7cad1031fbed1e914d58a0a515561f3f78 Reviewed-on: http://gerrit.openafs.org/1149 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d9cef89c93d33985c43c0bf5d28d96955bb0e457 Author: Derrick Brashear Date: Thu Jan 14 15:41:23 2010 -0500 abstract rx if structure access change things to use accessor macros styled after the mac KPI where feasible, and make access consistent. Change-Id: I284101b370666e1aeb8e42bc1a651a2781a9af78 Reviewed-on: http://gerrit.openafs.org/1101 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f02ab3339d01bca414fe705f3a990a1db146f29b Author: Russ Allbery Date: Fri Jan 22 10:59:14 2010 -0800 Enable weak enctypes for klog.krb5 if supported by Kerberos The same as cb4b62a40352ccebae3a299f4327fa70fc7a0c5c, but for klog.krb5. Current versions of both MIT Kerberos and Heimdal disable DES enctypes by default, but DES enctypes are still required for AFS service tickets. Probe for either krb5_allow_weak_crypto() (MIT Kerberos 1.8) or krb5_enctype_enable() (Heimdal) and, if found, call them to enable DES enctypes. If neither is found, assume that the Kerberos libraries are old enough that DES is enabled by default. Change-Id: I99c93621c847f6edcc485207f5b6b99b2370b347 Reviewed-on: http://gerrit.openafs.org/1144 Tested-by: Russ Allbery Reviewed-by: Derrick Brashear commit 3f89c0feae89e9a255afb8a7f08995412a3f1b79 Author: Andrew Deason Date: Thu Jan 21 20:42:33 2010 -0500 Fix afs_AccessOK for dropbox case afs_AccessOK did not check for if we have 'i' rights on a directory, nor if we were the owner of a file, if we were only checking PRSFS_READ or PRSFS_WRITE. Thus, it does not correctly address the 'dropbox' permissions case (if you are the owner of a file and have insert permissions, you get implicit 'r' and 'w'). Fix this to check for 'i' and ownership when we need to, so the dropbox special-case check works as intended. FIXES 126216 Change-Id: Ib629bc30b73bc3965e777747067259451f0adff6 Reviewed-on: http://gerrit.openafs.org/1143 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cb4b62a40352ccebae3a299f4327fa70fc7a0c5c Author: Russ Allbery Date: Thu Jan 21 15:41:49 2010 -0800 Enable weak enctypes for aklog if supported by Kerberos Current versions of both MIT Kerberos and Heimdal disable DES enctypes by default, but DES enctypes are still required for AFS service tickets. Probe for either krb5_allow_weak_crypto() (MIT Kerberos 1.8) or krb5_enctype_enable() (Heimdal) and, if found, call them to enable DES enctypes. If neither is found, assume that the Kerberos libraries are old enough that DES is enabled by default. Change-Id: Ib5231bb7c2fe88f4c424628394ed08122d5710a1 Reviewed-on: http://gerrit.openafs.org/1141 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ddc64898e7b3a26e6514be63ef01672fe67cb851 Author: Marc Dionne Date: Thu Jan 21 17:53:42 2010 -0500 afs_vnop_attrs: syntax error in conditional expression Add a missing && in a 2-line condition. Not sure how this could have compiled successfully on the affected platforms. Change-Id: I2e8b791c6d8cd09795be1ef52c078ebfa5a3e53b Reviewed-on: http://gerrit.openafs.org/1140 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 14ffee4bbc1c8df93110ae1b86edb2a172aae091 Author: Jeffrey Altman Date: Thu Jan 21 20:05:25 2010 -0500 Windows: AFS_AFSDB_ENV preprocessor symbol no longer exists The decision to add AFS_AFSDB_ENV to make code consistent was a mistake. The preprocessor symbol no longer exists. AFSDB is broken in 1.5.69. Change-Id: I7ea147b824f3a67e2039abee8b2513af175fcc5d Reviewed-on: http://gerrit.openafs.org/1142 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 0342cdb2d3710f7d56a5b93ca8aedf7b2df835fc Author: Jeffrey Altman Date: Thu Jan 21 17:38:43 2010 -0500 Windows: add build and clean rule for bc.h Add a dependency rule to build bc.h before it is installed Add cleanup rules to delete bc.h and other installed files. Change-Id: I9a40fd64aff048bfc87b9fd823ae7499816cb3e5 Reviewed-on: http://gerrit.openafs.org/1139 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit d8bda273b09ed7d7b7395390f58891913e5fafdc Author: Jeffrey Altman Date: Thu Jan 21 16:43:18 2010 -0500 Windows: Windows v6.0 SDK does not define __RPC__out The Windows v6.0 SDK does not define __RPC__out in the rpcsal.h header file. The preprocessor symbol was added in the v6.0A SDK update. In case the v6.0 SDK is used with the 6000 WDK, add a symbol declaration. Change-Id: Iecce566e906977f41be00efb458753acd09f7949 Reviewed-on: http://gerrit.openafs.org/1138 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 7a5d90b7735e4047eb926dc03dbaafce556bccfe Author: Jeffrey Altman Date: Thu Jan 21 15:34:49 2010 -0500 Undo labeling of elements of rx structures for Windows Change I006bbbdb8923dbb72a97fde931a1b23e303375c2 broke the Windows build. Restore the unlabled assignments for Windows since Windows always uses the AFS xdr implementation. Change-Id: I2eadc624d84f4100281424993b7287a330d6c753 Reviewed-on: http://gerrit.openafs.org/1136 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 18ace069417cde36b2af8439c375fd247ed4d8aa Author: Jeffrey Altman Date: Thu Jan 21 15:30:23 2010 -0500 Install bucoord/bc.h to permit Windows to build Change I0a0ae92d3c7ba75e4a331bf59ea9c031763cc704 broke the Windows build. Fix it. Change-Id: I08db225790a37eee3e4fd778eacabc7168abee77 Reviewed-on: http://gerrit.openafs.org/1135 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7f1046896ee14d3e7ee6975e70cd1a9bb9f24736 Author: Marc Dionne Date: Wed Jan 20 21:03:08 2010 -0500 Warning cleanup: implicit function declarations in butc and bucoord Cleanup some prototype related warnings under bucoord and butc: - Copy a few prototypes from bucoord_internal.h to bucoord_prototypes.h, since they are used in other source directories - Install bc.h under include/afs, and include it in tcmain.c - Include bucoord_prototypes.h in tcmain.c - Add a prototype for GetResponseKey - Remove warning inhibition for tcmain.c, and entry in README.WARNINGS - Remove warning inhibition for bucoord/dump.c (no entry in README) Change-Id: I0a0ae92d3c7ba75e4a331bf59ea9c031763cc704 Reviewed-on: http://gerrit.openafs.org/1134 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 21cbf7fee0a089d94f62baa7df2422e7bc8293f7 Author: Derrick Brashear Date: Wed Jan 20 11:15:29 2010 -0500 simplify ufs cache mechanisms available instead of having use_fh for linux, vnode_path for solaris and darwin, use the same mechanism for both. for darwin/solaris we cache the path (tested via gop_lookupname) instead of an fh, freeing the path at shutdown. Change-Id: Id22052db0803264bdaba6b870d9e511953e348bc Reviewed-on: http://gerrit.openafs.org/1132 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 1b7836e44f33c8dccc486aa49a25e9fe5a2d5aed Author: Derrick Brashear Date: Tue Jan 19 01:29:11 2010 -0500 batch panic decoding for MacOS add support for decoding (nominally) any panic for MacOS. Limited testing. Requires hdutil from http://www.dementia.org/~shadow/dmgutil-0.1.tar.gz to extract files from DMGs. now with support for cross-version debugging, when run on 10.6 (e.g. with kextutil) Change-Id: I5d9db005e3014e22f916070f8af25271a28615ea Reviewed-on: http://gerrit.openafs.org/1125 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit be916b0f009e3c643da5cd928907a28629cc9726 Author: Derrick Brashear Date: Mon Jan 18 19:25:02 2010 -0500 macos set don't backup attribute on cache files hint to time machine that cache files should not be backed up Change-Id: I098c9231139b91ff093be74d8a39f94c185d478c Reviewed-on: http://gerrit.openafs.org/1122 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 04e6ddb60bf3ce4ddfe7a5d6e4950fb25d2a3f86 Author: Simon Wilkinson Date: Wed Jan 20 13:13:58 2010 +0000 Fix so that UKERNEL can keep using system xdr This fix modifies the way that the RX XDR operations are declared so that UKERNEL can continue using the system provided XDR glue, rather than using our own (as is the case in userspace, and in normal kernel modules) Change-Id: Ib6abad376c7f7a7f0f5c2314efe80f5b7b44f842 Reviewed-on: http://gerrit.openafs.org/1131 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f18a6c36b38ed8422eb6ed5e43cebaa3d212917c Author: Simon Wilkinson Date: Sun Jan 17 18:34:03 2010 +0000 Label elements of rx structures Label all of the assignments to the xdr_ops structure. This allows the rec, stdio and mem variants to continue to function, even when the ordering of the elements has changed in the header. Change-Id: I006bbbdb8923dbb72a97fde931a1b23e303375c2 Reviewed-on: http://gerrit.openafs.org/1126 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5dddb87eb362c824dee4b0340a95ca929c71d26f Author: Russ Allbery Date: Tue Jan 19 17:43:35 2010 -0800 Avoid executable headers in local include tree sys_prototypes.h, afs_AdminErrors.h, and afs_Admin.h were being installed into include/ in the build tree via ${INSTALL} instead of ${INSTALL_DATA}. rx_prototypes.h was executable in the repository. Install header files non-executable and make rx_prototypes.h non-executable for cleanliness. Discovered by Lintian because the executable permissions were duplicated by make libafs_tree. Change-Id: I609b62f69d1fecc2cdbba7e7442d93e9675c2fa0 Reviewed-on: http://gerrit.openafs.org/1129 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 340d3be82aa6d1fbaa0c775fe743f86e5a7335ed Author: Jeffrey Altman Date: Mon Jan 18 22:23:54 2010 -0500 Windows: Help text update for Network Identity Manager Provider Update the NetIdMgr provider help text to better describe its functionality. (Or at least not be incorrect.) Change-Id: I5d6b18f15cab7c48751666e754223ee68fb18d11 Reviewed-on: http://gerrit.openafs.org/1124 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit e010c8e9379bd2fa9b08a142e57cee56c123791c Author: Asanka Herath Date: Mon Jan 18 16:47:31 2010 -0500 Windows: Add a context menu for the AFS icon The OpenAFS plug-in for Network Identity Manager displays an icon in the notification area that displays status information about the AFS service and tokens. Add a context menu to the icon so that users can open the NIM application and get help for the plug-in from the notification icon. Change-Id: I704934b4f4eab72a18c54ef2a7a7dc3ca248ba78 Reviewed-on: http://gerrit.openafs.org/1121 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit b0ff95e2ee26f04dd7b03172acca075ddcd963a8 Author: Jeffrey Altman Date: Sat Jan 16 11:07:23 2010 -0500 Windows: Version number update for 1.5.69 Change-Id: I8af0167649cfeec95e5a5e5a72faeaccdeb92102 Reviewed-on: http://gerrit.openafs.org/1115 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e33a7346a6b9153daf593ae4c084ce3839f822cf Author: Jeffrey Altman Date: Sat Jan 16 11:05:57 2010 -0500 Windows: ChangeLog for 1.5.69 Change-Id: I078f719c6e769cfcb7997bb8b67403de480255f9 Reviewed-on: http://gerrit.openafs.org/1114 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 97d0d22e34dbb1e927c90695e55ee582c51f9e64 Author: Derrick Brashear Date: Mon Jan 18 19:59:28 2010 -0500 make 1.5.69 for unix set version number for unix Change-Id: I2273e97ec43fd172e6f486ab6226cc6376885163 Reviewed-on: http://gerrit.openafs.org/1123 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cc47e765912e1a5dedddb6ef00ca8b8c8d567f0e Author: Derrick Brashear Date: Sun Jan 17 01:10:28 2010 -0500 create debugging kext package for MacOS this creates and installs a debugging kext package for macos. it also always installs the decode-panic script (which can be used even without the debug kext) Change-Id: Iff03de66cd3df2690f03333e6629d21660364cd1 Reviewed-on: http://gerrit.openafs.org/1120 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9f79dde2c804e943c2d6f7deaa00c6997b991691 Author: Marc Dionne Date: Sat Jan 16 17:40:52 2010 -0500 More pam warning cleanups - test_pam.c Clear up a few more warnings in the pam code. The changes here are very similar to the ones in the previous patch and use the same configure test: - use PAM_CONST to conditionally declare pam_message as const - cast a few arguments to putenv, which expects a non-const pointer Change-Id: I6c98623c35f4453f34c1d48b8b7d6ff1bfbc1e0c Reviewed-on: http://gerrit.openafs.org/1116 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fdee40d8eac5466dff3969183debd422df60c269 Author: Marc Dionne Date: Sat Jan 16 16:29:10 2010 -0500 up.c: remove unused variable pageSize Variable pageSize is declared and set to the system page size using getpagesize(), but the value is not used anywhere. getpagesize() doesn't necessarily have a prototype declared in unistd.h with recent glibc, which can generate a new warning and trip up an enabled-checking build. Instead of trying to put in a workaround, just remove the unused variable. Change-Id: I6a9519eb2642bb0479edd1cf1195ce3f751c72bb Reviewed-on: http://gerrit.openafs.org/1117 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 41ae68f2986709daecd1b00a91919df8b2d9581f Author: Marc Dionne Date: Sat Jan 16 18:57:24 2010 -0500 uss: Fix IP address parsing and cleanup warnings In uss_vol_GetServer(), the IP address octets are scanned into "char" variables, and later cast to afs_int32 to build the address. sscanf gives warnings because it's expecting an int pointer, and testing shows that this code doesn't work as expected - the first 3 octets are always parsed as 0. Use afs_int32 variables instead, which works, eliminates warnings and simplifies the code. Note that this code does not seem to be reachable currently. It was probably meant to be used by planned additional uss commands. Change-Id: I646d4cbfa8ac0d0c50f98a334ac3fe387d6d361b Reviewed-on: http://gerrit.openafs.org/1119 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ad48e6fb1f8749a059696612ad503aea28c4707d Author: Asanka Herath Date: Fri Jan 15 15:39:12 2010 -0500 Windows: Query the MTU value from the registry The syscfg_GetIFInfo() call uses the interface info returned by GetAdaptersAddresses(). Also manually query the MTU value in the registry for any interfaces bound to the same adapter and use the smallest such MTU as the value returned by syscfg_GetIFInfo(). Change-Id: I8a1d487b51f6674ff6ebbf6b1f20d37b1e278279 Reviewed-on: http://gerrit.openafs.org/1105 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 806423be3c55f3de91c2b836d2088eeb0f4e4665 Author: Simon Wilkinson Date: Sat Jan 16 15:35:34 2010 +0000 Don't double free call structure If the rx_Read() of the number of bytes in the FetchData64 response fails, then it sets code, and disposes of the call structure. However, the length safety check that was added in c7b92a3018044f7aca4d9a77644e5c06ef64d1e9 executes regardless of whether code is set, and the call has already been freed. So we end up calling rx_Error with a NULL call structure, and panic. Change-Id: Ia2e341b7a9a2ddc1d656e8b8a31698c0d1771d5e Reviewed-on: http://gerrit.openafs.org/1112 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3c57a1a85a2b3299b7b38557c95ff79a77dc3252 Author: Simon Wilkinson Date: Sat Jan 16 02:15:36 2010 +0000 Linux: Add missing prototype 6e65ffbb6c520bf1c28356206410363d8eb36d78 added osi_get_group_pag. On most platforms this is static, but on Linux it's provided by the OSI layer. Add a prototype so the compiler doesn't go boom. Change-Id: I106fa5d5299f8ed486e70cea2ea8681b43a81a33 Reviewed-on: http://gerrit.openafs.org/1110 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f5cfa4cf7345e3d36c44f9bc01e0c70762e366b9 Author: Simon Wilkinson Date: Sat Jan 16 02:09:34 2010 +0000 Unix CM: Fix negative file length case, again As originally noted in f6f9ee5402f1718f330a00ec89fb34b05c3cd360 some fileservers return a negative length, typically when a client is attempting to fetch data that is past the extents of the file, the CM needs to retain this negative length, and handle it correctly. c7b92a3018044f7aca4d9a77644e5c06ef64d1e9 added safety checks for the fileserver returning a length larger than that asked for by the client. Sadly, this check does a comparison between a signed, and an unsigned, variable. This leads to it incorrectly classifying negative responses as being too large. Add a cast, and a comment, to fix this. Change-Id: I2ca67f55204c565667d5cd91cde3d520f8d9b10c Reviewed-on: http://gerrit.openafs.org/1109 Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit df702210275453e0d2362b0e142d82bfaf14406c Author: Jeffrey Altman Date: Fri Jan 15 09:06:05 2010 -0500 Rx: Correct AFS_NT40_ENV rx_GetIFInfo max MTU assignments On UNIX, the rx library values for rx_maxReceiveSize and rx_MyMaxSendSize are sent by the cache manager directly. In Windows, they are set by rx_GetIFInfo() which had two errors. (1) The comparison of rx_maxReceiveSize and maxsize were reversed which prevented rx_maxReceiveSize from ever being set to the interface MTU. (2) rx_MyMaxSendSize was never assigned a value. As a result, two problems occurred. (1) The remote peer was never told about the local MTU. (2) The local peer ignores the MTU. From 1.3.60 to 1.5.33, OpenAFS for Windows installers provided a registry default RxMaxMTU of 1260. This caused the cache manager to call rx_SetMaxMTU() which in turn set both rx_maxReceiveSize and rx_MyMaxSendSize in effect masking these errors. Change-Id: Ib05927d7985052e233ff6f4bd170a939eb05c320 Reviewed-on: http://gerrit.openafs.org/1107 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit c5d9f23cde1a024835582536e56cf4ea1652b7a8 Author: Jeffrey Altman Date: Fri Jan 15 09:18:50 2010 -0500 Rx: Do not drop call lock in rx_WriteProc* and rx_ReadProc* rx_WriteProc and rx_ReadProc has special fast logic that handles the most frequent case. This code was called without obtaining the call lock. However, each of these functions must obtain the call lock for the queue_IsNotEmpty() test and must re-obtain the call lock if the rxi_XXX variant is required. Dropping the lock and re-obtaining it is more expensive than holding it across the memcpy. Therefore, we shouldn't drop the lock until we are done. Change-Id: Icca679567994e91bbbf3afec72b863d986f86582 Reviewed-on: http://gerrit.openafs.org/1108 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Jeffrey Altman commit c1b74af7504e699ac831c81d0d7556ca36239298 Author: Jeffrey Altman Date: Fri Jan 15 09:00:41 2010 -0500 Rx: Remove last remnants of DJGPP support DJGPP code just clutters the AFS_NT40_ENV specific code but is never built. Change-Id: I90192bb5cf35239fdbbeaa28f85d1381162f3bae Reviewed-on: http://gerrit.openafs.org/1106 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d4c97c0017be80c798206767c750e0855ee6c015 Author: Marc Dionne Date: Thu Jan 14 18:56:49 2010 -0500 src/pam warning fixes The second parameter to pam_conv() should be a const pointer on recent systems. Make it so to eliminate a couple of warnings. A configure test is added to deal with some systems where pam_conv() might not be const. Cast a few assignments to cell_ptr in afs_auth.c and afs_setcred.c since the argv parameter is const. Change-Id: I5757310c94a6f26ca7dab656edaa416d16e32e2a Reviewed-on: http://gerrit.openafs.org/847 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 62e4bf7ddd99d6958cde8dc3639ff4305fb66556 Author: Asanka Herath Date: Thu Jan 14 19:15:03 2010 -0500 Fix typo in AdminGuide -> Change-Id: If0f8183f59f038b1b5e033d5ebd2607b5091f6da Reviewed-on: http://gerrit.openafs.org/1103 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit d4f6ece19b05f2233e53f2d3c59f92316ec5ec3a Author: Dan Hyde Date: Wed Jan 13 14:38:47 2010 -0500 volmonitor keep vtrans lock VolMonitor must maintain the VTRANS lock the whole time it is walking the allTrans list. Failure to do so can cause core dumps trying to access memory that has already been free'd. Two versions of this change were coded and tested. The other version used the VTRANS lock only around a THOLD, but needed a TRELE, too. Timing tests were run counting the number of vos status, vos listvol, and vos backupsys operations that could be performed during a fixed number of vos status operations. The THOLD/TRELE version caused other vos operations to run about 5% slower. FIXES 126110 Change-Id: I7e749d30c955867faacafa978d7d643dee648ca3 Reviewed-on: http://gerrit.openafs.org/1098 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 64778fd7bece52360482f9a51f19b34dac1d2678 Author: Simon Wilkinson Date: Tue Nov 17 20:46:17 2009 +0000 Kernel is always defined When we build the kernel module, either in the real or the ukernel case, KERNEL is defined. So, remove the #ifdefs around our locking primitives, so that things are a little bit clearer. Change-Id: I60893cc630d8cd4dd6cb11cdc44e8bf4f2f9f863 Reviewed-on: http://gerrit.openafs.org/838 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1a027a3ee151c7f77bbfa74c8002c8ff4b406985 Author: Simon Wilkinson Date: Tue Nov 17 19:52:15 2009 +0000 Move GLOCK initialisation to platform directories Rework the GLOCK initialisation code so that it's moved out into platform directories, rather than all being done in osi_Init. Change-Id: I1aae76ba12cd4e45f54881f5573ed1713159b64b Reviewed-on: http://gerrit.openafs.org/837 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 39b59269e5b7715c5a3017fb5e0a3e5222129ac5 Author: Chas Williams Date: Tue Jan 5 00:22:19 2010 +0000 rewrite afs_MemWriteBlk() using afs_MemWritevBlk() this avoids the code duplication of extending/shrinking cache entries Change-Id: Ieeae668caa506e934f92edf193b99dabdba2eabe Reviewed-on: http://gerrit.openafs.org/1062 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9984a95687ab23fea422bbf2b01d92caf33a24a1 Author: Chas Williams Date: Tue Jan 5 00:18:36 2010 +0000 Quick fix for readpages when using memcache Just don't do readpages if we're using memcache Change-Id: I6b8b45f291d106ad1303d5bea1caf7f910b7ecf4 Reviewed-on: http://gerrit.openafs.org/1061 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 18459cd32abe9aba75d46910f9a676e4a535e0da Author: Chas Williams - CONTRACTOR Date: Thu Jan 7 18:07:43 2010 -0500 afsd: decprecate -mem_alloc_sleep flag (and related code) On most platforms, afs_osi_Alloc_NoSleep() is already afs_osi_Alloc(). I have tested this on Solaris (the major exception) and haven't seen any problems. Change-Id: I0e8bfd76b2bd25889c1491633a3a6d50aceac510 Reviewed-on: http://gerrit.openafs.org/1079 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1544243167b0f294f080866710b3f29dec133f02 Author: Andrew Deason Date: Mon Jan 11 13:36:32 2010 -0600 Always check VInitVolumePackage2 return code Some programs were not checking the return code of VInitVolumePackage2. Although some programs do not care so much if we fail to properly init the volume package (SYNC debug tools), at the very least log/print an error, so it doesn't silently fail. Other programs are changed to exit when VInitVolumePackage2 fail, so e.g. salvages don't accidentally cause corruption on 'logging'-mounted UFS partitions. In any case, ensure the return code is always checked anywhere it is called. Change-Id: I164d5920a5ea2dd7e5ed9ad4ccc578e9bdf0db0b Reviewed-on: http://gerrit.openafs.org/1090 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 9b23804a82ea12b5d46e6ee2667ec05bed502081 Author: Simon Wilkinson Date: Wed Jan 13 17:28:24 2010 +0000 Remove weekly bosserver restarts Change the default so new installations of the bosserver have no weekly restarts. Update the manpage and XML documentation to reflect this change. FIXES 126138 Change-Id: Ic22b750a602f6d2a22be881f5e1b04cd4fa132ae Reviewed-on: http://gerrit.openafs.org/1097 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6e65ffbb6c520bf1c28356206410363d8eb36d78 Author: Simon Wilkinson Date: Sat Dec 19 23:58:54 2009 +0000 Linux: Rework PAG to group conversions The change to using a single group for PAGs on Linux led to a load of special cases throughout the code. This patch moves the OS dependent parts of this into the LINUX/ platform directory, and rearranges that file so that there is a clear distinction between the one and two group sections of the code. Change-Id: Ib6e6f081519b23494dcf731b4be689c006180c68 Reviewed-on: http://gerrit.openafs.org/1007 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d2ddc3b6cfb1bc05fa045360bc09d708fe9cf611 Author: Jeffrey Altman Date: Mon Jan 11 14:35:12 2010 -0500 Windows: remove signed vs unsigned error in smb_Init Use UINT_PTR instead of INT_PTR. LICENSE MIT Change-Id: Id10cd7b7a18688c9eee68e3eac9c20348519fd37 Reviewed-on: http://gerrit.openafs.org/1089 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 6789f170d64695907970f01c22ac6eb8c7b14d15 Author: Jeffrey Altman Date: Mon Jan 11 14:21:11 2010 -0500 Windows: Protect buffers in smb_WriteData from simultaneous writes smb_WriteData does not properly use CM_SCACHESYNC_WRITE to protect buffers from simultaneous writes. Instead of simply testing CM_SCACHESYNC_WRITE at the top of the while loop, the flag must remain set until the entire write completes. cm_SyncOp is now called once and cm_SyncOpDone is only called upon final success or error. In addition, as 'count' is unsigned, the test for count < 0 is replaced with count != 0. LICENSE MIT Change-Id: I82c8dc20e62079b13bf305e906f4744756aa0ac2 Reviewed-on: http://gerrit.openafs.org/1087 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 513a7e48a2e586bd687af75084cfdf955f37b42f Author: Jeffrey Altman Date: Mon Dec 21 12:35:12 2009 -0500 Windows: fs examine owner and group are signed Change the owner array to be signed for displaying owner and group within fs examine output. LICENSE MIT Change-Id: I807e3f1b3c07eb26c1782d6b76cd49977467ce33 Reviewed-on: http://gerrit.openafs.org/1017 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 57aac9734c12d12b12cb0f2c83a5d97c093a979e Author: Jeffrey Altman Date: Mon Jan 11 13:59:12 2010 -0500 Windows: do not call cm_SearchCellByDNS if AFS_AFSDB_ENV is not defined cm_SearchCellByDNS is only available when AFS_AFSDB_ENV is defined. Do not call it when it isn't. LICENSE MIT Change-Id: I203ab775513bd75ff6a547c557579c0bc095d555 Reviewed-on: http://gerrit.openafs.org/1086 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman commit 35ed0439e32b6aeffc4aee2601a08e0406302cbc Author: Jeffrey Altman Date: Mon Jan 11 13:51:42 2010 -0500 Windows: buf_Recycle should clean up flags and reset version The CM_BUF_EOF and CM_BUF_ERROR buffer flags and the buffer dataVersion should be reset within buf_Recycle() instead of by the caller of buf_Recycle(). LICENSE MIT Change-Id: I643da102553200b20f5ecc23ec43974581663a8e Reviewed-on: http://gerrit.openafs.org/1085 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman commit edc39892cbf60eb2f918180f0b4c217ac3bd6dab Author: Jeffrey Altman Date: Sat Jan 9 00:26:37 2010 -0500 Windows: do not leak scp->dirlock if cm_BPlusDirBuildTree fails In cm_BeginDirOp, the scp->dirlock would be leaked if cm_BPlusDirBuildTree() failed. This would either result in a panic later on if lock order validation is active; or as an inability to process subsequent requests on the directory. LICENSE MIT Change-Id: I03afd0c9e6296c0f43ae39e5a7b1ff29a1619a43 Reviewed-on: http://gerrit.openafs.org/1083 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman commit 6a96e0bf92e0a454e9d4fccf61402c033f374722 Author: Jeffrey Altman Date: Mon Dec 21 12:29:10 2009 -0500 Windows: alter nmtest CreateFile modes Change -r to open the file for FILE_SHARE_READ Change -w to open the file for FILE_SHARE_WRITE Change -w to open the file twice. Once for sequential access and once for random access. LICENSE MIT Change-Id: I295a7e7408e7e7eac06901108a726fe9e94bf18f Reviewed-on: http://gerrit.openafs.org/1016 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman commit 6f4ed82da9d941ac303eb2f886f95d97828119bc Author: Jeffrey Altman Date: Tue Dec 8 09:38:53 2009 -0500 Windows: return ENOMEM from cm_BPlus functions on malloc failure There are several cm_BPlus functions that do not return an error code on malloc failure. LICENSE MIT Change-Id: I3a3d78cc6d6844c78e51fa81ebf330f5af88a7a5 Reviewed-on: http://gerrit.openafs.org/900 Tested-by: Jeffrey Altman Reviewed-by: Rod Widdowson Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman commit 987f3bf9c7420bb555eccde3b7407080a760b641 Author: Simon Wilkinson Date: Sun Nov 22 23:31:00 2009 +0000 Use dget_parent to handle getting inode of parent We can't safely do dp->d_parent->d_inode to access the parent inode of a given dentry. Instead, use dget_parent() to get safely get a reference on the parent dcache, and access the inode using that reference. Dispose of this reference with dput() as appropriate. Change-Id: Ic4f2159f68f95744bca08ebc99ecd5f45dc46966 Reviewed-on: http://gerrit.openafs.org/1075 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 90f91f4464f5785290040436b2d8cbe4b8ed5810 Author: Matt Benjamin Date: Mon Jan 4 21:31:27 2010 -0500 freebsd: CM changes targeting RELENG_8 Force all vnodes onto the fs mount queue when allocated. This fixes a long-standing vnode recycling problem. Don't call vgone() on a vnode whose refcount is 0. Always destroy vnodes in VOP_RECLAIM. This is work in progress towards fixing old reclaim bug mentioned in Rees comment. Hold vnode returned from gop_lookupname_user in afs_pioctl_syscall, to avoid it going inactive before we're finished. Also unlock it if necessary. Don't use custom vop_lock impl when AFS_FBSD80_ENV. Remove duplicate conditional code in vnode pretty-print (old cruft). Also don't format fid members as hex. Revert vn_lock exclusve in osi_VM_StoreAllSegments (fixes deadlock introduced by me in a 2009 changeset). Remove unused variables in osi_VM_StoreAllSegments. Change-Id: I9fd146d6f405382a20a75523ec2b75c62ac6d17a Reviewed-on: http://gerrit.openafs.org/1068 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7c24f660474dea82a96e6c65883e53c9ad77379f Author: Andrew Deason Date: Thu Dec 17 13:59:57 2009 -0600 DAFS: avoid saving fileserver state when panicing When ShutDownAndCore is called with dopanic=1, avoid trying to save fileserver state. When we are panic'ing it is very possible that the thread that called ShutDownAndCore is one of the background threads we are waiting for, or that the calling thread is holding H_LOCK. Since we are panicing, the fileserver state is probably not consistent anyway, so just avoid trying to save state altogether, and avoid a possible deadlock. Change-Id: If727808bfdfda74a4ec0e65b27ef9c77fbee4aae Reviewed-on: http://gerrit.openafs.org/997 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit fe07f017f75b2ce0f783bbd8f31eb5b1bcd7c61b Author: Andrew Deason Date: Fri Nov 6 14:05:16 2009 -0600 DAFS: Allow non-fileserver to schedule salvages Allow non-fileserver programs to schedule salvages through the fileserver via FSSYNC (VOL_FORCE_ERROR with the FSYNC_SALVAGE reason code). Also make the volserver schedule salvages this way when it encounters the appropriate errors. FIXES 124484 Change-Id: I03ecf6302436c35fec705cd6c84a40b7cdbf6f97 Reviewed-on: http://gerrit.openafs.org/787 Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 9a08865c36013e7e2c6b564588f5a2a6b2a9fd1e Author: Simon Wilkinson Date: Fri Jan 8 17:29:16 2010 +0000 Revert "Linux: Replace invalidate_inode_pages" This reverts commit 40719534d5d906f97a6ae7d28a00289270daf2a6. RHEL5 kernels publish the invalidate_mapping_pages symbol as EXPORT_SYMBOL_GPL, so we can't use it with them. For now, revert this change - we can live with the deprecated warning at present... Change-Id: I22875683e643c4184bb2c1e06f37d4c6eb9ea0be Reviewed-on: http://gerrit.openafs.org/1082 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 165571947be770645900bb8d55ba7b6a3c58f8fd Author: Derrick Brashear Date: Mon Jan 4 17:57:30 2010 -0500 linux kernel lacks uintptr sadly only recent kernels include uintptr_t. change the cast to use unsigned long Change-Id: Ib69f7aa0f2d316c5ea8bdc960b15ee0f89f96250 Reviewed-on: http://gerrit.openafs.org/1059 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 708dc955012334fc9ada5fad576cfecd33edb326 Author: Chas Williams - CONTRACTOR Date: Thu Jan 7 17:48:15 2010 -0500 UNIX CM: remove the last remaining reference to afs_rxglobal_lock Somehow this was missed earlier. Change-Id: Iebebdb90cb42cc9ef716409af435509916e4ab58 Reviewed-on: http://gerrit.openafs.org/1078 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f72207d8c48bfa087bd677e3966e82952c25fd83 Author: Chas Williams - CONTRACTOR Date: Thu Jan 7 17:35:20 2010 -0500 LINUX/: ifdef for GFP_NOFS conditionals Remove the conditionals in the linux 2.6 tree for GFP_NOFS. This feature has existed since the beginning of the 2.6 tree. This makes the code easier to read. Change-Id: Ib42af012c57912f72effb836743ab8f1ddc30486 Reviewed-on: http://gerrit.openafs.org/1077 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fcce9a4727d80762552c10075b03a48ecd40edac Author: Derrick Brashear Date: Sun Jan 3 19:01:47 2010 -0500 darwin module prototype and cleanup tidy up the osi_module and osi_misc prototyping, and the error checking and returns at module load time. side effect: also use the afs3_syscall prototype for the BSDs. Change-Id: I373f44f3b5999dc05ba23f09c74149aaf237edcc Reviewed-on: http://gerrit.openafs.org/1056 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8f689aec1499fa0c8d1b49cff1a51a9f0dcd8890 Author: Dan Hyde Date: Wed Jan 6 10:49:39 2010 -0500 volmonitor copy link before calling free Copy tt->next before TRELE(tt) calls free(tt). We have a core file from a VTRANS_OBJ_LOCK(tt) assert failure, with tt pointing into glibc's malloc data structures. Change-Id: Id52b774520c59c224b58f5d507cc490dafea5ca1 Reviewed-on: http://gerrit.openafs.org/1069 Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Thomas L. Kula Reviewed-by: Michael Meffie Reviewed-by: Dan Hyde Reviewed-by: Derrick Brashear commit c37b9230c5ce845483d573efbb19e41d5b5cc48f Author: Simon Wilkinson Date: Wed Jan 6 15:43:18 2010 +0000 Linux: Mark our super block as not updating access time We don't update access times, so mark our mount options as such. FIXES 126084 Change-Id: Ic1591b943288dae45267676046f78e02c306ec08 Reviewed-on: http://gerrit.openafs.org/1071 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e34702ef89649df47745121f45df32bec1f2fccb Author: Simon Wilkinson Date: Wed Jan 6 15:12:32 2010 +0000 Linux: Use the correct ATIME flag Since Linux kernel 2.4.0, MS_NOATIME has been a super block flag, and S_NOATIME has been the corresponding inode flag. Use the correct flag when we're opening cache files. FIXES 126084 Change-Id: I69cbcd651584cc86568c51793dd3f6d3e8644709 Reviewed-on: http://gerrit.openafs.org/1070 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b2433a3e4cf08e2c489100ea6c7a676712e25369 Author: Derrick Brashear Date: Tue Jan 5 00:14:26 2010 -0500 cachemanager additional cleanup integrate support for additional cachemanager cleanup. free volume, server, unixuser objects. cleanup messages printed at shutdown. zero/null/init additional locks and structures. FIXES 126069 Change-Id: Id00219b679a0b4ad15ca06fc16335b0e4282e0eb Reviewed-on: http://gerrit.openafs.org/1065 Tested-by: Derrick Brashear Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear commit c03980f710a9b169f68ce72a2f00b1a414c0ad2d Author: Derrick Brashear Date: Mon Jan 4 13:44:48 2010 -0500 macos code signature for afsd this is a dodge; we should sign with a real certificate and distribute signed binaries. until we more formally exist, this allows application firewall to at least cope better with us. Change-Id: I84d18f72f7b9a42f4eb41f86e2e6dc1ae54f662a Reviewed-on: http://gerrit.openafs.org/1057 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6e82a621e6ddfe6b38c42f8302168b2b58502522 Author: Andrew Deason Date: Fri Dec 18 12:17:41 2009 -0600 Refuse to attach inode partitions with UFS logging Partitions with the 'logging' UFS mount option are known to cause corruption when using the inode fileserver backend. So, if we detect that we are attempting to attach a 'logging' partition, refuse to attach it. Change-Id: I0ee23b9935ac6ffc66e6228fe03d6bbfb5d64574 Reviewed-on: http://gerrit.openafs.org/999 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 94ff83fee835f6d6c43d1907daee7c0e1567ff52 Author: Marc Dionne Date: Mon Jan 4 19:37:40 2010 -0500 Linux: don't oops on writeback if vcache has no stashed credentials When doing writeback, use current credentials if we can't find stashed credentials in the vcache entry. This is normally stashed in afs_open, so it's not clear how we get to that point, but that's not a reason to trigger an oops. Change-Id: I60937e3f9e360e68ea84205570c05cabb47ef08e Reviewed-on: http://gerrit.openafs.org/1063 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 747a8c0642aeaef814d953d16968fb5026e1ec69 Author: Michael Meffie Date: Tue Dec 29 13:40:15 2009 -0500 viced: allow alternate addresses on the same hash chain again Revert the logic meant to prevent duplicate entries in the host address hash table so hosts with multiple addresses can be stored in the same hash bucket again. Add a new log message to show when the host cannot be stored in the hash table because of an address-port pair collision with a host already in the hash table. Change-Id: I24bf48b912dcf3062201691b446372d78de9bc14 Reviewed-on: http://gerrit.openafs.org/1046 Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit daff4006627fc88be85dade3d72aa45e57a6804a Author: Simon Wilkinson Date: Tue Jan 5 00:14:06 2010 +0000 Fixes for supergroups on Darwin 64bit Some fixes needed to make supergroups build on 64bit Mac OS 10.5 Change-Id: I1aea100b138a8212010dd9f511377c993589977f Reviewed-on: http://gerrit.openafs.org/1060 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e4eb19cdc03c4f31ed1d4cefcd01163036ed8c6d Author: Jeffrey Altman Date: Wed Dec 30 11:32:58 2009 +0000 Unix CM: Use xdr_free to free memory allocated by XDR In src/afs/afs_volume.c VL_GetAddrsU() returns memory allocated by the xdr package. In 1.4 there was no method of freeing this safely. On the head there is using the xdr_free() function. FIXES 124937 Change-Id: I72b8333e02e0e58dd16d25e9ed258a2551cdef9d Reviewed-on: http://gerrit.openafs.org/1047 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 54c4ce48bf4883ee4f1cb8db8899d754baef9c34 Author: Matt Benjamin Date: Wed Dec 30 19:19:09 2009 -0500 freebsd: fix afs_root signature (RELENG_8) Track removal of thread id param, which had become redundant. Change-Id: Ifa8ddce411373a1aee01b577bf7e5a268e644dd7 Reviewed-on: http://gerrit.openafs.org/1055 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit a5d054668a8ec5f0cff2e446512a7d027fc65343 Author: Marc Dionne Date: Thu Dec 31 11:08:32 2009 -0500 Build fix: restore centry in ptutils.c The declaration of centry is needed when supergroups are not enabled. Restore it within the ifdef so that we don't get an unused variable warning if supergroups are enabled. Change-Id: I0e7916b7898cdd5c47accb7f185764bbb1f2e94d Reviewed-on: http://gerrit.openafs.org/1054 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4d6d7866689a2c005a055c580b8a54d7c9412386 Author: Russ Allbery Date: Wed Dec 30 16:22:37 2009 -0800 Remove warnings from supergroups code on x86 Prototype functions where necessary, remove unused variables, fix mismatches of data types (char * != void *), initialize variables the compiler can't tell are initialized, compare integers against 0 and not NULL, and wrap assignments used as conditions in an explicit comparison. This removes all warnings that fail --enable-checking on x86 with --enable-supergroups. 64-bit will still have warnings. Change-Id: I5ab6e317a280bea29cb44b97f2805a00e387577f Reviewed-on: http://gerrit.openafs.org/1050 Tested-by: Russ Allbery Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit 1526593621f78efaf2b37e4ac25a2944b6099920 Author: Russ Allbery Date: Wed Dec 30 20:30:27 2009 -0800 Correct spelling errors in man pages Correct several spelling errors in the man pages detected by Debian's Lintian package checking tool. Change-Id: I3834a12776ec5e27b04d80fbfcc43ffe71cf1790 Reviewed-on: http://gerrit.openafs.org/1051 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 64cacab28ba7b9692db0b494e2d4399c535bd1ae Author: Matt Benjamin Date: Tue Dec 22 19:48:02 2009 -0500 freebsd: track RELENG_8 Fixes to re-enable build and load of kernel module on FreeBSD's RELENG_8. Includes the following changes: Remove cred pointer argument to vop_getattr and vop_setattr. Restore VSUID and VGUID defines, but move to osi_machdep.h. Fixup calls to vinvalbuf, create a macro to avoid too many ifdefs. Revert incorrect definition of gop_lookupname_user. Avoid uninitialized use of 'code' variable in vop_access, and track new a_accmode member name. Remove cred pointer in VFS_STATFS. Avoid including sys/ioctl.h in kernel mode (formerly had no effect, it's now an error). Avoid using an empty file as an object file in shlibafsrpc link. Replace suser() calls with calls to priv_check, using defined OpenAFS privileges (thanks due to Ben Kaduk). Change-Id: I96fc29599a797b975630c8fa5b8b84798b3740a6 Reviewed-on: http://gerrit.openafs.org/1023 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e4708157ea55ef79d1c3a5387859618bdba90395 Author: Simon Wilkinson Date: Sun Dec 27 11:28:43 2009 +0000 Linux: Check for multiple silly renames We don't want to do multiple silly renames of the same dcache entry, so add a check for that occuring, and just return EBUSY if we're trying to do so. Change-Id: Ic1cb4061d89bf87926995162f1ac410375bddcb5 Reviewed-on: http://gerrit.openafs.org/1035 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ec352e0bfd6f324c6b95a3b1e816809c24004e84 Author: Simon Wilkinson Date: Sun Dec 27 11:06:01 2009 +0000 Abstract out Linux sillyrename function In order to keep the dcache happy, the Linux client has its own sillyrename function. Abstract this out from afs_linux_unlink into a function of its own (afs_linux_sillyrename) so we can make use of it from other vnodeops. Change-Id: I298251c400dfc22efb3bacaa72612b28a5409112 Reviewed-on: http://gerrit.openafs.org/1034 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 35d5b6c4e101c92e2c242bb75029db24eb1aa7d7 Author: Simon Wilkinson Date: Sat Dec 26 18:22:32 2009 +0000 Remove unused configuration tests Remove configure tests that are no longer used by the build. Testing for unused features just slows down the configuration process. Change-Id: I18e161e8e608a69801c53980e545c3077a7578d7 Reviewed-on: http://gerrit.openafs.org/1033 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 16a824222ba1ecdee4734659d76680bf4f61695a Author: Simon Wilkinson Date: Thu Dec 24 18:19:01 2009 +0000 Remove HAVE_STRUCT_BUF test Ever since b1edf891d717ee8e08c0d93738a204cff09cf68f was committed, we've not needed to test to see if the OS provides struct buf - we can just declare it as a structure without providing a definition in all circumstances. Change-Id: I81ebad0dcda91229883f44b657e8113ec832668d Reviewed-on: http://gerrit.openafs.org/1032 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f54588201488fe1038f52546853c7c2082ff069a Author: Simon Wilkinson Date: Thu Dec 24 15:35:47 2009 +0000 Remove --disable-full-vos-listvol-switch option Remove the --disable-full-vos-listvol-switch configuration option, and the corresponding #ifdefs. Full output from vos listvol is now always enabled. Change-Id: Ib4900cc0a8532b3db31d13d34fe59946b34e86ed Reviewed-on: http://gerrit.openafs.org/1031 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5364fada4e4eb48dcb72cd0802b8486bee3228c9 Author: Simon Wilkinson Date: Thu Dec 24 15:14:46 2009 +0000 Remove --disable-afsdb Remove the --disable-afsdb option from configure, and the corresponding AFS_AFSDB_ENV #ifdefs from the code. This means that the AFSDB code will always be built, but whether it used or not can still be controlled by runtime options in the cache manager. Change-Id: I1378c4626568e02345c7c400804747c446078c7e Reviewed-on: http://gerrit.openafs.org/1030 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0fce88e07934899eb2dfcff87ec289e0d4f683eb Author: Derrick Brashear Date: Tue Dec 29 11:29:09 2009 -0500 clean up axscache at shutdown modify allocations in axscache code to be able to be tracked. at shutdown, clean up allocations. Change-Id: I1fbde0fe49cf0cdeea451dac58718a90f1c87e66 Reviewed-on: http://gerrit.openafs.org/1037 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d11ca53be7d80096c21b777ec04e1874bed870d9 Author: Andrew Deason Date: Wed Dec 30 11:44:39 2009 -0500 Make DAFS 'bos salvage' work in restricted mode bosserver currently has code to specifically allow 'bos salvage'-initiated salvages to run when in restricted mode. This only specifically tests for running salvager, though, and so fails when 'bos salvage' is run against a DAFS fileserver and tries to run 'salvageserver -client' instead. Test for 'salvageserver -client' as well, so we can run 'bos salvage' for DAFS fileservers in restricted mode. Change-Id: I27052a440ea8d6347a9d86e4a1f1a7131a277b0b Reviewed-on: http://gerrit.openafs.org/1048 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 12f35e84934015251ec4e0171d302e7f10f894c2 Author: Simon Wilkinson Date: Thu Dec 24 14:34:42 2009 +0000 Remove --disable-largefile-fileserver Make largefile fileservers the only option. Remove all of the AFS_LARGEFILE_ENV ifdefs, and tidy up some code as a result of this change. Change-Id: I126f7dc5505bbdb28c9337dcd2e81403045707f4 Reviewed-on: http://gerrit.openafs.org/1029 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Tested-by: Andrew Deason commit f085951d39c0d6c1e6a626177c30235704317600 Author: Simon Wilkinson Date: Thu Dec 24 13:00:53 2009 +0000 Turn on bos restricted code Remove the #ifdef's around the bos restricted mode code. This makes restricted mode available as part of the standard build, but a server will not go into restricted mode unless the relevant command line options are specified, or bos setrestricted is run. Document bos_setrestricted and bos_getrestricted, and the new '-restricted' command line option. Add a note to the man pages of all of the commands whose behaviour is affected by restricted mode. Add 'setr' and 'getr' aliases for setrestart and getrestart so that these documented shortcuts continue to work (otherwise they'd be ambiguous against setrestricted and getrestricted). Note that setre, setres, and setrest will not work once this patch is applied. Change-Id: Ie69d21493ea5f78757f0a3d478de43fdaabd3c31 Reviewed-on: http://gerrit.openafs.org/1028 Reviewed-by: Michael Meffie Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bd4c636e9169cc098696916a40da1301c3100d88 Author: Russ Allbery Date: Wed Dec 30 20:33:14 2009 -0800 Update .gitignore for copied rxkad files src/rxkad/Makefile copies fcrypt.h and sboxes.h from the domestic subdirectory, so ignore the copies in the src/rxkad directory. Change-Id: I263c8f5ea45c3c6b32bc377f6451424477d255a2 Reviewed-on: http://gerrit.openafs.org/1052 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c45e2b374b7fd03863e82e013fee6bc8821717a1 Author: Simon Wilkinson Date: Tue Dec 29 22:48:39 2009 +0000 Linux: #if BLAH should be #if defined(BLAH) As the subject says, using #if BLAH gives warnings. Fix them in osi_ioctl.c Change-Id: Iee3da68cd29e84bd201a1ee657d3f80ca9b2f5d5 Reviewed-on: http://gerrit.openafs.org/1041 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit dab6cbadd666f83ebaf597b5fe228525ad65bed3 Author: Michael Meffie Date: Wed Dec 30 13:02:31 2009 -0500 missing brace in afs_get_sb Fix a syntax error when GET_SB_HAS_STRUCT_VFSMOUNT is not true so we can build on older versions of linux. Change-Id: I85aac803f68c3f3729abd32dfcecbc20ccac8ab9 Reviewed-on: http://gerrit.openafs.org/1049 Reviewed-by: Simon Wilkinson Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 187630ed3e2fa65c8c49143da0b99b91450a6c5e Author: Simon Wilkinson Date: Tue Dec 29 17:06:42 2009 +0000 Unix: Rename aklog_main.c as aklog.c Now the reasons for having aklog_main.c separate from aklog.c have gone, rename the file so we've just got aklog.c Change-Id: I32e34be246a5357be25ab93328d434c396483042 Reviewed-on: http://gerrit.openafs.org/1038 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit da8c26533d101f5e90d7c2d829441c0f2c48a63b Author: Simon Wilkinson Date: Tue Dec 29 17:03:50 2009 +0000 Unix: Merge aklog with aklog_main Historically, aklog was split into aklog.c (which just contained a wrapper) and aklog_main.c, which did all of the hard work. Now that we've purged all of the Windows code from aklog_main.c, we can merge them both into the same file, so do so. FIXES 20884 Change-Id: Ifdcb33f4eb2b26703c833056882d95f7f0f654b1 Reviewed-on: http://gerrit.openafs.org/1036 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6ec18461649d3e4f44b2476f886bcc480c456500 Author: Derrick Brashear Date: Thu Dec 17 15:33:42 2009 -0500 avoid leaking stat info if a file is already CStatd we just copy out the information without doing access checks. add an access check. Change-Id: I94d1dc118189b19759d8e9635988c40f38026cbb Reviewed-on: http://gerrit.openafs.org/995 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 6c9d49d096017f15306d0c9256f6dc2d933f001e Author: Andrew Deason Date: Tue Dec 29 15:45:51 2009 -0500 Return a cell name from afsconf_LookupServer Previously, afsconf_LookupServer could not meaningfully return a cell name, since a char* was passed in for realCellName, and afsconf_GetAfsdbInfo was expecting the value of the pointer to change. Change afsconf_LookupServer to take a char**, and pass realCellName by reference, so we can get a cell name back. Change-Id: Ib945fcb4be482ee155cdd1dcd62fe577c002082d Reviewed-on: http://gerrit.openafs.org/1039 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 87de027fa430f67bd92153feedfc3fbab54c4c64 Author: Simon Wilkinson Date: Tue Dec 29 21:56:36 2009 +0000 Fix ioctl32 inclusion on Sparc 64 ioctl32.h only became available in Linux 2.5.44, so reduce the scope of the include. It went away again, in Linux 2.6.22. In its short life, it only ever provided prototypes for registering translation handlers, and for sys_ioctl. Only include it where we call those handlers, and when we call them, to remove compilation errors for Sparc64. Change-Id: I7816bd8b1e18ead68f7e5078e684d60bf59ac470 Reviewed-on: http://gerrit.openafs.org/1040 Reviewed-by: Russ Allbery Tested-by: Russ Allbery Reviewed-by: Derrick Brashear commit 99d007067329e451b99058e94f7a76e37b3dbdcd Author: Simon Wilkinson Date: Wed Dec 30 01:39:26 2009 +0000 Documentation: Fix asetkey syntax To set a key, use "asetkey add", not just "asetkey" FIXES 125430 Change-Id: Ifa381ec95f9253bcc5c7a1d374fbf88408f82f67 Reviewed-on: http://gerrit.openafs.org/1045 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 40719534d5d906f97a6ae7d28a00289270daf2a6 Author: Simon Wilkinson Date: Tue Dec 29 22:58:56 2009 +0000 Linux: Replace invalidate_inode_pages invalidate_inode_pages is now marked as deprecated in the kernel headers. Use the equivalent call to invalidate_mapping_pages() which has been available since Linux 2.5 Change-Id: I58de20e16874bb06991320b26bc6ce63685b8bb4 Reviewed-on: http://gerrit.openafs.org/1042 Reviewed-by: Russ Allbery Tested-by: Russ Allbery Reviewed-by: Derrick Brashear commit acd1bcf7267ea800ee4e3a19761105482a24f7b6 Author: Simon Wilkinson Date: Wed Dec 30 01:04:23 2009 +0000 Documentation: vos dump -verbose outputs to stderr vos dump -verbose sends its logging to stderr, not to stdout (where it would potentially collide with the dump data itself). FIXES 124911 Change-Id: I515c50df59d2f376787969df59b6e01e244ecbc7 Reviewed-on: http://gerrit.openafs.org/1044 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 10c00e1f17ceb0c74c074593d09633b6c0e51278 Author: Simon Wilkinson Date: Tue Dec 29 23:20:36 2009 +0000 rxgen: Remove stray debugging statement A stray "Printing ex_req" slipped into the last set of rxgen changes. Remove the unnecessary debugging statement. Change-Id: I2dda4138d70bf3429122f58bbbae996b84baefac Reviewed-on: http://gerrit.openafs.org/1043 Reviewed-by: Russ Allbery Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 9f1c90a6e0004bda153e9e077dc68381b2beec13 Author: Andrew Deason Date: Thu Dec 24 13:32:14 2009 -0500 Move TOP_INCDIR/des dependency to prelude Make TOP_INCDIR/des a dependency of the 'prelude' target, not all of the 'dest'-ish targets. Without this, things like 'make tviced' fail since we never create the TOP_INCDIR/des directory, but 'des' needs to copy headers into there. Also, remove the other redundant INCDIR/LIBDIR deps in the 'dest'-y targets, and put them in 'prelude'. Change-Id: I1beb1a0c8b93a7bf17af71792ab38590d03c9976 Reviewed-on: http://gerrit.openafs.org/1027 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1f23ff72e9d0b555c44dca90a92c6379e5d52f3a Author: Andrew Deason Date: Thu Dec 17 15:16:50 2009 -0600 Check viced FetchData length for cache bypass Same fix as change I413393a7bacbf207332d7f904cf396c79b77b6b5, but for the cache bypass code. Change-Id: Ic181e257f7d0e1892bd10bf14d8d5571b4804d63 Reviewed-on: http://gerrit.openafs.org/1000 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 9651fd726f8cc5d7b2ebdadf48b7e22bf25d1715 Author: Andrew Deason Date: Wed Dec 23 15:23:30 2009 -0500 Fix warnings in fs.c with --enable-cache-bypass Fix some warnings in src/venus/fs.c so we can compile with --enable-cache-bypass and --enable-checking: -- Include ctype.h so isdigit gets a prototype -- Make BypassThresholdCmd have the proper signature -- Remove the unused 'size' variable Change-Id: I09afc6c04c990476226d1c2a751e23d3d39085b6 Reviewed-on: http://gerrit.openafs.org/1025 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2c0a9ab3c361ade9218c2f458d86165de8eadc76 Author: Simon Wilkinson Date: Tue Dec 22 21:46:43 2009 +0000 Solaris: Don't access lbolt directly Recent changes in OpenSolaris have removed the 'lbolt' variable. However, the ddi_get_lbolt accessor (which has been present since Solaris 10) can be used to get access to the same value. So, use it. Change-Id: I7a72bab14b0226fb25adb642f3621512e02ca216 Reviewed-on: http://gerrit.openafs.org/1022 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dd9ab4b84c0bad163ccef8c3d24554e19f005cb1 Author: Simon Wilkinson Date: Tue Dec 22 21:42:19 2009 +0000 Solaris: Don't directly fiddle with the groups structure Solaris doesn't let us directly play with the groups structure anymore. Instead, there is a crsetgroups accessor which can be used instead. So, use it. Change-Id: I4d5b99110318630c8a7744812476e1941c117381 Reviewed-on: http://gerrit.openafs.org/1021 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0f0f6cd613fe1084af948f1765a5e7e0772b117d Author: Simon Wilkinson Date: Tue Dec 22 21:38:00 2009 +0000 Solaris: Be more flexible about compilers OpenSolaris doesn't have its C compiler in /opt/SUNWspro/bin/cc, but we still have to be careful to avoid gcc, as that can't build the kernel module. As a short term stop gap, add a PATH_PROG test which looks in both /opt/SUNWspro/bin and /opt/SunStudioExpress/bin for cc. We probably should look in more places, and in the long run, we should probably be taking whatever autoconf gives us (for userspace, at least) Change-Id: Ie31cf1bf474650a081fc101a2aa40cfa6bd39423 Reviewed-on: http://gerrit.openafs.org/1020 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b631f5d64c629f5cda8ca02d859a089dca0a71fe Author: Simon Wilkinson Date: Tue Dec 22 21:34:23 2009 +0000 Look for aclocal in more places Some operating systems (cough, OpenSolaris, cough) have multiple versions of aclocal installed, and don't populate the 'aclocal' name. If 'aclocal' isn't present, then try using 'aclocal-1.10' before we give up in disgust. Change-Id: Iad6daf1038942aeee13f38cb0c00c58da621cfd1 Reviewed-on: http://gerrit.openafs.org/1019 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2ec18e9f7adb8a5916e54cd9f45e5e6db6408de9 Author: Andrew Deason Date: Tue Dec 22 09:49:21 2009 -0500 Fix typo in afs_linux_cred_is_current 987816dfa852750caca8c64c44174a5333ae0e3b introduced a stray 'cred' in one of the afs_linux_cred_is_current definitions. Remove it so we can build without STRUCT_TASK_HAS_CRED. Change-Id: I7ef94c1c3d15a2a744755d8a20ec2b0c92cd5349 Reviewed-on: http://gerrit.openafs.org/1018 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 846f772601114dc57ddba934fbdca2b2f2a4aa31 Author: Michael Meffie Date: Thu Dec 10 16:13:45 2009 -0500 Prefix global defines Prefix constants relocated to the common afs_consts.h header to void naming collisions. Change-Id: Ib657e00385002c957b40b36058f260c6cabd108c Reviewed-on: http://gerrit.openafs.org/905 Reviewed-by: Mickey Lane Tested-by: Mickey Lane Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2b8e09315c6f08f3972754b3ea0b6847b1f12d25 Author: Michael Meffie Date: Thu Dec 10 11:37:34 2009 -0500 Consolidate duplicate definitions Housekeeping change to consolidate some common definitions. Create a new common header called afs_consts.h. This allows us to remove the afscp.c dependency on afs.h (so src/tests will build again.) Rename the max filename definition in the update server package to MAXFNSIZE to avoid a name conflict with MAXSIZE. The global defines will be prefixed with AFS_ in a second patch. Change-Id: I2b8d555a244cc92d889618de4eec4a99550d7c7f Reviewed-on: http://gerrit.openafs.org/855 Reviewed-by: Mickey Lane Tested-by: Mickey Lane Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9bbd7a211761db6bd9c9412037a35d3024af26cc Author: Marc Dionne Date: Sun Dec 20 08:30:07 2009 -0500 Linux: fix sysctl for 2.6.33 The sysctl patch for 2.6.33 was a bit overzealous and ifdef'ed a few lines that it shouldn't have. Change-Id: I7033259e567a06ce05b968366e810c5b2688c271 Reviewed-on: http://gerrit.openafs.org/1011 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 36f97969f39637042a54c0d45877a48cc9dfcac1 Author: Marc Dionne Date: Sat Dec 19 22:22:05 2009 -0500 Linux: utsrelease.h is moving In kernel 2.6.33, utsrelease.h has moved to include/generated. Adapt the configure code to consider that location, and clean up that section's indentation. Change-Id: I5061043ff7f46875a39953b11c472693650c7485 Reviewed-on: http://gerrit.openafs.org/1009 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 846c28282fb4ccd2136e3e27b60b9363ea7f759e Author: Simon Wilkinson Date: Sat Dec 19 21:53:54 2009 +0000 Fix PAGs for all platforms without Linux keyrings The changes in 7b272177de4c6f78db7f2315f4e30e85ab7660bb sadly break all platforms which aren't Linux. This is because the logic in PagInCred doesn't handle the non-Linux case at all. Fix this so that we call afs_get_group_pag whenever we're not running on Linux. The code also doesn't match the comment - Linux kernels which don't have keyrings should use afs_get_group_pag(), regardless of whether STRUCT_TASK_HAS_CRED. It's unlikely this bit would ever bite anyone though, kernels with cred support almost certainly require keyrings. Change-Id: I5373da51151229dc13b6dc60c3cf10700f0f881a Reviewed-on: http://gerrit.openafs.org/1006 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 987816dfa852750caca8c64c44174a5333ae0e3b Author: Simon Wilkinson Date: Sat Dec 19 20:21:36 2009 +0000 Linux: Simplify keyring compatibility code This introduces a few inline functions in osi_compat.h, to reduce the number of #ifdefs in the main chunk of code. In particular, we gain * afs_linux_key_alloc : to handle all the different key_alloc signatures * afs_linux_search_keyring : to handle our two different mechanisms for searching a keyring * afs_linux_cred_is_current : will return true if we're using native credentials, and the passed creds are also those of the current task Change-Id: I138f3533a7e8e88e04e4b5508158e003882d63ee Reviewed-on: http://gerrit.openafs.org/1005 Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cda45cc7a11495c1acc5a5ebbac1474f3eb5a6bd Author: Simon Wilkinson Date: Sat Dec 19 15:40:49 2009 +0000 Linux: Don't panic when keys aren't found This fixes two potential problems in our session keyring lookup code, which can lead to panics in situations where we're using the new struct cred based code. The first is that if there is no session kerying installed for the current task, we'll attempt to do a lookup on a NULL kerying and oops. The second is that if the keyring_search returns EPERM, then we can end up unmasking that error code, and return NULL, rather than an error. Change-Id: If0e2804408ec17b00f352980cee6a8e56704d93f Reviewed-on: http://gerrit.openafs.org/1004 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 994ef0e7cab95e2fc6f47fc8838490112e432ffd Author: Simon Wilkinson Date: Sat Dec 19 14:48:32 2009 +0000 Linux: Flush vcaches when a mount fails GetVCache (well, really NewVCache) creates a new vcache, with an attached inode, and links it into the VLRU queue, regardless of whether it is successful in populating that vcache or not. The attached inode, on Linux, contains a reference to the super block of the filesystem. If the created vcache is for the root, however, and populating that vcache failes, then mount fails, and the super block is disposed of. This leaves us with a vcache in the VLRU queue which contains a reference to a non-existent inode. When ShakeLooseVCaches comes along a few minutes later, it attempts to discard this inode. However, doing so fails because the inode no longer has a valid super block. Avoid this trauma by ensuring all vcaches are disposed of before the super block goes away, in the event of a mount failure. Change-Id: I68864f1ea401d24adba76164905a17de6ab3e6ce Reviewed-on: http://gerrit.openafs.org/1003 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit c7b92a3018044f7aca4d9a77644e5c06ef64d1e9 Author: Andrew Deason Date: Thu Dec 17 14:59:44 2009 -0600 Do not trust FetchData length from fileservers Currently the Unix CM implicitly trusts that the length from a FetchData request from a fileserver will always be less than the requested length. If the fileserver sends more data than requested, we can use up more cache space than we intended, possibly exceeding the cacheinfo cache limits. Add a check for this, and return EIO to the caller if the fileserver responds with too much data. Change-Id: I413393a7bacbf207332d7f904cf396c79b77b6b5 Reviewed-on: http://gerrit.openafs.org/996 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 244397335e41bb83e4dba12bc30a7b4ec6fc6218 Author: Andrew Deason Date: Fri Dec 18 12:21:35 2009 -0600 platform target depends on cmd and vol The 'platform' target depends on cmd and vol, since on solaris non-namei, we build fs_conv_sol26.c, which depends on some volume structures, and uses libcmd. So, have Makefile.in accurately reflect that dependency so we can build. Change-Id: Ic7038f252dd069522ebfc8e72b9743c01c97d99c Reviewed-on: http://gerrit.openafs.org/998 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9faaa2fed8c8dd0ae1c9288b1e1130bec78dc9f8 Author: Derrick Brashear Date: Thu Dec 17 09:48:06 2009 -0500 kernel ioctl32 conversion typecasting cast types to avoid a pointer from integer warning when using pointer types for sizing Change-Id: Idac76608e5352c65a13d07bfadb66d78f9db0ffd Reviewed-on: http://gerrit.openafs.org/988 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3df80a163874c841f32c4c523fba641142e6d698 Author: Andrew Deason Date: Fri Oct 16 17:12:35 2009 -0500 Add the 'vos endtrans' command Add a command to vos to explicitly end volume transactions. These can happen if (for example) we segfault or the user ctrl-C's in 'vos' before/after a volume operation, but before we AFSVolEndTrans. Change-Id: Ie34ee1fdff917b56900f456c7cf8b1329533a7da Reviewed-on: http://gerrit.openafs.org/870 Reviewed-by: Dan Hyde Reviewed-by: Alistair Ferguson Tested-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2a69aa22c1278d62008863aabe6833954b4466c0 Author: Claudio Bisegni Date: Fri Dec 11 22:03:39 2009 +0100 OpenAFS Preference Pane Now the preference pane is fat compiled. Change-Id: I5c54555d00b16d85f01286719bbc41ea5f1fb67d Reviewed-on: http://gerrit.openafs.org/906 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 6f439ff7edc0e333d477bf7c65b291dae5d993c2 Author: Andrew Deason Date: Fri Nov 6 14:03:52 2009 -0600 Expand ProgramType enumeration The ProgramType values volumeUtility and salvager are overloaded. Expand the ProgramType enum to include more specific program types, and adjust conditionals to match. Also, instead of determining all behavior by checking programType, add some flags to be passed in to VInitVolumePackage to determine e.g. whether or not we can use the FSSYNC channel. This makes it easier to see the intent of some conditionals, and reduces the number of times a caller must lie about what program it is. Change-Id: Ic9852a35bb16a6b1f4b0aa9766de63178ecea56f Reviewed-on: http://gerrit.openafs.org/786 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 34ffc9cd7d7eed62229704ad0e1d327f076ea7b6 Author: Simon Wilkinson Date: Fri Nov 20 15:08:25 2009 +0000 Linux: Use splice to speed up cache storeback This patch adds a new cache store function for Linux, which uses splice() and direct access to the page cache, rather than doing data copies to a temporary buffer between rx and afs. It removes one copy, and some context switching, from the write codepath. One side-effect here is that it will delay storebehinds from returning control to the user. Instead of returning once the first 4k has been successfully transfered, we will wait until a cache chunk has been transmitted. This is currently unavoidable, as we can't take the GLOCK within a splice actor. Change-Id: I5b0284d67febccf099710589908fad18b808332c Reviewed-on: http://gerrit.openafs.org/903 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 292ec075d2beea2d718caa3f50929e125b1b97c1 Author: Simon Wilkinson Date: Fri Nov 20 15:03:37 2009 +0000 Rework cache store back This patch reworks the code to store data from the cache to the server, such that the entire store loop can be replaced. The idea here is that a platform which wishes to provide a different store loop, in particular one which doesn't rely upon multiple data copies, may do so simply by plugging in a new function. Change-Id: I6573c6a5c3e93a1259266e7e1a2b7bd17357203f Reviewed-on: http://gerrit.openafs.org/902 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 886801b069fab1e6fc94003221dcfe18e05ac376 Author: Marc Dionne Date: Wed Dec 9 19:06:18 2009 -0500 Linux: deal with ctl_name removal The binary sysctl interface will be removed in kernel 2.6.33 and ctl_name will be dropped from the ctl_table structure. Make the code that uses ctl_name conditional on a configure test. Change-Id: Iba0f107f299c6515e4e560d7596e6187bd68e399 Reviewed-on: http://gerrit.openafs.org/904 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 33a87fce6b46515c7e9e057858141cfb0c601d81 Author: Simon Wilkinson Date: Tue Dec 8 15:21:54 2009 +0000 pt_util runs on database servers Fix the pt_util manpage to reflect the fact that it is run on database servers, not fileservers. Change-Id: If2a8e5b65ef925c50eb9bfebea4e0d30c20f0970 Reviewed-on: http://gerrit.openafs.org/901 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 62a21819a1b57d006c73f84362494794651d1a37 Author: Jeffrey Altman Date: Sat Dec 5 10:51:27 2009 -0500 Windows: cm_BPlusEnumAlloc should not fail for zero entries If cm_BPlusEnumAlloc returns NULL, the caller assumes a memory allocation error. If the enumeration consists of zero entries, allocate a structure that stores zero entries. LICENSE MIT Change-Id: I8ed3811a1b3a0e4262749e110027c5d5812338b6 Reviewed-on: http://gerrit.openafs.org/892 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 2bffe725c5ebb785257555286567f128e0911cb7 Author: Jeffrey Altman Date: Sat Dec 5 10:53:03 2009 -0500 Windows: cm_BPlusDirBuildTree can fail It is possible that cm_BPlusDirBuildTree can fail. For example, the server could be marked down after a callback is obtained but before all of the directory data buffers have been fetched. cm_BeginDirOp must check for the failure, destroy the tree, and return the failure code to the caller. Otherwise, a tree with no entries may be created and marked with the current data version. LICENSE MIT Change-Id: I26fbfceaf68389a1906797b12721c49172b027ec Reviewed-on: http://gerrit.openafs.org/893 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 019ae5240691f27beaf583084fc81f4efb84b166 Author: Derrick Brashear Date: Sun Dec 6 23:44:53 2009 -0500 macos avoid dotunderbar lookups in fakestat mode cocoa tries to lookup ._ files for every object, possibly generating AFSDB queries and other fun. avoid them Change-Id: Id70b6335d4dddcb6d5628a9883b2c81193bb39d7 Reviewed-on: http://gerrit.openafs.org/896 Reviewed-by: Rod Widdowson Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 61ba8e5a88f0fa09a212b89b375167f0b4e1c70d Author: Derrick Brashear Date: Mon Dec 7 15:43:33 2009 -0500 add newline to lockprocs_prototypes.h gcc was unhappy about the lack of trailing newline. add one. Change-Id: Ie9c93bd9ed8c923ea8069fe49e7f5ddb20c28f80 Reviewed-on: http://gerrit.openafs.org/898 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3cb49f57a34b42c9efdc24797efda053cd88be80 Author: Andrew Deason Date: Tue Nov 24 16:09:42 2009 -0500 Dump all hostFlags in hosts.dump Currently only certain flags are dumped in hosts.dump. Also dump the value of hostFlags itself, so we get more information from a host dump. Change-Id: I2d265b85e057c2d44938e1d92f4c102048c4bf1f Reviewed-on: http://gerrit.openafs.org/869 Tested-by: Andrew Deason Reviewed-by: Dan Hyde Reviewed-by: Alistair Ferguson Tested-by: Alistair Ferguson Reviewed-by: Derrick Brashear commit 5529bf9b6b6b69bbe244f1185e4842e3eca732f5 Author: Andrew Deason Date: Sun Dec 6 14:56:20 2009 -0600 Make HandleClientContext take an afs_ucred_t 5d5d18071608d9782a5d936f79215048af641410 missed one occurrence of AFS_UCRED. Make HandleClientContext take an afs_ucred_t instead of AFS_UCRED, so afs_pioctl.c builds again. Change-Id: I04c831ad262cade5da0f90fb8860174657dae4bf Reviewed-on: http://gerrit.openafs.org/895 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 03b5994d7bec0088d0edbfc83f5820c089ac9599 Author: Simon Wilkinson Date: Sun Dec 6 14:25:08 2009 +0000 Remove AFS_USEBUFFERS The AFS_USEBUFFERS code has been disabled for all supported platforms since the initial OpenAFS code drop. Simplify the buffers code by removing it entirely. Change-Id: Iab6b2d54361eca1a1446b4804b3d6533d75f2831 Reviewed-on: http://gerrit.openafs.org/894 Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit ae1926fa95dea39dce2166583d2948c22d59f2c1 Author: Derrick Brashear Date: Fri Dec 4 19:53:21 2009 -0500 Windows: Version update for 1.5.68 1.5.6800 = 1.5.68 Change-Id: Id3bdc21e5f72ebe2047cb70c2496df2ba7300b4b Reviewed-on: http://gerrit.openafs.org/891 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit adf9baebc81dd0a1a88007a1982b889d9eefe72e Author: Derrick Brashear Date: Fri Dec 4 11:52:29 2009 -0500 unix 1.5.68 update version numbers for unix Change-Id: Ic8a42a9ca1cfc74ab2d8f8d2ac0442efa716a84b Reviewed-on: http://gerrit.openafs.org/888 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 1ad30c2ea8cd2139a14ebe698117f1dc08fb4cf4 Author: Derrick Brashear Date: Fri Dec 4 15:31:10 2009 -0500 rx packet dumper not in kernel don't compile the rx packet dumper when in kernel Change-Id: I8484f3ed80d3b97d733091901f6e252a455cefa1 Reviewed-on: http://gerrit.openafs.org/889 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b6b18f12315f648614823bafa016c422a3e0c6f7 Author: Jeffrey Altman Date: Fri Dec 4 10:52:21 2009 -0500 Fix midnight volume calculation to build on Windows Change I516d732d broke the Windows build. localtime_r does not exist on Windows. Change-Id: Ib28e414a85d763dbe146bc2fadec91310f6144ab Reviewed-on: http://gerrit.openafs.org/887 Tested-by: Jeffrey Altman Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit f48c0a20a1a5507f499260175e5308931ecd03be Author: Jeffrey Altman Date: Fri Dec 4 00:43:54 2009 -0500 Windows: Version update for 1.5.67 1.5.6700.0 == 1.5.67 Change-Id: I0f4402cdb8f387b67c93ee9066dc3be352d163c1 Reviewed-on: http://gerrit.openafs.org/886 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit ccb64bd3aacf6f1253dfe4dc3d04bb6b87e100b7 Author: Derrick Brashear Date: Thu Dec 3 23:26:18 2009 -0500 unix 1.5.67 make 1.5.67 for unix Change-Id: I1e25ec581b9b2a37230bd2a889f88f454a73ba8f Reviewed-on: http://gerrit.openafs.org/885 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit a031c900ca6eb40a914327bfc9e9cca370016d56 Author: Derrick Brashear Date: Thu Dec 3 15:37:52 2009 -0500 add rx packet trace debug dumping for unix revised version of a patch i've had for months to actually be clean. allow state of all packets to be dumped so you can see what's on what queues where. Change-Id: Ibaa692c835e9ced5e7cd3299922f5bac09344d28 Reviewed-on: http://gerrit.openafs.org/883 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit b98ca30c160c85834b1ad63a9d806efdd2940e61 Author: Rainer Toebbicke Date: Thu Nov 19 14:07:07 2009 +0100 Calculate midnight (for volume stats) based on standard functions The "tz" structure used with gettimeofday is not blessed by common standards and not widely supported, on Solaris for example it does not return anything useful. Calculate midnight based on standard functions (localtime/mktime). Change-Id: I516d732d4a9dd4696a524a271d806d349c074c25 Reviewed-on: http://gerrit.openafs.org/849 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 96eaa67edbe25c475836aa31921864936c271941 Author: Jeffrey Altman Date: Thu Dec 3 15:47:38 2009 -0500 Windows: change notes for 1.5.67 release Change-Id: I0eedd81fbfee98c591cfd57364bc23392ccca2da Reviewed-on: http://gerrit.openafs.org/884 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit e26926210057a6666c66825a78dbb04bf3238846 Author: Derrick Brashear Date: Tue Dec 1 16:17:49 2009 -0500 add unlock support to afscp make the afscp test client able to drop a lock on a file. additionally, make it build again. Change-Id: Ib4a5acf787f8f2e84699e1638a662068b993d965 Reviewed-on: http://gerrit.openafs.org/881 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b40b60650cf91f005990bc2e55185a4af7e2cd4b Author: Jeffrey Altman Date: Mon Aug 17 12:30:44 2009 -0400 Use xdr_alloc and xdr_free within ptuser If the memory allocation routines for libafsauthent and libafsrpc differ, callers of the ptuser routines in libafsauthent will crash. Use xdr_alloc and xdr_free in ptuser to ensure that the memory allocation routines are always consistent. LICENSE MIT Change-Id: I20fa1e1fc0677917e47e2ed9f0eaec83f23b699b Change-Id: Id31bf20b482e9502a5af79f4d86319fe530aa5a5 Reviewed-on: http://gerrit.openafs.org/319 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 14dbe49786f2547b66a6ad38bdae0db9d1648c49 Author: Michael Meffie Date: Mon Nov 30 19:28:13 2009 -0500 shutdown_icl return type void Change the shutdown_icl return type to void to match the 1.4.x branch. Change-Id: I641abbd0f87d648c3c9de3cab4d0dd926a51eb89 Reviewed-on: http://gerrit.openafs.org/879 Tested-by: Marc Dionne Reviewed-by: Marc Dionne Reviewed-by: Russ Allbery commit d393aabca577917b107afdd42efb40cc2fdac50c Author: Andrew Deason Date: Mon Oct 26 14:09:41 2009 -0500 Correct duplicate special inodes while salvaging Right now when the salvager encounters duplicate special inodes for a volume, it refuses to salvage the volume, presumably because it does not know which inodes to use when recreating the volume header. However, this can cause the confusing state where the fileserver and various volume utilities have no problem with a volume, but the salvager refuses to salvage it and marks the volume as needing salvage. When salvaging, if we already have a volume header, and we encounter duplicate special inodes, it is likely that the special inode referenced by the volume header is the correct one. So, instead of erroring out, keep track of which inodes are referenced in the volume header, and if there are any duplicates, either ignore or delete the unreferenced ones, depending on the -orphans setting. Also be a little more verbose when logging errors in this area. Change-Id: I15e34e8f2bccdc666bb59e3730fdf8bf51624259 Reviewed-on: http://gerrit.openafs.org/736 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Reviewed-by: Steve Simmons Reviewed-by: Derrick Brashear commit 19f0da1e44c6ac5acd22f8a2b1d9095d568d216e Author: Marc Dionne Date: Thu Nov 19 18:29:08 2009 -0500 Warning fixes - key handling Various warning fixes related mostly to the different types used to handle keys. This should clear most of the remaining warnings in this area. The technique of inline converter helpers is extended to cover a few more cases. README.WARNINGS is adjusted to reflect the current status. Fixes: - bos: define and use an inline converter from a ktc key to a bozo key - bos.c and bos_utils.c should no longer have warnings - adjust Makefile - define a ktc key to char * converter and use it in a few places - define kas key to bozo key ptr converter and use it in a few places (afs_bosAdmin) - cast a few arguments to ka_StringToKey which expects non-const pointers Change-Id: I1c19869ac232d78209126d4eeeb11af8bcb95815 Reviewed-on: http://gerrit.openafs.org/860 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 0188cf081f3c21cc1cb467a9babeb22a52b093f7 Author: Andrew Deason Date: Sat Nov 28 22:25:27 2009 -0500 Add server prefix to utst_int.xg When compiling src/ubik/utst_int.ss.c, a warning would be produced since the server stubs are defined as accepting an rx_connection instead of an rx_call, and since the server and client RPC stubs have the same name. Give a server prefix so we can distinguish between the two, and fix the server stubs and squash the warning, similar to bd011aeee7f5dad5c61fd81a90b296c46a0b9058. Change-Id: Iebf843bcabb4cf8f4a56c6ac30d210573b58d801 Reviewed-on: http://gerrit.openafs.org/876 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 58258ba3b89732ea825e1aff2decab54347ab92e Author: Andrew Deason Date: Fri Nov 20 14:15:28 2009 -0600 Add safety checks on all hostList traversals Currently, h_Enumerate checks that it doesn't enumerate over more than hostCount hosts, in case the hostList has a cycle or is otherwise corrupt. Add similar checks to all places in the code that loop over hostList, to prevent the code from getting in an infinite loop under H_LOCK in the case of a hostList cycle. Also, ShutDownAndCore instead of assert'ing, so we try and detach volumes first, possibly reducing salvaging time when we restart after core'ing. Change-Id: Ide1e5aca7c2c4a4af3f62bc07821db694f2f9999 Reviewed-on: http://gerrit.openafs.org/863 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9bff2027cb963343778001512d5cdf00cc7094c6 Author: Andrew Deason Date: Wed Nov 25 16:23:06 2009 -0500 Add a watchdog timer for ShutDownAndCore(PANIC) Add a watchdog timer that is started when ShutDownAndCore(PANIC) is called, to ensure we actually panic and do not e.g. get stuck in deadlock. Change-Id: I9201fe7d09aeb6819beefaf1755b51129c7bda6b Reviewed-on: http://gerrit.openafs.org/873 Tested-by: Andrew Deason Reviewed-by: Alistair Ferguson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c4780421a41a05683bcec8d1092534c2ad58f341 Author: Andrew Deason Date: Wed Nov 25 10:25:14 2009 -0500 Correct include paths in fs_conv_sol26.c Make the #include paths in fs_conv_sol26.c correspond to the 36524b2ed73a2774ee1f6242208a1395be7736a8 changes, so fs_conv_sol26.c will build again. Change-Id: Ic454dae07c0fb324f8550d1281b63fe539f8d525 Reviewed-on: http://gerrit.openafs.org/871 Tested-by: Andrew Deason Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit af9d80512852c083dd25655c2f717cfd75a9dce5 Author: Andrew Deason Date: Wed Nov 25 16:47:27 2009 -0500 'Flexible client buffer growth' fallout e7c966354c428a5a5929a3db6a829ee71c8ba2fc re-introduced a usage of the 'M' lock macro variants previously removed by bab6fd227f5724c4e4ca5d0ba1dc64e21ed21f97. Use the non-'M' macros instead so we can build. Change-Id: Ie27fb8e82a7440a6952517d9a0cc1aeb8523511c Reviewed-on: http://gerrit.openafs.org/872 Tested-by: Andrew Deason Tested-by: Marc Dionne Reviewed-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3138aaba25fc93ec0ef38cd1cf61100b86990e80 Author: Jeffrey Altman Date: Tue Nov 24 18:08:55 2009 -0500 Windows: Fix test for setting FILE_ATTR_READONLY When checking whether or not to enforce the unix mode bits as if they were the Windows FILE_ATTR_READONLY flag the mask 0200 is used. Make sure that the same mask is used when publishing the FILE_ATTR_READONLY flag to the smb client. LICENSE MIT Change-Id: Ia68bd17ad80341f1c14f3c0caaec8f09a0a2f3c5 Reviewed-on: http://gerrit.openafs.org/868 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit e7c966354c428a5a5929a3db6a829ee71c8ba2fc Author: Rainer Toebbicke Date: Thu Oct 29 14:52:45 2009 +0100 Flexible client buffer growth Allocates the 2k-directory-buffers for the client as needed, in small increments, rather than a fixed-length area upon startup. Change-Id: I6061b71d40284a0059e54377e3b374fee9b86816 Reviewed-on: http://gerrit.openafs.org/799 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f716962ab41847af4450d0a361f5de9195b32ed0 Author: Jeffrey Altman Date: Thu Nov 19 18:53:56 2009 -0500 Windows: disable readonly volume versioning due to file server bug Change I17e3980184ec68e38c5186e1c9637ac6e38451fe corrects a file server bug that results in invalid volume sync data being sent to clients during bulk status rpcs. Unless this is fixed in the file servers it is not safe to use the volume versioning functionality. This patchset disables the functionality by default and permits it to be turned on via a registry value. If the client is deployed in an environment in which all of the file servers have been fixed, then it will be safe to turn this feature on. LICENSE MIT Change-Id: I0db38ffc9cdeb90db20b92adca9a42a06fed2e2f Reviewed-on: http://gerrit.openafs.org/859 Reviewed-by: Derrick Brashear Reviewed-by: Rod Widdowson Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 072d69ac27587b6d384aae52de27b6e9b83fdea3 Author: Jeffrey Altman Date: Thu Nov 19 11:35:12 2009 -0500 Windows: provide enhanced error output to aklog Add Simon Wilkinson's change from Unix aklog to Windows aklog If afs_com_err fails to describe the error, allow the krb5 error_message function try. LICENSE MIT Change-Id: I47bb6806f1076116a68967617d32d69b98a5bba9 Reviewed-on: http://gerrit.openafs.org/852 Reviewed-by: Derrick Brashear Reviewed-by: Rod Widdowson Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit c5e362a683c5a0b2e046aa62d652ff1c83e42818 Author: Jeffrey Altman Date: Thu Nov 19 18:21:39 2009 -0500 Windows: cm_TryBulkStatus processing changes move the logging of success or failure in order to try to avoid the VS8 compiler optimizing them out. merge the bulk status information if the current cm_scache_t object is flagged with an access denied failure on the last request or if it is a readonly volume. This permits us to return something valid to the directory enumeration that generated the cm_TryBulkStatus call. LICENSE MIT Change-Id: I97e9e096e2c36b0a87baaa8d728b588aaf10f153 Reviewed-on: http://gerrit.openafs.org/858 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit dac817389081d45dab15880f34d9a35c059853c9 Author: Jeffrey Altman Date: Thu Nov 19 18:19:39 2009 -0500 Windows: when assigning a new clientModTime, hold a lock The smb server modifies the cm_scache_t clientModTime without holding a write lock creating a race condition. Fix it. LICENSE MIT Change-Id: I6f110f87ef76131965da31a8bf02685480ad9641 Reviewed-on: http://gerrit.openafs.org/857 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 985a62bcf1a3315ce0460f64e56fa667a4268f1b Author: Jeffrey Altman Date: Thu Nov 19 14:18:18 2009 -0500 Windows: modify src/rxkad/NTMakefile to avoid file copies Permit src/rxkad/domestic/* files to be compiled / installed in place. This permits the tree to build after the application of change I0796fabcf83ffcd74e533624c64e138a160dd632. Change-Id: I5616c7ab9374751dcb44bb2bce37dec40e01148a Reviewed-on: http://gerrit.openafs.org/854 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 13843d852749ba081804f3af368620db7b4b7d7a Author: Jeffrey Altman Date: Thu Nov 19 18:11:06 2009 -0500 viced: set volume sync data in bulk status rpcs The bulkstatus and inlinebulkstatus rpcs have a bug that prevents the volume sync data from being set. Currently the data is being set within the for loop only when i == nfiles. The conditional of the loop is i < nfiles so the SetVolumeSync call is never performed. This patch changes the test for performing SetVolumeSync to i == 0. LICENSE MIT Change-Id: I17e3980184ec68e38c5186e1c9637ac6e38451fe Reviewed-on: http://gerrit.openafs.org/856 Reviewed-by: Dan Hyde Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 7b272177de4c6f78db7f2315f4e30e85ab7660bb Author: Marc Dionne Date: Sat Oct 24 22:10:46 2009 -0400 Linux: Keyrings PAG handling changes We can take advantage of the fact that PagInCred now receives a kernel credentials structure as an argument (including any session keyring) to make some improvements in the handling of PAGs when keyrings are in use. These changes are effective only if keyrings are in use and we have a recent enough kernel where we can use the kernel credentials structure. 1 - Search the session keyring of the passed credentials instead of the current process' to determine the PAG, if any. This was always not really correct, and now we're able to do the right thing. In some situations such as background writeback and pre-fetching, this means that we'll now do it with the right credentials, even when in a PAG. 2 - Don't use groups at all to determine PAG membership. Doing so can lead to some inconsistent situations such as the one described in RT 125198, where a process gets access through a soon to be deleted PAG. Make PagInCred look exclusively at the keyrings. Groups are still updated to try to reflect the current PAG for now, if the passed credentials belong to the current process. Note that a process can no longer get a PAG's privileges simply by adding the corresponding groups to its group list. No behaviour change for kernels prior to 2.6.29. FIXES 125198 Change-Id: Ifb171993cc9ca9d6a97fb7312909485ec0666efb Reviewed-on: http://gerrit.openafs.org/730 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 51ece42ab438295d3807180dae34963c676f170a Author: Marc Dionne Date: Sun Nov 22 14:17:19 2009 -0500 Remove "unused" warnings from lex generated files Some (f)lex generated source files produce warnings because of unused labels or variables. Since there is limited control of the source itself, just be more permissive in this particular case with -Wno-unused. Change-Id: Ice25019f8a592a25f5084e88119b68846d900033 Reviewed-on: http://gerrit.openafs.org/867 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 85fd4e86af2a6c8a1742774ea4126b8a7b919f3c Author: Marc Dionne Date: Fri Nov 20 17:27:20 2009 -0500 Linux: hinting removal fallout The removal of the hinting missed a few things - the prototype to afs_linux_raw_open needs to be changed, as well as a few additional call sites. Change-Id: I006540cee574bca7155d9209c2d9b6702c4f6c94 Reviewed-on: http://gerrit.openafs.org/864 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 8ebade0e67c62335416ba3cfd40d19d1e152de02 Author: Marc Dionne Date: Fri Nov 20 17:50:41 2009 -0500 Revert "osi_UFSOpen returns struct osi_file *" This reverts commit 4057a9941b95f7a00c57738c1810ec5abf315e97. UFSOpen shares a prototype with MemCacheOpen because of the afs_cacheOps structure. This is why a void * is used. Revert until a more complete fix can be submitted that adresses the memcache case as well. Change-Id: I2e259c08a0bfbc695260c981d29319c2bb7c93dd Reviewed-on: http://gerrit.openafs.org/865 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 4057a9941b95f7a00c57738c1810ec5abf315e97 Author: Simon Wilkinson Date: Thu Nov 19 16:34:07 2009 +0000 osi_UFSOpen returns struct osi_file * The osi_UFSOpen function always returns a (struct osi_file *). Fix the code to reflect this, rather than casting to and from (void *). Change-Id: I3aa0bb17b547060671aa7045a8237b3926ec613f Reviewed-on: http://gerrit.openafs.org/851 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6f803428fdb1d85021cde1606498178d557a9db1 Author: Simon Wilkinson Date: Wed Nov 18 20:07:04 2009 +0000 Remove inode hinting for dcaches The VNOP read code has always contained incomplete support for inode hinting. In theory this would let us attach open cache files to dcache structures, so that we don't have the overhead of opening the file with every read that we do. However, this has been ifdef'd off ever since the first release, and is fundamentally broken - it relied upon structure elements that just don't exist, and has no mechanism for throttling the number of inode hints that are maintained. Inode hinting also required that we store an inode number within the osi_file structure (so hint validity could be checked), which causes a problem on some modern OS's. Simplify all of this, by just removing the partial hinting support. If we want to revisit this in the future, then the code is in git, but if we _do_ feel we want to keep open cache files around, it's probably better to start from scratch! Change-Id: Ia378922f7fcc24fb27b343015dbd16818302ec10 Reviewed-on: http://gerrit.openafs.org/850 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 573cd80cd145ca2d6bbfcc48499599ec4a86c0b1 Author: Andrew Deason Date: Wed Nov 18 14:33:09 2009 -0600 Define afs_maxvcount everywhere afs_maxvcount can be referenced by non-Linux code, so define it everywhere, not just on Linux. Change-Id: I6e99b6735d58823d0809a00be42a447deb3ced89 Reviewed-on: http://gerrit.openafs.org/845 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dce56fb8ceff9d052ebcebd21db9e070015142ab Author: Simon Wilkinson Date: Mon Oct 26 19:58:53 2009 +0000 Fix prepare and commit_write to do the right thing Even when we're doing syncronous writeback, as we currently do for write() operations, it's important to correctly fill, and flag the pages we're writing to. Not doing so has a huge performance penalty, as it means even when we've just written a page, we have to pull it back from the backing store for a read. This code fixes prepare_write and commit_write (for RHEL5) and write_begin and write_end (for Fedora) to correctly populate and flag pages which are being written. Change-Id: Iaa2165b9b429000dcf0c6dd452e3eb8033257277 Reviewed-on: http://gerrit.openafs.org/820 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4f91de7cf429db63bcf67466cf3fb36feb990643 Author: Simon Wilkinson Date: Sat Oct 24 15:08:52 2009 +0100 Linux: Use atomics for credential reference counts The reference count maintained as part of the afs_cred structure wasn't being maintained atomically, requiring that crfree and crhold always be called with the GLOCK held. This patch just switches to using Linux's inbuilt atomic types to maintain the reference count. Change-Id: I1787061afbb48e234b4839b38b8801168ea2f25f Reviewed-on: http://gerrit.openafs.org/726 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b9f6a8ce1898cd90c713dc4b54a27bd1644fe47a Author: Andrew Deason Date: Wed Nov 18 15:43:17 2009 -0600 Define WCOREDUMP in salvsync-server.c Some platforms do not define WCOREDUMP. Conditionally define WCOREDUMP in salvsync-server.c, and make all of the similar WCOREDUMP defines in the tree consistent. Change-Id: I197979881ade20f6e790bf41523938089379dbe3 Reviewed-on: http://gerrit.openafs.org/846 Reviewed-by: Russ Allbery Reviewed-by: Tom Keiser Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ca9a12c422ad2d29a0c865a2c35ea12fc71158e0 Author: Mickey Lane Date: Wed Nov 18 12:23:15 2009 -0500 Fix 2 errors in Windows release Notes Description of registry key HKLM\ SOFTWARE\ OpenAFS\ Client\ Server Preferences\ File (and \ VLDB) states "256" - should be 15 - and "ServerPreferences" should have a space between the words. Change-Id: Ia2147f920ecc023d26250efaf9815f1b09d1550a Reviewed-on: http://gerrit.openafs.org/840 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit aa9072ce40f7af11919252da82179b45481eb878 Author: Jeffrey Altman Date: Fri Nov 13 13:56:20 2009 -0500 Windows: cm_BkgDaemon requeuing only applies to BkgStore cm_BkgDaemon currently requeues failed requests for a variety of errors. It only applies to cm_BkgStore requests. The current code only supports cm_BkgStore and cm_BkgPrefetch operations. Additional background operations may be added in the future. If requeues are meant to apply to the new operations, they should be explicitly specified. Specify cm_BkgStore explicitly now. LICENSE MIT Change-Id: Iae7c5fe4f2f7bc701ebe93500626b68f49b0063f Reviewed-on: http://gerrit.openafs.org/824 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 4c58b1db9f34c220d839dd4a1b38ed11e9ce2197 Author: Jeffrey Altman Date: Sat Nov 14 16:33:31 2009 -0500 Windows: Improvements to background fetch processing Log offset and length in cm_BkgPrefetch() Convert mxheld to rwheld in cm_BkgPrefetch() now that cm_scache_t objects use rwlocks. Do not clear CM_SCACHEFLAG_PREFETCHING from within the error returns from cm_CheckFetchRange(). Let the caller decide if that is appropriate. Add CM_BUF_CMBKGFETCH cm_buf_t cmFlag to make it possible to quickly detect if a background fetch operation has already been queued for a particular cm_buf_t data range. LICENSE MIT Change-Id: I4ac9a2f84ddd64cba86612d7a2abe849bd0bec0b Reviewed-on: http://gerrit.openafs.org/827 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 87b1b849811cb4c8c7d3a7e9fd22e5a9f8b3fadc Author: Jeffrey Altman Date: Sun Nov 15 00:11:24 2009 -0500 Windows: buf_DirtyBuffersExist uses fileHashp not allp list pointer buf_DirtyBuffersExist() should use the fileHashp pointer and not the allp list pointer in order to walk the hash table list. LICENSE MIT Change-Id: Ie043647cbeec479abe0d96b3b5405130f2ba1aac Reviewed-on: http://gerrit.openafs.org/828 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 3f3a76c0ca2a6e098f337e28cdfcb39ee865446a Author: Jeffrey Altman Date: Sun Nov 15 15:48:00 2009 -0500 Windows: Permit custom version numbers and default cellname Permit custom version numbers and default cellname to be specified using environment variables. LICENSE MIT Change-Id: If72430a33d8317fcb59d2f83769193e79984046c Reviewed-on: http://gerrit.openafs.org/829 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 84cc4f2b367399cdadf544c473566c3ffa908535 Author: Andrew Deason Date: Wed Nov 18 14:14:16 2009 -0600 src/afs/afs_user.c typo Commit eb8e55bba7740a87e07ef07bb4b789e6d4e36f0d had a paren-related typo. Correct it to make afs_user.c build on some platforms again. Change-Id: Iec4634b4c0f1769c81bf9baab0d2cc53f47aaa9c Reviewed-on: http://gerrit.openafs.org/843 Reviewed-by: Marc Dionne Reviewed-by: Alistair Ferguson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 9c61e1196a4eb5131cff555fbaeb357bf2e78c1f Author: Andrew Deason Date: Wed Nov 18 14:08:49 2009 -0600 Define T_SRV when not defined for us Define T_SRV when we don't have a usable arpa/nameser_compat.h, just like we do with T_AFSDB. Some platforms like AIX do not have an easily-usable arpa/nameser_compat.h. Change-Id: I8406a3d2b1f98d0849a1739875656432869ea3c4 Reviewed-on: http://gerrit.openafs.org/842 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c42222c40e3c4ef80edcdaa34b976505ae9421ac Author: Andrew Deason Date: Wed Nov 18 14:25:48 2009 -0600 AIX: Missing brace in afs_vnop_flock.c Commit 50f6529cf1f191606f55add4cabe53fceab492ed missed a brace in the AIX lockIDSet. Add it back to make afs_vnop_flock.c build again. Change-Id: I09c5ee58ee5258fb904fd752213eb28a1e80291a Reviewed-on: http://gerrit.openafs.org/844 Reviewed-by: Alistair Ferguson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 0a8e7b15486f5baa089eef661cdf0924af736160 Author: matt@linuxbox.com Date: Tue Oct 6 08:42:51 2009 -0400 viced ihandle boost Make ihandle file descriptor cache parameters tunable, and accommodate platforms where max open files is large. Expand the fd cache hash table to 2048 entries. Raise fd cache size automatically to match configured number of lwps. NOTE: This code has been tested on Centos 5.3 x86_64, on VMWare, 2 physical, 2 logical CPUs (in tandem with viced_more_threads). LICENSE BSD Change-Id: If68eda6e1c955e026b250ca52bddf0b8383959c9 Change-Id: I5fbbec95523ea9cd9ff42dcf43f17db94c7bb161 Reviewed-on: http://gerrit.openafs.org/584 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 82c131f6c5b57c224d157e810df264b66d052ba0 Author: Simon Wilkinson Date: Wed Nov 18 11:23:06 2009 +0000 Name chunkOps structure elements Name the structure elements in chunkOps, to reduce the danger of things getting misaligned when new function pointers are added. Change-Id: I3d22130f9bd9625d836681531646b9eac75329f5 Reviewed-on: http://gerrit.openafs.org/839 Reviewed-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 42516f2c0bb6445c9f870cf1943efa016d66349b Author: Michael Meffie Date: Wed Nov 18 14:05:02 2009 -0500 fix for volser transaction object race conditions Spell AFS_PTHREAD_ENV correctly and fix missing pthread_mutex_init() argument. Change-Id: I9a6397ef5ba3ef7197f3d927759258be31914fd7 Reviewed-on: http://gerrit.openafs.org/841 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit a2744cab12c87a8c42ba40a9f186a1f05c6886f8 Author: Simon Wilkinson Date: Mon Nov 16 22:52:01 2009 +0000 Linux: Fix lock ordering The inode mutex (or semaphore) should be held before acquiring the alloc semaphore. Fix the lock ordering to avoid theoretical deadlocks. Change-Id: Ifc572083dc92fff51be6785b0bcc92152fab1d73 Reviewed-on: http://gerrit.openafs.org/835 Reviewed-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 22541ea8323434cc555d71daf3c90b66e34c7c87 Author: Marc Dionne Date: Tue Nov 17 17:59:58 2009 -0500 aklog build fix: com_err.h header Fix this build error: aklog_main.c:67:21: error: com_err.h: No such file or directory On some systems this system header is actually "et/com_err.h". Cope by checking for this at configure time and using that location if needed. Change-Id: Iaf4fb4fe157ff8e54aa043785377706eab6fb3d1 Reviewed-on: http://gerrit.openafs.org/836 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 36524b2ed73a2774ee1f6242208a1395be7736a8 Author: Simon Wilkinson Date: Fri Nov 13 09:50:29 2009 +0000 Rationalise our include paths Our include paths are a bit of a mess. Fix these so that they're more rational, and more in line with normal coding style. In particular: *) Don't include all of the subdirectories of our top level include directory. If a file wants afs/file.h, it should include that, not "file.h" *) Try to avoid including '.' in the search path (although objdir builds make this harder) *) Don't blindly include other directories from the code tree in the search path. If a package wants another packages header, then it should get it from the include directory *) Use the convention that quoted includes ("") pick up local headers. Bracketed includes (<>) pick up ones from the top level include dir *) In directories which pull in files from multiple packages, don't blindly put all of the package directories in the search path. Specifically include the file's package directory when required The big change here is that it's no longer possible to hide a system include by placing a header of the same name in include/afs. The most common case where this was happening was for 'assert.h' Change-Id: I0796fabcf83ffcd74e533624c64e138a160dd632 Reviewed-on: http://gerrit.openafs.org/834 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cb6681c0d189d15fb5ff0d21cf47c9ac223a98c5 Author: Derrick Brashear Date: Mon Nov 16 20:58:11 2009 -0500 ktc remove unused variable inadvertantly introduced non-linux warning (error) due to unused variable. fix it. Change-Id: Ie44013fdf2ff8e5d401f5598a7ec628fd887588a Reviewed-on: http://gerrit.openafs.org/832 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 146b732fc877a23d515191471603a9ef0a655501 Author: Simon Wilkinson Date: Fri Nov 13 16:40:53 2009 +0000 Translate messages from ktc_SetToken Error messages from ktc_SetToken weren't being passed through com_err, leading to the confusing unable to obtain tokens for cell inf.ed.ac.uk (status: 11862788). error message. Instead, call into afs_com_err here, which gives: a pioctl failed while obtaining tokens for cell inf.ed.ac.uk Much nicer ... Change-Id: Id4c7e6f6a2f52efc6ac1db9fa007ba1a452092fe Reviewed-on: http://gerrit.openafs.org/822 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit fda55b178c12bba1474ae2c63bc7b803cdc9730f Author: Simon Wilkinson Date: Fri Nov 13 16:33:52 2009 +0000 Better errors from aklog Since the great com_err fracture, aklog has only returned decent error messages from AFS, leaving Kerberos errors untranslated. Needless to say, this causes user confusion and distress. This patch uses the error display proc hook to call out to the real com_err in situations where AFS can't supply an error message, giving clearer errors for Kerberos problems. Change-Id: I8832b755beb84c593e1b2eace5c356e71a582b2a Reviewed-on: http://gerrit.openafs.org/821 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9bfd03d723a9cf17673f40513a7adde1d503bcbc Author: Derrick Brashear Date: Wed Nov 11 19:36:01 2009 -0500 asm unexecutable stack make stack not executable in assembled files FIXES 125491 Change-Id: I396680b6877843201f6c07d5607385044abd5e74 Reviewed-on: http://gerrit.openafs.org/818 Reviewed-by: Simon Wilkinson Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 65db6150246294e49e0c4a1a0e64780d040faf7a Author: Jeffrey Altman Date: Sat Nov 14 16:24:41 2009 -0500 Windows: Code signing with cross-signed certificates Permit the version of signtool.exe to be specified with the SIGNTOOL environment variable. Add the CODESIGN_CROSS_CERT environment variable to specify the cross-signed certificate to be used LICENSE MIT Change-Id: Ib549e31f1f240e0de2cedfabac9bb998ee58a517 Reviewed-on: http://gerrit.openafs.org/825 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 7d44a087712def4b07011212f978c6d4572bf0de Author: Jeffrey Altman Date: Sat Nov 14 16:27:37 2009 -0500 Windows: Error mapping for VBUSY and VRESTARTING Add error mapping for VBUSY and VRESTARTING to cm_MapRPCError(). Return CM_ERROR_ALLBUSY. This prevents an unknown error from being returned to the SMB redirector. LICENSE MIT Change-Id: Ie8bf8bc88e087a8eef428444ca07c7ca7c4621a8 Reviewed-on: http://gerrit.openafs.org/826 Reviewed-by: Jacob Thebault-Spieker Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 1594cf98926ceef1de36010335f9ca19cc050bad Author: Jeffrey Altman Date: Sat Oct 31 10:33:00 2009 -0400 Windows: Use STATUS_IO_TIMEOUT where STATUS_TIMEOUT was returned STATUS_TIMEOUT causes the smb redirector to drop the connection. STATUS_RETRY is interpreted by the smb redirector as if the error was generated by the transport stack and not the smb server. STATUS_IO_TIMEOUT is listed in the SNIA CIFS 1.0 spec as a valid return code for the smb server. Lets us that. LICENSE MIT Change-Id: I842a78cde3d975c88bbeb64294dd53cc8b101047 Reviewed-on: http://gerrit.openafs.org/831 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 4c25f00088a603723b75e60d6b808a89034b33d3 Author: Jeffrey Altman Date: Sun Nov 15 01:01:23 2009 -0500 Windows: Fix port assignment to use network byte order Service port numbers are stored within sockaddr* structures and returned by afsconf_FindService() in network byte order. getAFSServer() and afsconf_GetAfsdbInfo() accept and return service port numbers in network byte order. When processing the special case for 7002 and 7003 in afsconf_GetAfsdbInfo(), the comparisons must consistently use network byte order. When assigning port numbers for AFSDB lookups, getAFSServer() must use network byte order. Document the use of network byte order for each variable. LICENSE MIT Change-Id: I2163826e8a234a1d19474b2eba3d36335ba12afb Reviewed-on: http://gerrit.openafs.org/830 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 9d245a26228a80e4584cb3b481dffa3fd77514cb Author: Jeffrey Altman Date: Wed Oct 21 18:41:59 2009 -0400 Windows: ports in the cache manager are stored in network byte order When assigning ports from SRV/AFSDB lookups, convert to network byte order when assigning them to cm_server objects. LICENSE MIT Change-Id: Ic22a445c9f6433f9f7544774ea9952d82fcdba8a Reviewed-on: http://gerrit.openafs.org/791 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit c53abbb3e8d14643f3f82999cbe24fb12d358ce0 Author: Andrew Deason Date: Wed Nov 11 11:23:49 2009 -0600 Make ktc_curpag also detect ONEGROUP PAG gids ktc_curpag falls back to looking at the group list if the VIOC_GETPAG pioctl fails. If we're in AFS_LINUX26_ONEGROUP_ENV in the kernel, though, ktc_curpag still looks for two groups, instead of the one combined group. Add a check for the big one group in the fallback if we're on LINUX26. Change-Id: I28e5eda5c62f13a6fb466c8a2b04d2628706498f Reviewed-on: http://gerrit.openafs.org/815 Tested-by: Andrew Deason Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear commit 5e99d56cf2a8c4c9789bc7ace04a804d07e6238f Author: Simon Wilkinson Date: Wed Oct 21 23:17:15 2009 +0100 Use set_page_writeback and end_page_writeback Calling set_page_writeback and end_page_writeback is necessary to ensure that the dirty page radix tree and the page dirty flags tally. The results of end_page_writeback are also used by the bdi code to prioritise writeback. The Linux kernel documentation contains further warnings of doom for what may happen due to not calling them. Adding set_page_writeback and end_page_writeback also allows us to unlock the page earlier (the page can be locked any time after the writeback flag is set). This means that we're not calling the backing filesystem's ->write function with our pages locked, and should help reduce contention and the potential for deadlocks there. Change-Id: I9130b2ad9a09c6b9b16a0f63d7b4a614a93de8d3 Reviewed-on: http://gerrit.openafs.org/819 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit dc85abcaa6e3423452078e36bbfcd281e613c407 Author: Marc Dionne Date: Thu Oct 29 19:58:00 2009 -0400 Linux: Use the kernel's credentials structure Recent kernels (2.6.29 and above) have a separate ref-counted structure for holding credentials. Use it directly instead of keeping a separate afs specific structure that shadows the same information. Also adapt Linux for the change from cr_xxx to afs_cr_xxx wrappers. Reference counting is done with the appropriate get/put calls. Change-Id: I1135bb5a66cda51cee4fa9f3f3e63eaa9af28f61 Reviewed-on: http://gerrit.openafs.org/797 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 97d3fcfcd1617bafa6ee62d291f09b2e8bb6daf7 Author: Andrew Deason Date: Wed Nov 11 10:51:19 2009 -0600 Do not check *aoutSize in PGetPAG *aoutSize is always zero in pioctls, since afs_HandlePioctl handles checking the output buffer size, and sets outSize to 0 before calling the pioctl. So, PGetPAG was always returning E2BIG; remove the check to make it work. Change-Id: Ibed16b35ea14237f44a494add8c7a4a48e0c2b71 Reviewed-on: http://gerrit.openafs.org/814 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e854e26ef1a2ddb26d926891ffb32c1f46293878 Author: Simon Wilkinson Date: Wed Nov 11 10:34:30 2009 +0000 Update warning inhibition A number of recent changes haven't caught all of the locations where warning inhibition can be removed. This patch updates all of the inhibitions to reflect the current state of the tree when built with gcc4.2 Change-Id: I7bad4fee1258f4e37fd729cda84711fed66acbc9 Reviewed-on: http://gerrit.openafs.org/813 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 748eaf804119a632204f0c6cce5e07ec4c372c13 Author: Simon Wilkinson Date: Wed Nov 11 10:32:59 2009 +0000 Prototype kalog_Init Prototype the kalog_Init function in kauth_internal.h, and remove the warning inhibition from kaserver.c Change-Id: Ic48d199126629f1c0c2e498081be97901678ec70 Reviewed-on: http://gerrit.openafs.org/812 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 420dfad900267720d1665a67c92c567a341728c7 Author: Simon Wilkinson Date: Wed Nov 11 10:28:29 2009 +0000 const char paths for ubik_ServerInit ubik_ServerInit* take a pathname, which should really be a const. It already is in many of the callers, some of which remove the const by casting, the others throw errors. Make pathName const for all of ubik_ServerInitByInfo, ubik_ServerInit and ubik_ServerInitCommon. Update all of our callers to remove the now unecessary casting. Remove the now uneccessary warning inhibition on vlserver/vlserver.c Change-Id: I009103dc49e4473eec65ebd75aab727915c26f3c Reviewed-on: http://gerrit.openafs.org/811 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 420a544ecea96d5f72e5446f1f75add666b4f463 Author: Simon Wilkinson Date: Wed Nov 11 10:19:07 2009 +0000 Fix des key type issue in bosoprocs The call to afsconf_AddKey was using 'akey' rather than 'akey->data'. As data is the first element of the akey structure, these are actually identical, but the compiler sees it as a type error. Fix to use the correct name, and remove the warning inhibition. Change-Id: Id4775a836276ddd6f5ae105c298dcc3c68b92145 Reviewed-on: http://gerrit.openafs.org/810 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit be305ae119c4bd71431596f81d97f9195faa069f Author: Simon Wilkinson Date: Wed Nov 11 10:13:57 2009 +0000 Prototype UV_Bind Publicly prototype UV_Bind in volser_prototypes.h Make dump.c use the public prototype, instead of an incomplete private copy, and remove the warning inhibition that was required to support the private copy. Change-Id: I945192454702d79083a10062adaf2cb124d14a35 Reviewed-on: http://gerrit.openafs.org/809 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bab6fd227f5724c4e4ca5d0ba1dc64e21ed21f97 Author: Simon Wilkinson Date: Wed Nov 11 08:32:48 2009 +0000 Remove 'M' variants of lock macros Since the beginning, we've had M variants of the lock macros, which are identical to the normal form. Dispose of these variants, to make it clearer what's going on. Change-Id: I0b7708ec670ef0edb4c1dc21d472e5041d31f6a2 Reviewed-on: http://gerrit.openafs.org/807 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cbe83cb1a12fddc63c1775243c47fb43da40f9c1 Author: Simon Wilkinson Date: Wed Nov 11 09:10:36 2009 +0000 Fix warnings from afsconf_SetExtendedCellInfo If a is declared as an array, then a == &a. However, the compiler still gives a type warning when usign the & form, as the types no longer match. 5f720faab920a1007327de415ceaf187c16fdbe6 fixed this problem for calls to GetExtendedCellInfo - do the same for the corresponding Set calls. Change-Id: I8204afe7df0c0db1d059cb3f6ab61eff1cdf9140 Reviewed-on: http://gerrit.openafs.org/808 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c90132f2af3455948f029f9c475c768e476f66e4 Author: Simon Wilkinson Date: Wed Nov 11 08:28:32 2009 +0000 Include signal.h for sigfillset f6ce2af008feb615e94d924fc9f81e2098e73e7c added a call to AFS_SIGSET_CLEAR to vol/volume.c. However, it didn't add signal.h to this file. As AFS_SIGSET_CLEAR calls sigfillset(), this broke checked builds. Add signal.h to the list of headers to fix the build warning. Change-Id: Ib861abfbd153f6ef2ff4b42ea03b5604a95975d4 Reviewed-on: http://gerrit.openafs.org/806 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d616d1ee99794525aa2d778d11552c1986007ebb Author: Marc Dionne Date: Tue Nov 10 18:36:55 2009 -0500 krb_udp.c warning fix This file generates a warning because the left side of a variable assignment is commented out. Keep the effect of the line (incrementing packet) but remove the unused casting and reference, and remove the comments that date from the original IBM source. Leave a new comment in place in case the information is useful. Adjust the Makefile and README.WARNINGS to account for the change. Change-Id: I944e1c488e39411d32d700cba2d3ef567eddddb4 Reviewed-on: http://gerrit.openafs.org/804 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c4dfacc9341cd47805de5cd2d2de151199344a67 Author: Michael Meffie Date: Mon Nov 9 11:03:10 2009 -0500 cm: address race condition in afs_QueueVCB Access the vcache callback member after taking the xvcb lock to avoid the server object from being freed in FlushServer on another thread. Eventually, we should have a ref count on avc->server. FIXES 125596 Change-Id: I760819b1632d0e8188eaa34531239951aab980d3 Reviewed-on: http://gerrit.openafs.org/800 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2d0824245c030b08f90972ea0756fccf981263c0 Author: Marc Dionne Date: Tue Nov 10 18:16:45 2009 -0500 src/pam/afs_auth.c warning fix ka_UserAuthenticateGeneral expects an afs_int32 pointer for the password_expires argument. A (long *) was used in afs_auth.c, generating a few warnings. Change-Id: Iafc92e72022644ff23c642e801d51bd4387afa88 Reviewed-on: http://gerrit.openafs.org/803 Reviewed-by: Russ Allbery Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 954f67c682bdceb10c58646336ae0178ad47e317 Author: Simon Wilkinson Date: Wed Nov 11 08:12:51 2009 +0000 cr_gid is already used by Darwin Commit eb8e55bba7740a87e07ef07bb4b789e6d4e36f0d introduced a variety of functions for accessing members of the credentials structure in a platform independent way. Sadly, cr_gid is already defined by the Darwin platform headers (on Darwin, the GID is just the first of the user's groups) Turn cr_gid() into afs_cr_gid() to avoid this problem, and for consistency, also rename cr_uid, cr_ruid, cr_rgid, and the corresponding set_* functions. Change-Id: I82d74900324d079b5a5c8985510a2c9586c4a526 Reviewed-on: http://gerrit.openafs.org/805 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit fc5e2a4d81f535db29cea962b26748a04f1bca4d Author: Derrick Brashear Date: Mon Nov 9 13:10:55 2009 -0500 unix srv record network byte order fix correctly process dns lookups corresponding to the srv record changes in network byte order Change-Id: Id70f972331582912ca984ae1b1c027c7b702a22c Reviewed-on: http://gerrit.openafs.org/801 Reviewed-by: Thomas L. Kula Tested-by: Russ Allbery Reviewed-by: Russ Allbery commit 24de8dae6d5d9ef72bd89877eb2f29c401024504 Author: Russ Allbery Date: Sun Nov 8 17:31:25 2009 -0800 Update afsd cache and firewall details Cache parameters are discussed in two locations in the afsd man page, and the first copy had not been updated for the new auto-tuning of the chunk size and the stat parameter. Fix both. Note that the firewall requirements for klog only apply if you're using kaserver and klog. Kerberos v5 has its own requirements, but this is not the place to talk about them. Change-Id: I9cdaaa71351a64cecc1b6904efba87d4871d42fb Reviewed-on: http://gerrit.openafs.org/798 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c9197a1f32f3ba69b4c609726532977324dabd7b Author: Simon Wilkinson Date: Mon Nov 9 23:20:14 2009 +0000 Fix locking in FlushVCBs when called from discon The disconnected code doesn't request locking from FlushVCBs when it calls it, but also doesn't hold the required locks itself. Fix this. Change-Id: I2450df4b19b2d44dca80990197e5e7637c9c8334 Reviewed-on: http://gerrit.openafs.org/802 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit eb8e55bba7740a87e07ef07bb4b789e6d4e36f0d Author: Marc Dionne Date: Thu Oct 29 19:23:28 2009 -0400 Unix client: wrappers for credentials structure access This patch introduces and makes use of wrappers for access to credentials structure members: cr_uid (afs_ucred_t *) cr_ruid(afs_ucred_t *) cr_gid (afs_ucred_t *) cr_rgid(afs_ucred_t *) cr_group_info(afs_ucred_t *) Inline functions are also introduced to set values: set_cr_uid (afs_ucred_t *, uid_t) set_cr_ruid(afs_ucred_t *, uid_t) set_cr_gid (afs_ucred_t *, gid_t) set_cr_rgid(afs_ucred_t *, gid_t) set_cr_group_info(afs_ucred_t *, struct group_info *) This will allow an architecture to make use of an alternate structure to hold credentials. In particular it will allow the linux client to be modified to use the kernel credentials structure directly instead of shadowing it into our own local structure. There should be no functional change. Change-Id: I7739196a0691a9c30887043b085e4878e88780ae Reviewed-on: http://gerrit.openafs.org/768 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f6ce2af008feb615e94d924fc9f81e2098e73e7c Author: Michael Meffie Date: Thu Nov 5 11:08:08 2009 -0500 viced: avoid useless core if shutdown during initialization Avoid leaving an unnecessary core file when the fileserver is shutdown while still attaching volumes. The bosserver issues SIQUIT to shutdown the fileserver which leaves a core file by default. Register the fileserver shutdown signal handler earlier in the fileserver initialization, before the long running volume attachment is started. The volume package shutdown has been changed to allow the VShutdown to gracefully abort the volume attachment (or pre-attachment for DAFS). FIXES 124485 Change-Id: Ic22e68afb7bcc54ad956b2ae093375f29b969191 Reviewed-on: http://gerrit.openafs.org/764 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d98d3060f880f4c7d4089fd2fb981ee08fd1486f Author: Simon Wilkinson Date: Sat Nov 7 11:52:59 2009 +0000 Add printf-style format checking Add the AFS_ATTRIBUTE_FORMAT macro which can be used to turn on printf-like format checking for our va-arg log functions. Enable this checking for volser's Log(), and fix the fallout from doing so. Change-Id: Ic5ab93ba731856f1f90e894d711b0f84298ded12 Reviewed-on: http://gerrit.openafs.org/789 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 392dcf676bd3642fc114abb29b79888055d8c409 Author: Simon Wilkinson Date: Wed Nov 4 20:15:36 2009 +0000 Complete removal of DUX client code With commit cfce015ead18c72ee921f480c73e9247a98838fc (in 2006) all of the files specific to the DUX cache manager were removed. However, the DUX code within general files remained untouched. This patch completes the removal of the (entirely non-functional) DUX client, by removing all cache manager code which is for AFS_DUX*_ENV and AFS_OSF_ENV platforms. It also takes the advantage of this removal to simplify some #ifdef ladders, and indents others (purely because I needed the indentation to work out what on earth was going on!) Change-Id: Icbea5ed3ef94c5e902cdb0d722be85f376c3d296 Reviewed-on: http://gerrit.openafs.org/785 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c90134fd1f1b5cd16052c5fdc91ddd1b1ac6e19a Author: Simon Wilkinson Date: Wed Nov 4 18:09:51 2009 +0000 Move vnode macros to their own directories The tree is inconsistent whether macros for access to vnodes are provided by the OS directories, or in afs_osi.h. This makes things very confusing, especially in the Linux case where macros are provided in afs_osi.h, and then promptly redefined in LINUX/osi_machdep.h Adopt a convention where default macros are conditionally provided by osi_machdep.h. Where these aren't wanted, they should be disabled in osi_machdep.h, and OS specific versions provided in the individual OS's directory. Change-Id: I47bc969af3f6670db9348689b5ce60181fd44f21 Reviewed-on: http://gerrit.openafs.org/784 Tested-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 457303440042ad43e61652b6ca11c84fab390b82 Author: Marc Dionne Date: Sat Nov 7 10:51:52 2009 -0500 Linux: always use afs_maybe_unlock_kernel In one error case in afs_linux_lookup unlock_kernel() is called directly instead of using the conditional "maybe" form. If the config is such that the BKL is not taken, this can result in an attempt to unlock when the lock has not been taken, and can cause an oops. Change-Id: I27d5db58e9b9d45d925b24e27bc43960499c6ead Reviewed-on: http://gerrit.openafs.org/790 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 09c4c1978b8901cac0191900c8679095b7e53e6d Author: Simon Wilkinson Date: Sat Nov 7 01:10:22 2009 +0000 Add error_table.c to gitignore in comerr error_table.c is a build product for comerr, should we should gitignore it Change-Id: Ie47ae4daec734b31c884e4732d053635ee1048bb Reviewed-on: http://gerrit.openafs.org/788 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit fd592c7674d4aa44dda90998b54d7b56947f6ed8 Author: Andrew Deason Date: Tue Nov 3 21:22:50 2009 -0600 Cleanup VOffline log message Make the 'Volume X (Y) is now offline' messages appear more sanely in the log; logging as one line at once. Change-Id: I8a3cf986fb30e292e509237357bd1039f2f181b9 Reviewed-on: http://gerrit.openafs.org/782 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 95770bf95ad766207252ea0c2d2b5ab2415c896f Author: Simon Wilkinson Date: Wed Nov 4 23:40:39 2009 +0000 Prevent VLRUQ race in ShakeLooseVCaches When ShakeLooseVCaches is called from afs_Daemon, the xvcache lock is not held. This means that if the GLOCK is dropped for any reason (for example, whilst purging the dentry cache), then ShakeLooseVCaches can be raced, end we can end up attempting to flush the same vcache twice. The symptoms of this in Linux are that we oops in clear_inode. Get the xvcache lock in afs_Daemon(), before calling ShakeLooseVCaches. Also, remove the conditional GLOCK code from that function. If we don't have the GLOCK on entry, then we're really in trouble (and both code paths - afs_Daemon and afs_NewVCache should get the GLOCK for us, anyway) FIXES 125589 Change-Id: I3fe5b41a661cd162ec73c51492925ad87c6d4c13 Reviewed-on: http://gerrit.openafs.org/781 Reviewed-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 86858bdfb6e25168828d8595f387ef5919e0df3a Author: Rainer Toebbicke Date: Fri Oct 30 12:10:21 2009 +0100 Correct diskused and files when cloning a volume Recalculates a volume's disk space used and number of files upon every clone where it is effortless. Even though tracked mostly correctly, bugs and accidents leave their traces which only a salvage would correct. Change-Id: Ied6fb9eb3944b6e30eac175fe42649c5b7cfaefb Reviewed-on: http://gerrit.openafs.org/756 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2df6f25f61cc888bc2a8fb3ccab1de37fc4c04b0 Author: Derrick Brashear Date: Tue Nov 3 19:26:33 2009 -0500 macos fstrace msgcat search path everything else on osx will look for config in /var/db/openafs; make fstrace do the same Change-Id: I7b787435343b15c82cd8eb8f3ed00096d469e888 Reviewed-on: http://gerrit.openafs.org/772 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 848b781d114cbf5cd245273f37be97f64047c8cc Author: Derrick Brashear Date: Tue Nov 3 19:25:23 2009 -0500 macos 10.6 64bit trace fixes the 64 bit pointer massaging was incomplete for kernel tracing on macos. add in the missing cases. Change-Id: I38eb608c233819ab437adec25e2cd3afac3e234e Reviewed-on: http://gerrit.openafs.org/771 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c41d3b21323de122fc0a60dc602a5377dfb19d3e Author: Marc Dionne Date: Wed Oct 28 17:54:32 2009 -0400 Linux - Fix disk cache access for selinux/AppArmor constrained processes Preserve the credentials used for cache initialisation and use then whenever disk cache files are opened. This takes advantage of the credentials separation work from David Howells available in kernels 2.6.29 and above. Access to cache files was done under the security context of the user process, causing processes constrained by selinux or AppArmor to fail to access AFS cache files and causing the cache manager to panic. Besides the RT tickets, should also fix the following Ubuntu bugs: 415766 429260 457779 459299 FIXES 92944,125544 Change-Id: Ief8acd65c1a3e4d8c951f80bfd65f8340b8cec34 Reviewed-on: http://gerrit.openafs.org/752 Reviewed-by: Derrick Brashear Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit cbe580fee176c9e9e083379129c309fd15d0f24c Author: Jeffrey Altman Date: Fri Oct 23 09:54:35 2009 -0500 Check for (hostFlags & HOSTDELETED) after h_Lock_r Many callers of h_Lock_r do not check if the HOSTDELETED flag is set, even though it could have been set while waiting for the host lock. Add checks for it everywhere we call h_Lock_r and we care if the host has been deleted. FIXES 125507 Change-Id: Id1430529a1afdb5e2af29d40148877f5e4260a41 Reviewed-on: http://gerrit.openafs.org/716 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f08c714f8800aaa28177c3d58e7a5641af61d7de Author: Andrew Deason Date: Mon Nov 2 12:19:45 2009 -0600 DAFS: Avoid SALVSYNC communication during shutdown Avoid trying to contact the salvageserver for any reason while we are shutting down. During shutdown the salvageserver may not be around anymore, so any SALVSYNC communication will appear to hang. Just set a global flag to indicate 'no-SALVSYNC' on shutdown, in addition to the thread-local flag we already have. Change-Id: Id96f20917fd0753b4934a0377b91032b2ea3d0dc Reviewed-on: http://gerrit.openafs.org/765 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 5e6842283f5c2fdf0fe3306993a6e18c2e590716 Author: Andrew Deason Date: Mon Nov 2 17:18:19 2009 -0600 DAFS: Wait for exclusive ops in FSYNC_VOL_OFF In the FSYNC_VOL_OFF handler, fssync-server.c errors out if the call to VGetVolumeByVp_r fails. However, this can fail if the volume is in an error state such as SALVAGING. Normally we don't even call GetVolume when the volume is salvaging, but the volume state can change to SALVAGING inside GetVolume. This is particularly likely to happen on a demand salvage, since we switch to the SALVSYNC_REQ state when scheduling the salvage, and if we are still in that state when the salvaged child requests a VOL_OFF, we will fail to get the heavyweight ref. Fix this in two ways. First, we VWaitExclusiveState_r before examining states for the short-circuit logic so our view of the volume state is more accurate. Second, re-examine the volume state after the call to GetVolume, and perform the same short-circuit logic, since the volume state may have changed during GetVolume. Change-Id: I4ebb87691c28170b42e0056b342477a12d0f6888 Reviewed-on: http://gerrit.openafs.org/769 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 93d48b1735b88b3051357307bdbebf5da9872d69 Author: Dan Hyde Date: Thu Oct 29 12:07:47 2009 -0400 Add array bounds checking in h_Enumerate When hostList is not properly NULL-terminated, the current code does not protect from buffer overflow. The following patch prevents buffer overflow, prints a message, and asserts. On our Linux hosts, we never reached the original assert, as there is a problem handling the segfault the buffer overflow causes. FIXES 125506 Change-Id: Ifce92c593d17050e45add9e37a7a9ed4fbc377ef Reviewed-on: http://gerrit.openafs.org/757 Reviewed-by: Dan Hyde Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 715c67f2fb3c1756f0c9cee0bc3258a3e378d3fd Author: Marc Dionne Date: Sat Oct 31 13:27:18 2009 -0400 Linux: Fix write_begin configure test for recent RHEL kernels Recent RHEL kernels now define simple_write_begin, which was used as a test for the write_begin address_space op. This makes the test succeed when it shouldn't, and breaks the build. Rewrite the test to actually check the address_space operation. Change-Id: Idac9b318ff716b61bf8ca4508d2dbdbfbad5b50d Reviewed-on: http://gerrit.openafs.org/759 Reviewed-by: Simon Wilkinson Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 5a537f071970c38881fde1ad8508775fafd7489d Author: Marc Dionne Date: Sat Oct 31 08:54:52 2009 -0400 Fix memory allocation warnings at shutdown At shutdown we check for unfreed memory allocated with AllocSmallSpace and AllocLargeSpace and complain in the syslog if there are dangling pieces. This patch takes care of a few cases that always showed up as warnings, even after a simple start-stop of the client. - The cacheInode file needs to be closed before the checks, since it uses a large piece for its struct file. - The ICL logging code allocates 6 small pieces that are never freed. Add a shutdown_icl() function that releases everything. While we're at it, correct one place where we allocated with afs_osi_Alloc but freed with osi_FreeSmallSpace, confusing our accounting. Change-Id: I4c28c848f155dec9d89e6199cde34209227ca5c9 Reviewed-on: http://gerrit.openafs.org/758 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8b3d2c1a3c9c430bb28e8d209d8399a9dc635f4b Author: Marc Dionne Date: Thu Oct 29 17:11:34 2009 -0400 Linux: remove unused cr->next member in struct afs_cred This field was once used to track allocations in a credentials pool. That code was removed a few years ago but the field remained. Change-Id: Ieac642d7d55c4da766a5a3aa8ff790a514b606d6 Reviewed-on: http://gerrit.openafs.org/753 Reviewed-by: Simon Wilkinson Reviewed-by: Dan Hyde Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit afdfbefe9cbf1818bee0072d2845fd02f7ac69a4 Author: Simon Wilkinson Date: Thu Oct 29 18:53:30 2009 +0000 Cleanup cache bypass This patch cleans up the cache bypass code so that it uses a consistent form of indentation throughout the file. It also changes the do { } while(0); macros to omit the trailing semicolon, as macro definitions with trailing semicolons break normal coding conventions. Change-Id: Id5161fe4b1ba27110e41ed27e14a2bb3c9cccd4a Reviewed-on: http://gerrit.openafs.org/754 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 416e2f11c35f5d55f91090b30b4db1a9bf6d6e07 Author: Andrew Deason Date: Wed Oct 28 11:06:47 2009 -0500 Avoid using released hosts Since h_Release_r has the possibility of freeing a host, we should not be using a host after it has been released. A few places can still use a released host, potentially causing heap corruption, double frees, and generally weird behavior. So either move calls of h_Release_r until after we finish using a host, or make sure to set the pointer to NULL after it has been released. Change-Id: I3d5275c3862003e372d3c19a5462e62bf9cb269e Reviewed-on: http://gerrit.openafs.org/747 Tested-by: Andrew Deason Reviewed-by: Dan Hyde Reviewed-by: Derrick Brashear commit 28ccbd1ad88f8cee34515b0552441083c310aa1d Author: Simon Wilkinson Date: Thu Oct 29 18:42:41 2009 +0000 Coding style cleanup Our style for function definitions has the name of the function as the first item on a new line - this means you can find a definition by using grep ^functionName. Fix the disconnected code to follow this style. Change-Id: I925039070f2bbbd97f04fbee006ea08df92d7cf5 Reviewed-on: http://gerrit.openafs.org/751 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 7833e472b9585ee1a7085ca704e642a73ca969a5 Author: Simon Wilkinson Date: Wed Oct 28 11:12:18 2009 +0000 Make afsd.pod reflect reality 9d396c4916fdac64fcface30e6637ca6e2911203 (from 2005) introduced autotuning for afsd, and changed some of the defaults which aren't autotuned. Update the afsd man page to reflect the autotuning, and the new defaults. Change-Id: Iea2035743cb45cca1c249bc2e838405039ad7d3a Reviewed-on: http://gerrit.openafs.org/744 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 53fc41a856da4a23fa603bd5a274d819e7a3b54e Author: Simon Wilkinson Date: Wed Oct 28 18:24:33 2009 +0000 Move PMTU header block to top of file 1206e7538be86f073b21cd289266286b60a95d0a added linux/errqueue.h to rx_user.c, but added the include in the middle of a function - which means that the new structure is out of scope for the rest of the file, which breaks the build on Linux. Put the header include at the start with all of its other friends. Cc: Alf Wachsmann Change-Id: Id932ff63b59e6cd62eda3df4f01e4eef354736ca Reviewed-on: http://gerrit.openafs.org/748 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 21efa6394ebf0b1eea440b74aef9f62160d5f851 Author: Marc Dionne Date: Mon Oct 26 18:23:00 2009 -0400 afs_buffer.c: fix uninitialized variable warning Squash a warning about lt being potentially used uninitialized. Change-Id: I41bfccfd1a0db925a4d728a217b154f45c28b112 Reviewed-on: http://gerrit.openafs.org/742 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bea4c4ea5d563bebe9f9c6289a1f25fd016a01a4 Author: Simon Wilkinson Date: Mon Oct 26 19:52:48 2009 +0000 Use fewer #ifdefs for dynamic vcaches When we're not in AFS_MAXVCOUNT_ENV, make afsd_dynamic_vcaches a static 0, which allows the removal of a scattering of #ifdef's in the middle of conditionals in afs_vcache.c, and generally improves the code browsing experience. Also, move the externs for this variable to afs.h, where they belong, and fix related formatting. Change-Id: I4d56ebae63fe1855ac80f8511b9fc76f7e5a326f Reviewed-on: http://gerrit.openafs.org/741 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d769b27694b4ab6d3fba23c6121238b311bd82d6 Author: Simon Wilkinson Date: Mon Oct 26 23:17:36 2009 +0000 Make cache bypass build again Recent commits had left cache bypass somewhat behind, make it build again. Change-Id: I500372f4584f4d0d90f6ea9f98a9ac3fb05f5185 Reviewed-on: http://gerrit.openafs.org/743 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 293e8c6a1048bf3c342134b5ca6f79d68023258b Author: Simon Wilkinson Date: Mon Oct 26 18:52:52 2009 +0000 Remove hardcoded maximum time When iterating across the buffer list, afs_newslot used a hardcoded maximum time to find the oldest. Instead of using this, just use the accesstime of the first unused buffer that we find as the oldest, and continue as normal. Change-Id: Ifeacb8a407901b46a23fbc838b1fca761108ebbb Reviewed-on: http://gerrit.openafs.org/738 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f97262c1d422e0a32289c75665d051914c8d69ad Author: Simon Wilkinson Date: Mon Oct 26 19:36:53 2009 +0000 Fix dynamic vcache / rxmaxmtu cmd id collision Both dynamic vcaches and rxmaxmtu had been committed as using the 35th command entry. Fix this according to the order they are in the command list (35 and 36, respectively). Tidy up the command list so it's easier to read, and remove the #ifdef notdef entry from it, as adding it back in would just cause chaos. Change-Id: I3fce403aa0ab01c42f0e1a48ae401503b0e21c24 Reviewed-on: http://gerrit.openafs.org/740 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b21b209f1cb2bafe916543c1ac8f232d6fc84847 Author: Simon Wilkinson Date: Mon Oct 26 17:06:20 2009 +0000 Fix locking in afs_buffer.c Back in 2002, 0eb68f307aac84472a13523a0ce8b7a865f01ac7 was committed to fix locking problems in dir/buffer.c. Sadly, similar changes were never made to afs/afs_buffer.c, so the same problems remain in the cache manager. The issue here is with two processes racing in afs_newslot. Calls to afs_newslot protect buffers with a zero reference count using afs_bufferLock. If we release afs_bufferLock, before we increase the reference count of the vcache, then we can end up with newslot picking the same buffer for two different purposes. The GLOCK actually protects us from the worst of this, but this fix is necessary both for correctness, and for symmetry with the file server buffer code. Change-Id: I7f1c7d6571559c5f1784926c39d4889b77677231 Reviewed-on: http://gerrit.openafs.org/737 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ba93d8f9f1379e3342460273234f964a39e1caf9 Author: Simon Wilkinson Date: Mon Oct 26 19:46:09 2009 +0000 Remove pininodes The pininodes option has been commented out of afsd since the original OpenAFS commit. Enabling it now would cause chaos, due to the way that cmd orders its arguments. Just remove the sections of code to avoid this danger. Change-Id: I9e9944d4470fd21d2ec9e36e17771b499d7c8e0b Reviewed-on: http://gerrit.openafs.org/739 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit dbe3b7b8eeb4a010f82248befc6167b3b5ed9606 Author: Andrew Deason Date: Mon Oct 26 14:04:48 2009 -0500 Dec old special inodes in inode convertROtoRW The convertROtoRW code for the inode fileserver makes copies of the volume's special inodes, but leaves the old (RO) inodes around. If the RO is created again, this will result in duplicate special inodes for the same volume, which freaks out the salvager (and possibly other things). So IH_DEC the old RO special inodes after converting, so they go away. Change-Id: Ifefa2cb69c5b2960b81dbee9d54e5ea8401b240e Reviewed-on: http://gerrit.openafs.org/735 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c95ace2c5963076deaf5f5c3a9856978f19ea0c4 Author: matt@linuxbox.com Date: Mon Aug 3 12:36:25 2009 -0400 viced (non atomic) refcount/more-threads Replace host-hold bitmap with reference counting, phase 1, not atomic. Increase viced MAX_THREADS. NOTE: This code has been tested on Centos 5.3 x86_64, on VMWare, 2 physical, 2 logical CPUs. LICENSE BSD Change-Id: Id62dcc786619dfd99e1a7b69a196bbaa0b45158c Change-Id: I8ee2ec645402f02fdba0920815409b56172d393b Reviewed-on: http://gerrit.openafs.org/268 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bf8355bd9aa7e7bd47ec5554030258fe43e2abdb Author: Jeffrey Altman Date: Mon Oct 26 07:13:00 2009 -0700 ubik_VL_GetAddrsU does not accept a VLCallBack parameter ubik_VL_GetAddrU accepts a pointer to a uniqifier and not a pointer to a VLCallBack structure. Remove an incorrect cast and provide the correct parameter in src/volser/vos.c. Change-Id: I4b12cf2d4c65f115fdef76f0a4306960b5cd0413 Reviewed-on: http://gerrit.openafs.org/733 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b90f4241285efccdf8be5f9ce3ae28c64fbccd38 Author: Andrew Deason Date: Fri Oct 23 15:02:12 2009 -0500 Avoid 'salvageserver -client -showlog' segfault Running salvageserver with the -client and -showlog options will currently segfault, since -client does not open logFile, and -showlog will attempt to rewind logFile on exit. Fix this by not allowing -client and -showlog together (since it won't work anyway, as -showlog tries to read SalvageLog), and by making showlog() check logFile for NULL-ness. Change-Id: I30f43ef1696f1e7e8873b9e1cc3867b4e06d1980 Reviewed-on: http://gerrit.openafs.org/734 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 8edafd92c0ec5b31aff7f86b73f954a04d0f17d4 Author: Jeffrey Altman Date: Mon Aug 17 12:23:57 2009 -0400 Updates to Jake's RTT based server ranking (Gerrit 317) Remove check on powerStateSuspend in cm_Daemon() Update the server Reference lists if the ranking changes. Change-Id: Id290e0f98c616a12f4f8b1746dca58ad7a0f06ce Reviewed-on: http://gerrit.openafs.org/729 Tested-by: Jeffrey Altman Reviewed-by: Jacob Thebault-Spieker Reviewed-by: Jeffrey Altman commit d22c05e6799649a1b5c06b0396e78b0520b3e4f6 Author: Jacob Thebault-Spieker Date: Wed Aug 12 01:32:06 2009 -0400 Adds cm_RankUpServers() and cm_RankServer() This adds the functions cm_RankUpServers() and cm_RankServer() to the Windows cache manager. cm_RankUpServers() steps through the list of servers, and calls cm_RankServer(), which in turn re-ranks the servers that are currently up based on rx peer statistics as exposed by rx_GetLocalPeers(). cm_RankUpServers() is called every 10 minutes by the cache manager daemon, so as to allow re-ranking of the servers. Also added is the struct server->adminRank data structure, to allow for the modification of the rank that the admin has set, without but basing this modification on the admin-set rank. Change-Id: I118b885e179e4f84901dd9a3180ce821f194feb8 Reviewed-on: http://gerrit.openafs.org/317 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 4a006f167bf6fe550eac9c96c6fce1f538760709 Author: Simon Wilkinson Date: Mon Oct 26 12:49:11 2009 +0000 Clean up console message Clean up the 'all buffers locked' console message so that it's clear that it comes from AFS, and so it has a trailing newline. From a bug report by Rainer Toebbicke to openafs-info Change-Id: I3f69e57e37a91ae3e6e8822ccfe72dddc06b4359 Reviewed-on: http://gerrit.openafs.org/732 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b8e4c573a5da18ecd80578a1061594891528ffc9 Author: Simon Wilkinson Date: Fri Oct 23 16:34:33 2009 +0100 Don't return AOP_WRITEPAGE_ACTIVATE to write() When we're called from write(), we don't have the option of deferring the writing of a page by returning AOP_WRITEPAGE_ACTIVATE. Instead, write() simply sees this as the output of 0x8000 bytes of data. So, whilst we can mark a vcache as being output, we can't defer the processing of one which is already being written (by, for example, an earlier writepage()). This problem only affects files which are have mmap() and write() called in quick succession, but it does break the fsx utility. Change-Id: I750a186de38da9873665a862f5b584a78e6979ad Reviewed-on: http://gerrit.openafs.org/725 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 70c8deab1694e2cd200f4ff7a81f5f3f028a4c19 Author: Simon Wilkinson Date: Sat Oct 24 10:54:32 2009 +0100 Use user credentials for Linux writepage() We have no control over the context in which the kernel calls our writepage routine. It may be from the process which original wrote the page, from any other process on the system which is writing and goes over the dirty page threshold, or from the flush thread (pdflush / flush-afs). Therefore, we cannot use the credentials of the current process to perform the writeback. This is an issue both for afs_write (which, in our current MM model, may need to contact the fileserver to read missing chunks), and for DoPartialWrite (which needs to be able to store chunks when the local cache is getting full) This patch stores the credentials of the first process to open a file in the vcache structure. Whenever writepage() is used to writeback pages for this file, the cached credentials are used rather than those of the current context. Thanks to Marc Dionne for his work in testing and refining this patch. FIXES 125471 Change-Id: I2900f711150fd81b2b4839bbc2bf77623bde3b64 Reviewed-on: http://gerrit.openafs.org/724 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 207882ec4fa91a69d1ec0f25d23a409fd19898de Author: Derrick Brashear Date: Fri Oct 23 17:50:09 2009 -0400 windows 1.5.66 make 1.5.66 for windows Change-Id: I04902106c35eea2dccf6db594c496302cde3f15b Reviewed-on: http://gerrit.openafs.org/723 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 944580c19566fbf1d6d2717cf21f9afd3ef93c14 Author: Derrick Brashear Date: Fri Oct 23 17:35:37 2009 -0400 make 1.5.66 for unix push version changes for 1.5.66 Change-Id: I5302e9aa83b4aba0081130934f0d6df0786ce43c Reviewed-on: http://gerrit.openafs.org/722 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 11cdb701556fc0430445caaf3a4c6955683d9bd7 Author: Michael Meffie Date: Thu Oct 22 15:51:33 2009 -0400 volser transaction object race conditions Fix the transaction object races between VolMonitor and the volume operation procedures which can cause the volume server to crash. Add a per transaction object mutex to safely set the transaction call pointer and name. Fix VolMonitor to safely traverse the transaction list and to access the call pointer and last proc name while copying info to send to the vos client. Fix the sleep thread to safely access the last proc name. FIXES 125479 Change-Id: I59595b93522d111b6a771d3d93c246bfc2ce65de Reviewed-on: http://gerrit.openafs.org/718 Reviewed-by: Andrew Deason Tested-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bbcfbe1a04eda9e75b1643be88cf9d4842a8aa86 Author: Andrew Deason Date: Thu Oct 22 11:12:30 2009 -0500 Avoid prematurely destroying callback_rxcon Currently, h_GetHost_r and removeAddress_r can destroy the callback_rxcon of a host. Having a NULL callback_rxcon can cause segfaults in code that does not properly check if a host has been HOSTDELETED before trying to use it. Although such code is incorrect and should be fixed, we can still avoid a segfault in those situations by not destroying callback_rxcon until we destroy the host itself. This just prevents destroying callback_rxcon in h_GetHost_r and removeAddress_r, leaving it to h_TossStuff_r to destroy when it destroys the host. Change-Id: I6fd5cbb924053446689c576026f9044f78ba71be Reviewed-on: http://gerrit.openafs.org/717 Tested-by: Andrew Deason Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit ed8d83e0f6b9825503643d1ee8398b2310946dd7 Author: Simon Wilkinson Date: Fri Oct 23 12:42:19 2009 +0100 Resolve error return issues in writepage The writepage_sync changes get error returns wrong in a couple of places. In particular, they return a 0 code from dopartialwrite in preference to the length return from page_writeback Change-Id: I34a848fed5f799aa6844e9ef0339321f91c7e59b Reviewed-on: http://gerrit.openafs.org/721 Reviewed-by: Marc Dionne Tested-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 5f720faab920a1007327de415ceaf187c16fdbe6 Author: Jeffrey Altman Date: Thu Oct 22 10:38:23 2009 -0400 Remove warning from all calls to afsconf_GetExtendedCellInfo Fix 'afsconf_GetExtendedCellInfo' : different types for formal and actual parameter 5 Change-Id: I922d653a88a9d0c04ed6dbd1c9c0b3fc90719337 Reviewed-on: http://gerrit.openafs.org/715 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ecfeb5365f7b7812529b8f6c269700f4ce30b45e Author: Jeffrey Altman Date: Fri Oct 23 00:16:01 2009 -0700 Windows: Notes for 1.5.66 ChangeLog description for 1.5.66 on Windows. Reviewed-on: http://gerrit.openafs.org/720 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit d0080431fab17c5e96f617ce78980adb3680d0f8 Author: Jeffrey Altman Date: Fri Oct 23 00:04:52 2009 -0700 Windows: Updates to Release Notes Add support for Windows 7 and Server 2008 R2. Improve text in a variety of areas. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/719 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit e16ce66634a85a870dae3323a2257953cfe571be Author: Simon Wilkinson Date: Tue Oct 20 12:38:53 2009 +0100 Refactor writepage_sync This change refactors writepage_sync into 4 functions - *) prepare_writeback() readies a vnode for writeback, and performs the anti-recursion check. *) dopartialwrite() intialises a request and performs the call to DoPartialWrite *) page_writeback() does the actual work of writing an AFS page into the disk cache page *) complete_writeback clears the writeback flag from a vnode There should be no change to the current behaviour of writepage_sync, these modifications are the first part of a fix to our writepage() behaviour. Reviewed-on: http://gerrit.openafs.org/712 Tested-by: Derrick Brashear Reviewed-by: Marc Dionne Reviewed-by: Derrick Brashear commit 234acbbb84534c5327bb69a2fcb7675dcd0d1198 Author: Jeffrey Altman Date: Thu Oct 22 10:27:41 2009 -0400 Windows: no longer use WinExec in afscreds WinExec is a compatibility interface for 16-bit applications. It is not compatible with Windows 7. Replace it with ShellExecuteEx. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/714 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 95cddea6da14d2dd58a2d5e5da775d26d647033f Author: Derrick Brashear Date: Wed Oct 21 14:42:23 2009 -0400 pthread pid casting in rx, we use pthread_self (which can return a pointer) as a pid; in order to not cause problems, cast it as we do elsewhere Reviewed-on: http://gerrit.openafs.org/703 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cd2d4ceadcb3c52ec8e1b7bfd078b32226bd0d9f Author: Jeffrey Altman Date: Thu Oct 22 10:10:12 2009 -0400 rx lwp include assert.h where AFS_NT40_ENV builds can see it Reviewed-on: http://gerrit.openafs.org/713 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 196b2a2cb35eb85fe599e5faa946c93073935928 Author: Jeffrey Altman Date: Thu Oct 22 08:57:04 2009 -0400 Windows: Update Control Panel to use ShellExecuteEx instead of WinExec WinExec is for 16-bit application compatibility. Starting with Windows 7 it cannot be used to execute a process that requires elevated privileges. ShellExecute[Ex] must be used instead. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/711 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit a3bad94d1726a13460dd2c6f55f8742efa9c34d6 Author: Derrick Brashear Date: Thu Oct 22 08:07:43 2009 -0400 remove spurious log in icl fstrace should not log sets to the kernel message log Reviewed-on: http://gerrit.openafs.org/710 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e83d382d208950029610ff04ec696b7ce6840a56 Author: Simon Wilkinson Date: Thu Oct 22 00:34:50 2009 +0100 Add -Wpointer-arith to warning and checking builds GCC doesn't catch issues with performing pointer arithmetic on (void *)s, unless the -Wpointer-arith warning flags is supplied. Enable it for warning and checking builds. Reviewed-on: http://gerrit.openafs.org/708 Tested-by: Marc Dionne Reviewed-by: Derrick Brashear commit 5f688ff4bd89aa0c73d96a51c0d5343a2ed2e843 Author: Derrick Brashear Date: Wed Oct 21 14:43:26 2009 -0400 rx don't exit exiting in library code is antisocial. if rx encounters an error which cannot be returned and would otherwise indicate a service thread has gone away, assert. Reviewed-on: http://gerrit.openafs.org/668 Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Tom Keiser commit 304f21cb7094e68224b22f8a91144f80207d7a3c Author: Simon Wilkinson Date: Thu Oct 22 00:31:10 2009 +0100 Fix fall out from removal of memset casts In places where we're doing pointer arithmetic, we must cast to (char *), because pointer arithmetic on a void * isn't permitted by the C standard. Sadly gcc lets us get away with it 'for convenience'. Reinstate the necessary casts. Reviewed-on: http://gerrit.openafs.org/707 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit a8a9c3c0f248d8ce0fbe7da701abb898adfe003c Author: Jeffrey Altman Date: Wed Oct 21 18:51:09 2009 -0400 Windows: Update MSI installer properties Reference useful web pages such as docs.openafs.org for help, www.openafs.org/windows.html for upgrade info, etc. Reviewed-on: http://gerrit.openafs.org/706 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 32b2f18628f4e7942e988111ba9903e9a2967754 Author: Jeffrey Altman Date: Wed Oct 21 18:41:59 2009 -0400 Windows: ports in the cache manager are stored in network byte order When assigning ports from SRV/AFSDB lookups, convert to network byte order when assigning them to cm_server objects. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/705 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 2a9263a451847f4f1fb4deff56ee68d73c70e5bc Author: Asanka Herath Date: Wed Oct 21 15:56:12 2009 -0400 Windows: Set the ARPINSTALLLOCATION property when installing The WiX based Windows Installer package for OpenAFS should set the ARPINSTALLLOCATION property when installing. This property contains the main installation directory for the product and is necessary for Windows Logo compliance. Reviewed-on: http://gerrit.openafs.org/704 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit b9eaf43bbe31ac20604e79b0fd4e35aa029a06bd Author: Simon Wilkinson Date: Wed Oct 21 17:34:30 2009 +0100 Don't cast the pointer past to memset memset() takes a void * as it's first argument. Don't explicitly cast what we're passing in to (char *), as this may mask other errors. Reviewed-on: http://gerrit.openafs.org/701 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5d5d18071608d9782a5d936f79215048af641410 Author: matt@linuxbox.com Date: Sun Oct 11 20:52:26 2009 -0400 Make typedefs of AFS_UCRED and AFS_PROC with renaming Make typedefs of AFS_UCRED and AFS_PROC, with a corresponding name change. The names afs_ucred_t and afs_proc_t are chosen since these appear to be the best available choices. The names cannot actually collide with anything which POSIX might later introduce. For UKERNEL, the preprocessor is used to redirect references. This seems not easily avoidable at present. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/645 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bf9c51a4e13b3e621b99866e9be53c8fe35a39fe Author: Andrew Deason Date: Tue Oct 20 12:43:42 2009 -0500 HPUX: Do not sigwait on critical signals On HPUX, it is possible for 'critical' signals such as SEGV, ABRT, etc to be delivered to the softsig thread when we sigwait(). The current code marks these as 'fatal' and just exit(0)s when they are received, preventing us from getting cores in the case of a SEGV, ABRT, etc. To work around this and keep behavior on other platforms the same, just do not wait on 'critical' signals on HPUX in the softsig thread. Reviewed-on: http://gerrit.openafs.org/693 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 4141bf4084b3f473a8a756b42556c6273cd7c9bd Author: Jeffrey Altman Date: Wed Oct 21 09:14:51 2009 -0400 Windows: Add registry entries for rx_SetMinPeerTimeout, rx_SetMaxRecvWindow, rx_SetMaxSendWindow Permit the new rx settings to be configured via the registry and set at startup. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/700 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit c4263054a0c3101199d84527f36e18e2743169c4 Author: Jeffrey Altman Date: Wed Oct 21 09:13:22 2009 -0400 Add rx_SetMinPeerTimeout and rx_GetMinPeerTimeout Permit the minimum peer timeout value to be adjusted at runtime. The default remains 350ms. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/699 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 54d9c6cb34af3da75831b4b8c68cb40475eee1ea Author: Simon Wilkinson Date: Tue Oct 20 15:30:33 2009 +0100 Use real names for page lock operations Call a spade a spade. Don't use macros to rename lock_page as LockPage, and unlock_page as UnlockPage. Instead use the same names as the kernel, which makes it a lot easier for people familiar with kernel code to read ours. Reviewed-on: http://gerrit.openafs.org/692 Reviewed-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 040712a744dd5e021d20987c2e2a98ac0f129b15 Author: Jeffrey Altman Date: Wed Oct 14 23:43:46 2009 -0400 Windows: Modify afscreds.exe and afs_config.exe to be UAC compatible afscreds.exe: 1. disable the drive mapping and advanced tabs. 2. on exit, remove the option to stop the service. afs_config.exe: 1. disable the drive mapping tab Removing this functionality by default will address some of the problems while permitting users that wish to continue using these tools to do so. The drive mapping tab can be re-enabled setting the registry value to be non-zero: {HKCU,HKLM}\Software\OpenAFS\Client DWORD "ShowMountTab" LICENSE MIT Reviewed-on: http://gerrit.openafs.org/663 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit ee7399fa3795652c3d903e9af2baa9ba0174ca03 Author: Jeffrey Altman Date: Wed Oct 21 09:02:04 2009 -0400 Windows: Do not permit infinite attempts to obtain a pioctl file handle The recent change to detect sharing violations and initiate retries permits infinite attempts. Change this to a limit of 100 attempts and increase the sleep period between attempts from 1ms to 100ms. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/697 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 2e9dc9ee20181db0e3c6dbee0b51b0f8de5d52ec Author: Jeffrey Altman Date: Wed Oct 21 09:07:47 2009 -0400 Windows: digital signatures are required for resource dlls Windows 7 logo requirements state that all dlls including resource only dlls be digitally signed. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/698 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 7673b2450c9e7449d8165a0be5bbd8e0c063dfd2 Author: Jeffrey Altman Date: Wed Oct 14 22:06:38 2009 -0400 Windows: Adjust error return values Do not return STATUS_TIMEOUT to the smb redirector, doing so results in an undesireable disconnect. Map RXKADNOAUTH to STATUS_CLOCK_SKEW as that is the most frequent cause of rx level authorization failures. Map CM_ERROR_UNKNOWN to access denied since there is no better error choice. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/661 Reviewed-by: Asanka Herath Tested-by: Asanka Herath Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 310cec9933d1ff3a74bcbe716dba5ade9cc28d15 Author: Derrick Brashear Date: Tue Sep 29 05:34:30 2009 -0400 rx window size increase window size was previously pushed to 64; push to 128. as this increases memory use, anything further should be arguably tied to rx-using-program's resource allocation preferences, e.g. fileserver -LL should be willing to up this Reviewed-on: http://gerrit.openafs.org/549 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit b8e3de897a05ac07ea8cff5774d982ce6ad605b2 Author: Derrick Brashear Date: Tue Oct 20 15:03:09 2009 -0400 afscp warnings cleanup make the copy of afscp in src/tests compile with fewer warnings (and provide needed prototype for RXAFSCB_ExecuteRequest) Reviewed-on: http://gerrit.openafs.org/694 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit cc112e7a59d441d28a1d195cb48f23887df51929 Author: Jeffrey Altman Date: Tue Oct 20 16:16:47 2009 -0400 prevent rx peer timeout from reaching 0.0 seconds The rx peer timeout is computed from the round trip time calculation. It traditionally has had a lowerbound of 350ms. The computation in rxi_ComputeRoundTripTime() was incorrect and instead used 350ms as an upperbound. rxi_ComputeRoundTripTime() had a second problem wherein if the actually RTT is shorter than the resolution of the clock then the RTT would quickly approach 0.0 seconds. Enforce a lowerbound of 1ms if the RTT for a given packet appears to be 0.0 seconds. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/696 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e7e057346fa456cb27c54112a4dba311bcaf9aaf Author: Jeffrey Altman Date: Tue Oct 20 15:08:51 2009 -0400 Rx warning removal This patch set removes many but not all of the warnings in the rx library. - use AFS_PTR_FMT in dpf debugging output - fix many signed vs unsigned warnings - on Windows, the first parameter to select() is ignored. Passing an osi_socket produces an unnecessary warning. - In rx_SlowReadPacket and rx_SlowWritePacket, use 'r' the unsigned value for internal computation and 'resid' for holding the original value. This avoids many signed vs unsigned warnings. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/695 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c188acf396487be4b902549c215e3da5cda615ce Author: Jeffrey Altman Date: Tue Oct 20 12:32:22 2009 -0400 Windows: AFS_PTR_FMT is just 'p' The printf format specification for a pointer of any size is just 'p'. The 'I' is only to be used for [duox]. Reviewed-on: http://gerrit.openafs.org/690 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 840e4d2123e1e94adfc27ae0b286a11d472cf0fc Author: Andrew Deason Date: Sun Oct 18 22:48:56 2009 -0500 Avoid 'static __inline' on HPUX 'static __inline' functions on HPUX can segfault the /opt/ansic compiler (unless we lose debugging symbols). So, just use 'static' for those functions on HPUX. Also revert a9368a6c3dfe4435ec2ae63fff4a3325104ed9f7, so we get a static inline function on other platforms. Reviewed-on: http://gerrit.openafs.org/691 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit a26f10a01a39747cd275baa326adf8415c5648e4 Author: Simon Wilkinson Date: Tue Oct 20 13:38:08 2009 +0100 Remove pageoff macro The pageoff macro is now unused. Remove it. Reviewed-on: http://gerrit.openafs.org/689 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit bd011aeee7f5dad5c61fd81a90b296c46a0b9058 Author: Jeffrey Altman Date: Mon Oct 19 18:43:44 2009 -0400 Add server prefix to bumon.xg; avoid rx_call * vs rx_connection * warning When compiling src/bubasics/bumon.ss.c a warning would be produced due to an rx_call* being passed into BC_Print which in its client form requires an rx_connection*. The server implementation and client stub each were called BC_Print because there was no server prefix specified in bumon.xg. Add prefix 'S' and update bucoord/server.c to match. Reviewed-on: http://gerrit.openafs.org/686 Reviewed-by: Simon Wilkinson Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3eec9fa7700de5d20a5c7eec8fc02f87ead1f342 Author: Simon Wilkinson Date: Mon Oct 19 23:56:12 2009 +0100 Return both error codes for rxfs_fetchInit The FetchStore refactoring was causing the result from rx_EndCall to be discarded. This change will cause that to be returned to the caller if rx_Error() returns 0 Reviewed-on: http://gerrit.openafs.org/687 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 6f2ce4cdc216ad5a3e8ed09a011a5f0681f098b4 Author: Simon Wilkinson Date: Fri Oct 16 16:39:24 2009 +0100 Always unlock pages when returning from writepage Writepage has a return path which returns an error with a locked page. However, all returns that are not AOP_WRITEPAGE_ACTIVATE must unlock their pages - using this codepath would leave a stray page lock, which would eventually hang the machine. The logic behind the -EIO return was also incorrect. In the Linux page cache model, truncates simply reduce the size recorded in the inode. If there are pages pending writeback then they may still have writepage() called upon them - it's up to the writepage routine to discard the write request (rather than returning an error) Reviewed-on: http://gerrit.openafs.org/685 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit ebf6516db2f1105e5ca8172f6d64038c6acc60bd Author: Andrew Deason Date: Thu Oct 15 13:15:44 2009 -0500 Fix a couple more unlink()s in vol-salvage.c There are a couple more unlink() calls in vol-salvage.c that were using relative paths. Fix them to use absolute paths and to log a warning if the unlink() fails. Reviewed-on: http://gerrit.openafs.org/684 Tested-by: Andrew Deason Reviewed-by: Derrick Brashear commit 6b0e4039c65262e68481ff43bc0cce531c5b39eb Author: Asanka Herath Date: Mon Oct 19 17:12:32 2009 -0400 Windows: Add a token status icon to the NIM plug-in The Network Identity Manager plug-in for OpenAFS replaces afscreds.exe for token management. However, unlike afscreds.exe, the plug-in did not indicate the status of AFS tokens using an icon in the notification area. This patch adds a token status icon to the plug-in so that while the plug-in is used, a familiar padlock icon in the notification area will indicate the status of tokens as well as the OpenAFS service. There are four possible states indicated by the icons: - No tokens: indicated by a padlock with a bright red 'X' beside it. - At least one valid token: indicated by a normal padlock. - Service is not running: indicated by a grayed out padlock with a black square beside it. - Service error: indicated by a padlock broken in half. The 'Service error' state means that the OpenAFS client service is technically running (as reported by Windows), but is not responding to requests. In addition to the icon, hovering the mouse cursor over the icon will show details about the current state (such as the list of cells for which valid tokens exist) and the version of OpenAFS running on the machine. Reviewed-on: http://gerrit.openafs.org/683 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit edbef134b7ee2abbd8e2b9639991e5906f3b8fb0 Author: Claudio Bisegni Date: Mon Oct 19 17:34:09 2009 +0200 AFSPreference Pane Mounts View refresh issue Resolved the bug that prevented to show the link description after it was added. Now the table is refreshed at any operation(add/remove). Reviewed-on: http://gerrit.openafs.org/682 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e82f3b210e0e49fb9d9531565f634ed9d49426a5 Author: Claudio Bisegni Date: Sun Oct 18 20:39:21 2009 +0200 OpenAFS Preference Pane 64bit and Symbolic Link features implemented. Now the OpenAFS preference pane is compiled with 32 and 64 bit snowleopard support, so the preference windows is no more restarted in 32 bit mode. The tab for symbolic link creation has been implemented. Now the user can create and delete link. For create a link both name and destination path must be set. AFSBackgrounder has been updated to manager in a separate thread the link creation and destroy operation, according to the vaule of checkbox "Enable Symbolic Link" in "Mounts" tab. Reviewed-on: http://gerrit.openafs.org/677 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 67395a7b6a3c83d3f15fae75cf78db9f60730bbc Author: Andrew Deason Date: Sun Oct 18 21:05:58 2009 -0500 Prototype encode_krb5_enc_tkt_part for aklog Prototype encode_krb5_enc_tkt_part in aklog_main.c, since it is a private interface so we don't get a prototype from the krb5 headers. Reviewed-on: http://gerrit.openafs.org/680 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit bb7f31bc3cd85557ddaf89e801572e0d933702af Author: Andrew Deason Date: Sun Oct 18 22:20:59 2009 -0500 Fix format warnings in tviced/state_analyzer.c state_analyzer.c assumes subtracting two char*s will result in an unsigned int, which can cause warnings. Lacking a portable format specifier, just use %ld and cast to long. Reviewed-on: http://gerrit.openafs.org/681 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 9818e3dce9461f08f4aafbfd99be5a48ac098464 Author: Andrew Deason Date: Sun Oct 18 20:46:27 2009 -0500 Fix a couple of size_t warnings fsprobe/fsprobe.c and kauth/ka-forwarder.c were trying to print size_t's without using AFS_SIZET_FMT. Fix that. Reviewed-on: http://gerrit.openafs.org/678 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3dbee6f66d3932d1e2e9141220c0e9f6623a9b94 Author: Andrew Deason Date: Sun Oct 18 20:47:43 2009 -0500 Prototype ka_log Prototype ka_log in kauth/kalog.h to prevent warnings. While we're at it, only prototype kalog_log and kalog_Init when they actually get implemented. Reviewed-on: http://gerrit.openafs.org/679 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 9bbe16d33097b387c5f855de0ca7ba4c67631e67 Author: Simon Wilkinson Date: Sun Oct 18 12:07:37 2009 +0100 Fix warnings in tviced Prototype hpr_Initialize and hpr_End to remove warnings in the tviced build. Reviewed-on: http://gerrit.openafs.org/675 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c9dc69afae4c359058f1f524a388f4cd059fdf10 Author: Andrew Deason Date: Fri Oct 16 14:30:34 2009 -0500 Log error messages in volser i/o errors Currently, in various places in src/volser/, we log/print an error message when some disk i/o error occurs, but we don't log what error was returned. Log that little bit more info to make debugging easier in some cases. Reviewed-on: http://gerrit.openafs.org/671 Tested-by: Andrew Deason Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c4f190ca605597fd31972192c65363117863e262 Author: Simon Wilkinson Date: Fri Oct 16 23:15:52 2009 +0100 More warning fixes for kauth Resolve more minor warnings from the kauth directory. *) kaux_read takes an unsigned for the number of failures *) The COUNT_REQ macro generates an unused variable (this_op) *) kas is missing some headers *) Add some more prototypes to kauth_internal.h *) Add the standard boilerplate to kauth_internal.h *) recvfrom takes a socklen_t * as its 6th argument This make kaprocs.c, kaauxdb.c, kas.c, klog.c, and ka-forwarder.c warning clean. Mark them as such. Reviewed-on: http://gerrit.openafs.org/673 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3064879c8d69ca9541c622e9f3f90e7c1e35c26c Author: Simon Wilkinson Date: Fri Oct 16 22:45:50 2009 +0100 Update warning management This change tidies up after the recent slew of warning reduction. It updates README.WARNINGS to reflect the current state of the tree, disables warnings for a couple of files that are now warning clean, and ensures that the libuafs and libafsrpc Makefiles match the state of the rest of the tree in terms of which warnings are enabled. Reviewed-on: http://gerrit.openafs.org/672 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7de8be52f5720f865fdfbf59772df1f2ab1bd8e5 Author: Simon Wilkinson Date: Sun Oct 18 12:44:56 2009 +0100 Use ranlib -c for Mac OS X Leopard Building with --enable-demand-attach-fs requires that ranlib -c be used on Leopard (it is already the default for Tiger) Reviewed-on: http://gerrit.openafs.org/676 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 20a5b58e23ceab1c6be60e173e631ee8fb6834a5 Author: Simon Wilkinson Date: Sat Oct 17 08:49:03 2009 +0100 afs_Conn must be called within the analyze loop afs_Analyze calls afs_PutConn, so each pass through the afs_Analyze loop must call afs_Conn to get a new connection handle. afs_CacheStoreVCache (part of the fetchstore refactoring) wasn't doing this, and so producing garbage data upon retries. Reviewed-on: http://gerrit.openafs.org/674 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f3d5b94f2e2dfcdb5c626a42b6be4f1e412f4a33 Author: Jeffrey Altman Date: Fri Oct 16 15:28:04 2009 -0400 Windows: Always compute time remaining in cm_Analyze In cm_Analyze, the time remaining for processing the request is used to determine if a retry should requested upon return. If the request's CM_REQ_NORETRY flag is set, cm_Analyze can still permit a retry if a new rx connection is to be forced. This cannot happen if the time remaining is not calculated when the CM_REQ_NORETRY flag is set. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/670 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 2285341b5f009329d84f1ccdb6bcadcb6a507047 Author: Jeffrey Altman Date: Fri Oct 16 15:31:02 2009 -0400 Windows: mark volume status online during cm_MergeStatus During cm_MergeStatus, if the volume status is not vl_online mark it vl_online. The volume must be online because an AFSFetchStatus was just processed. This change reduces the amount of work that must be performed by the daemon thread's volume status check. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/669 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 3abc87a5a94f0d5eaca702c7bd66fbe35ce7b896 Author: Marc Dionne Date: Thu Oct 8 21:53:03 2009 -0400 Linux: kmem_cache_create fix and cleanup Fix the kmem_cache constructor function to match the current expected prototype, and cleanup related code. This has been wrong for a while, but since we were just passing extra parameters the only effect was to generate a warning. - Add a new configure test to detect the new constructor function signature - Define the older versions of the constructor in osi_compat.h, making them call the current version - Move a few compatibility #defines to osi_compat.h Reviewed-on: http://gerrit.openafs.org/657 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 508bcd69b5ad55bcadf26d9b748f175c7a33ce77 Author: Andrew Deason Date: Thu Oct 15 13:48:08 2009 -0400 Fix rxgen-generated warnings Prevent rxgen from generating code that produces warnings at compile time. * Add print_ifarg_with_cast(). Used within print_ifstat() to generate a member in an argument list complete with a type cast. The type cast may be a pointer to the type or the type depending on the value of the 'ptr_to' parameter. * When print_ifstat() generates the output for an opaque vector, cast the object to 'caddr_t' as xdr_opaque() accepts an argument of type 'caddr_t'. * When print_ifstat() generates the output for an opaque array, cast the object to 'char **' because xdr_bytes() accepts an argument of type 'char **'. * When print_ifstat() generates the output for any array that is not opaque or string, cast the object to 'caddr_t' because all of the xdr_XXX() functions other than xdr_opaque and xdr_bytes accept an argument of type 'caddr_t'. * When print_ifstat() generates the output for an alias, cast the output to a pointer to the specified type because xdr_ accepts an argument of type ' *'. This addresses warnings generated when compiling fsint/Kvice.xdr.c and fsint/afsint.xdr.c. Reviewed-on: http://gerrit.openafs.org/664 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit fe68604f113773c1ffcb6d83d4a2febc3e0e3ed8 Author: Derrick Brashear Date: Fri Oct 16 10:44:58 2009 -0400 exit less start cleanup of calls to exit scatter into library code. ugen_ callers handle error returns correctly; rmtsys already deals with errors; and rx_pthread can already deal with errors in the case that's fixed Reviewed-on: http://gerrit.openafs.org/667 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 50313a72a99ab312a796108d807aef0f6b4d2ca9 Author: Derrick Brashear Date: Thu Oct 15 19:21:54 2009 -0400 snowleopard 64 bit warning death make all errors from warnings when compiling on snowleopard die as a note, the ukernel pid, and pthread self as id changes, probably should be revisited, but for now i have changed nothing. it should be a separate change. Reviewed-on: http://gerrit.openafs.org/666 Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 58628eb745acdf4b1b7e9f5ab828e4ca0fa18b81 Author: Andrew Deason Date: Sun Oct 11 21:55:05 2009 -0500 Detect and use %zu for size_t when available Commit db949b7fade69d7eb1e38ad85d5b822c443306cb was incorrect and generated warnings on many platforms; we cannot determine the correct format string for a size_t at compile-time. Instead use the %z length modifier when we can detect that it is safe to use. Otherwise, fall back to just %lu on Unix, since it is reasonable to assume sizeof(size_t) == sizeof(unsigned long) on Unix. Reviewed-on: http://gerrit.openafs.org/647 Reviewed-by: Russ Allbery Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1fa650cee2d6cc708ee29a963ad3498a808bbde8 Author: Andrew Deason Date: Wed Oct 14 22:43:27 2009 -0500 Fix unitialized variable warning in cfghost.c Initialize cellentry. It does not appear to be possible to actually hit code that references an uninitialized cellentry, but the compiler can still complain. Reviewed-on: http://gerrit.openafs.org/665 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 862390a987f5ef4438079e7d1e961c7ddafb94ac Author: Jeffrey Altman Date: Tue Oct 13 23:36:26 2009 -0400 Windows: AFSVolSync creationDate based readonly volume versioning Implement readonly volume versioning based upon the .readonly volume creation date as reported in the AFSVolSync output parameter of every RXAFS RPC. Whenever a new callback is obtained for an object stored within a .readonly volume, the volume creation date is recorded in the cm_volume object along with the callback expiration time and a reference to the server that issued it. These values are used to determine if a callback is present when the cm_scache object's volume creation date matches the cm_volume object's volume creation date. If there is no match, the cm_scache object's individual callback information is used to determine whether a callback has been registered. This mechansism ensures that the whole-volume callback issued in response to a RXAFS_FetchStatus request against a .readonly volume can be applied to all objects that are cached from the same version of the .readonly volume instance. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/654 Tested-by: Jeffrey Altman Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Alistair Ferguson Reviewed-by: Jeffrey Altman commit 0468b18058332a21c52dd336eaea9768de271208 Author: Jeffrey Altman Date: Wed Oct 14 22:33:11 2009 -0400 Windows does not provide sys/wait.h sys/wait.h was added to butm/file_tm.c by patch set 789580d13591ff1aa53cfbf5fef4d46b0b65c805 (gerrit 635) Reviewed-on: http://gerrit.openafs.org/662 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 25882899879531d7bea20ab2d8c1e3dea0a7975b Author: Simon Wilkinson Date: Sat Oct 10 00:30:01 2009 +0100 Fix checked builds with gcc4.2 Recent change sets removed the 'ignore-all-warnings' mode from a number of files, in favour of using the implicit-function-declaration pragma. Sadly, that pragma isn't available in gcc 4.2. Revert the Makefile changes such that ignore all warnings is turned back on for the affected files, and note this in README.WARNINGS Reviewed-on: http://gerrit.openafs.org/639 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 41baf5c58fabc62145731be1d6c99c833c8ee003 Author: Derrick Brashear Date: Wed Oct 7 09:21:53 2009 -0400 add SRV record lookups to unix afsconf support suite also create new api call afsconf_LookupServer make afsconf_GetAfsdbInfo call it include T_SRV support Reviewed-on: http://gerrit.openafs.org/594 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 34c71e6b11e4e7fae40fa64a998a564feaa4a4b0 Author: Simon Wilkinson Date: Wed Oct 14 22:27:34 2009 +0100 Add fsint dependency to audit builds The 'audit' target requires that fsint is built first. Express this as a make dependency. Reviewed-on: http://gerrit.openafs.org/660 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 94ceae1220538dec8ba3400b1368b599fe28197d Author: Jeffrey Altman Date: Mon Oct 12 21:57:52 2009 -0400 Windows: refactor afs status cloning and clone when fs fetchdata bug detected When the file server fetchdata invalid length bug is detected the cache manager must fake the AFS Status info for the file as well as the AFSVolSync info. Otherwise, the merge status is incorrect. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/651 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit a394d74e4462a2a3e006ca161f22e35a9f44a77c Author: Jeffrey Altman Date: Wed Oct 14 09:26:27 2009 -0400 Revert "Windows: Readonly Volume Versioning for Windows Cache Manager" This reverts commit bb6e38a45b8b5061cd4c9613262fa015957fb8d8. Reviewed-on: http://gerrit.openafs.org/659 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 5a403db74efc732c3695fb60d4baa652656151a5 Author: Jeffrey Altman Date: Tue Oct 13 22:35:55 2009 -0400 Windows: fix build due to broken src/volser/NTMakefile Commit 82aa5b4e09ac8a550525efd0e357783a3b3aed88 incorrectly updated the src/volser/NTMakefile resulting in a broken build system. Reviewed-on: http://gerrit.openafs.org/658 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 958f54766452d3468e849570114fe1ff685bb0cc Author: Marc Dionne Date: Tue Oct 13 21:52:47 2009 -0400 Linux: Remove declaration of unused variable filp filp is unused after the recent rework of osi_file.c Reviewed-on: http://gerrit.openafs.org/656 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 789580d13591ff1aa53cfbf5fef4d46b0b65c805 Author: Andrew Deason Date: Fri Oct 9 10:17:43 2009 -0500 Fix warnings in butc, tbutc, and butm tbutc: - Ignore warnings for dump.c butc/dump.c: - butm_WriteFileData takes a char*, no need to cast buffer - volumeHeader_hton takes a struct volumeHeader*, though, need to cast buffer there - Ignore strict prototypes butc/recoverDb.c: - scanVolData takes a uint*, not an int* - Initialize nbytes to 0 - Remove warning inhibition butc/tcmain.c: - atocl takes an int*, not a uint* - Ignore implicit function declaration warnings butc/tcudbprocs.c: - Ignore implicit function declaration warnings (ubik stuff) butm/file_tm.c: - Include sys/wait.h for the waitpid() prototype Reviewed-on: http://gerrit.openafs.org/635 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 664e5aca1692b664cfacd906bd4e632baedf4a4b Author: Jeffrey Altman Date: Mon Oct 12 14:20:00 2009 -0400 Windows: If SecurityLevel is configured use it for vos.exe and pts.exe If the SecurityLevel registry value indicates that crypt should be the default, then always set -encrypt for vos.exe and pts.exe. Reviewed-on: http://gerrit.openafs.org/648 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 78d8b8c5c19b8d6873b2d62beaa60cc7acba1840 Author: Andrew Deason Date: Thu Sep 24 12:02:55 2009 -0500 Use f_bsize for ZFS afs_fsfragsize On ZFS, the disk space files can use up can be rounded up to the next recordsize boundary if they've been truncated. This can cause the Unix CM to mis-estimate cache usage, since it truncates files fairly often, and assumes the disk space used is the file length rounded up to the next f_frsize. Since the ZFS recordsize is available via the statvfs f_bsize, just round up to that instead. There is still some additional file metadata that takes up some additional space on disk, but according to ZFS people I've spoken to about this, it cannot be known in advance. In practice, the additional metadata storage doesn't appear to exceed about 10% of the data storage, which should be acceptable. FIXES 125365 Reviewed-on: http://gerrit.openafs.org/650 Reviewed-by: Derrick Brashear Tested-by: Andrew Deason commit 82aa5b4e09ac8a550525efd0e357783a3b3aed88 Author: Simon Wilkinson Date: Fri Oct 9 21:17:16 2009 +0100 Add public protoypes for volser Add a new public header file volser_prototypes.h, which contains prototypes for those volser functions that are used by the rest of the tree, and link it into the Unix and Windows build systems. Rename the current volser_prototypes.h volser_internal.h, and update references to it. Make those places that should use the new public header use it, and re-enable warnings-as-errors as appropriate. Remove the warning free files from the list in README.WARNINGS Add butm_prototypes.h to butc/lwps.c, so we can enable warnings for that, too. Reviewed-on: http://gerrit.openafs.org/636 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9bd725692787534c5fb0d209b69be1de01c3cdf2 Author: Andrew Deason Date: Mon Oct 12 13:26:57 2009 -0500 Formatting typos in pts.pod Fix a couple of B<...> sequences pod2man yells at us about. Reviewed-on: http://gerrit.openafs.org/649 Tested-by: Russ Allbery Reviewed-by: Russ Allbery commit 633047c378b58b4bcd7e9dac046224955e868ea9 Author: Simon Wilkinson Date: Fri Oct 9 21:21:23 2009 +0100 Add afsio to gitignore Add the new afsio binary to the appropriate .gitignore file Reviewed-on: http://gerrit.openafs.org/637 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit bb6e38a45b8b5061cd4c9613262fa015957fb8d8 Author: Jeffrey Altman Date: Mon Oct 5 14:00:50 2009 -0400 Windows: Readonly Volume Versioning for Windows Cache Manager When the HKLM\SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters "ReadOnlyVolumeVersioning" DWORD registry value is non-zero, the volserver will be queried for each .readonly volume to obtain the lastUpdateTime. The lastUpdateTime will be used as a volume version identifier for each cm_scache_t object stored in the volume. With a known volume version, whenever a current status is obtained for any object within the .readonly volume, all the cached objects within that volume that have the same volume version can share the resulting callback registration. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/579 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit e026fcb2f03d792c80a81d99435a4ecdebba8fc9 Author: Jeffrey Altman Date: Sun Oct 11 18:06:25 2009 -0400 Windows Explorer Shell Extension: Remove OutputDebugString calls Remove all OutputDebugString calls from the explorer shell extension. OutputDebugString() requires acquiring system global locks. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/643 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 93fb21a8d090cea1ce25d0394bff921c44096575 Author: Jeffrey Altman Date: Mon Oct 12 08:28:54 2009 -0400 Windows: Correct lock error codes and log file server lockCount The error codes that should be returned when a lock request fails are: STATUS_LOCK_NOT_GRANTED for an explicit lock request STATUS_SHARING_VIOLATION when a CreateFile fails due to a previous lock Correct the service to ensure that these values are in fact returned. Also, add 'fsLockCount' field to cm_scache_t and dump its value as part of the "fs memdump" output. This permits some ability to identify what the file server thinks the lock count is. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/646 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 917a860e818d5cdda82add0d4d50b594820816f2 Author: Jeffrey Altman Date: Mon Oct 5 14:34:59 2009 -0400 Improve accuracy of Rx RTT calculation by skipping retransmitted packets Rx RTT calculations are based on Van Jacobson's work using constants that make computations fast but are not necessarily the best for modeling Rx protocol exchanges. This patch does not alter the constants but does improve the comments to show that the math is correct. Phil Karn in 1987 demonstrated that Van Jacobson's algorithms produced inaccurate results when the RTT computed from an acknowledgement of a retransmitted packet were included. The resulting RTT would either be too small causing the system to retransmit too many packets or too long resulting in too few being sent. This patch follows Phil Karn's advice which was also adopted as mandatory for TCP in RFC2988. Retransmitted packets and delayed acks are skipped and the retransmit time is backed off (up to a maximum of 3 seconds) until a successful acknowlegement is received for an initially transmitted packet. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/580 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 76ae0f51892a703d7bd4aea5fdcf60c586e4a440 Author: matt@linuxbox.com Date: Sat Oct 10 09:09:53 2009 -0400 Use AFS_PROC consistently Make consistent use of AFS_PROC in portable and mixed files, adding the define for platforms which lacked it. This completes a change that has been ongoing for several years. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/642 Reviewed-by: Simon Wilkinson Tested-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit d705e26eac5c4327ef1499cd59228e123f03971f Author: Simon Wilkinson Date: Sat Oct 10 00:46:08 2009 +0100 Revert "Linux: kmem_cache_create fix and cleanup" This reverts commit 6133d25397b8365d450c99b8bc147972f8600074. This patch breaks builds on RHEL5.3 - revert it until we can come up with a fix. Reviewed-on: http://gerrit.openafs.org/640 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit dc94d7da5f6767d0de4e11e8b41408394092a48b Author: Jeffrey Altman Date: Thu Oct 8 08:59:15 2009 -0400 Windows: use port when finding server by address Modify cm_FindServerByIP to search by port as well. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/607 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 8788462b65eca3e4b25f0e5bda44eac43a135d79 Author: Jeffrey Altman Date: Fri Oct 9 06:23:10 2009 -0400 Windows: Prevent fs fetchdata offset bug error from propagating to caller When the file server fetchdata offset bug is triggered and detected, not only do we have to behave as if 'length_found' is zero, but we also must ignore the RXGEN_CC_UNMARSHAL error that will be returned from rx_EndCall() due to the parsing error that occurred during the rx_Read32() call. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/634 Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 6133d25397b8365d450c99b8bc147972f8600074 Author: Marc Dionne Date: Thu Oct 8 21:53:03 2009 -0400 Linux: kmem_cache_create fix and cleanup Fix the kmem_cache constructor function to match the current expected prototype, and cleanup related code. This has been wrong for a while, but since we were just passing extra parameters the only effect was to generate a warning. - Add a new configure test to detect the new constructor function signature - Define the older versions of the constructor in osi_compat.h, making them call the current version - Move a few compatibility #defines to osi_compat.h - Clean up the call to kmem_cache_create by introducing an inline afs_kmem_cache_create in osi_compat.h Reviewed-on: http://gerrit.openafs.org/621 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6d59a0fcd04b7eaa917a84b98c7a932734e69b91 Author: Andrew Deason Date: Thu Oct 8 17:50:06 2009 -0500 Fix warning in vol/namei_ops.c Commit 906403c6d770026fd9da606ea468e47ee911f896 introduced a warning by making 'error' unused anywhere. Remove the declaration, as well. Reviewed-on: http://gerrit.openafs.org/620 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 94eae9ed26c9de6d30f2abf3b856412503359270 Author: Davor Ocelic Date: Thu Oct 8 23:03:06 2009 +0200 Update README with solved/pending docs tasks Reviewed-on: http://gerrit.openafs.org/618 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 04fa499ac9285f51fdbc2ff724c2a1bd7f0e5d58 Author: Davor Ocelic Date: Thu Oct 8 23:01:39 2009 +0200 Update backup suite manpages -- Add missing POD links (L<>) -- Verify all subcommands and options -- Format > 80 columns synopsis lines Reviewed-on: http://gerrit.openafs.org/617 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit a6e15c992e0d1d4a6934917acacc864160846eb0 Author: Davor Ocelic Date: Thu Oct 8 22:58:31 2009 +0200 Update fstrace suite manpages -- Add missing POD links (L<>) -- Verify all subcommands and options -- Format > 80 columns synopsis lines Reviewed-on: http://gerrit.openafs.org/616 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 923721f8396178902a001887497566b8a8d2efa4 Author: Davor Ocelic Date: Thu Oct 8 22:57:03 2009 +0200 Minimal left docs updates for vos suite Reviewed-on: http://gerrit.openafs.org/615 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit eb46f02e560653d8fa72b7ef453b87c8f1986575 Author: Andrew Deason Date: Thu Oct 8 13:15:00 2009 -0500 Typo in vos_remsite.pod A typo in c717fcd32cabbc9651b81ef3d0cea11d3a6ecd57 removed the = before the first head1 in vos_remsite.pod. Put it back. Reviewed-on: http://gerrit.openafs.org/612 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 065d9a65ba90505b6a1a2ad58b7e208028a17ced Author: Davor Ocelic Date: Thu Oct 8 19:32:36 2009 +0200 Add POD links (L<>) in pts.pod and symlink.pod Reviewed-on: http://gerrit.openafs.org/610 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c717fcd32cabbc9651b81ef3d0cea11d3a6ecd57 Author: Davor Ocelic Date: Thu Oct 8 19:31:00 2009 +0200 Update vos suite manpages Larger collection of all vos suite commands, including but not limited to: -- documented all commands / options, verified against both 1.4 and 1.5 tree (including the common -encrypt/-noresolve options) -- correct order, POD formatting and synopsis for all commands' options -- shorthand synopsis provided for all commands that missed it, with proper non-ambiguous command abbreviations of all options -- POD synopsis formatted to 80-columns in commands where it was running over -- for newer options, documented which OpenAFS version they became available -- proper manpage links using L<> in vos.pod Reviewed-on: http://gerrit.openafs.org/609 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit dde6f7d84087ad7a99bc7694f58521d6947c0665 Author: Davor Ocelic Date: Thu Oct 8 19:20:33 2009 +0200 Allow check-pod to work on specific files or dirs Reviewed-on: http://gerrit.openafs.org/608 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f387806bd43e9fa357b48a5c9381d1434a311f2e Author: Davor Ocelic Date: Thu Oct 8 19:33:26 2009 +0200 Update readme with solved and pending tasks Reviewed-on: http://gerrit.openafs.org/611 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 8314001bdb305204467adfb27b3dfa2e6890a3b1 Author: Andrew Deason Date: Wed Oct 7 15:57:04 2009 -0500 Reduce warnings in vos.c Squash a few miscellaneous that appear when building vos.c: -- CreateVolume should use util_GetUInt32 to parse vol ids, since they are now unsigned -- The m_uuid argument of print_addrs is altered, so do not declare it const -- Declare the confDir argument of ugen/vsu_ClientInit to be const, since it does not change, and vos.c passes a const confDir in MyBeforeProc -- Ignore implicit function declaration warnings and remove CFLAGS_NOERROR from the vos.c build, since the only remaining warning is an implicit function declaration Reviewed-on: http://gerrit.openafs.org/602 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c8482d0fb97b3cfe0445c14a605af8c2d00fb50d Author: Andrew Deason Date: Wed Oct 7 17:33:02 2009 -0500 Fix warnings in rxkad Some miscellaneous warnings throughout rxkad: rxkad/ticket5.c: - Explicitly cast ticket blob to unsigned char*, as some functions take a ticket as a char*, and some take it as an unsigned char* - in tkt_DecodeTicket5, make 'start' and 'end' be unsigned, since that is what their callers think they are - Ignore implicit function declaration warnings (for CRC functons) - Remove general warning inhibition rxkad/ticket.c: - in tkt_DecodeTicket, make 'start' and 'end' be unsigned, since that is what their callers think they are - Remove general warning inhibition rxkad/v5der.c: - In decode_enumerated, use der_get_unsigned instead of der_get_int, since we're decoding an unsigned integer. rxkad/rxkad_server.c: - The last two arguments to rxkad_DeriveXORInfo are char*s, so explicitly cast them to be so - Remove general warning inhibition rxkad/rxkad_common.c: - rxkad_stats_t has had a couple of spares transform into clientObjects/serverObjects; account for them and don't overrun the spares array Reviewed-on: http://gerrit.openafs.org/600 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 549002c906795f978eebf81c706995116a04a8ff Author: Andrew Deason Date: Wed Oct 7 16:42:42 2009 -0500 Remove warnings related to type-punning cmd/cmd.c: - Just make dummy be a struct cmd_item instead of casting rxdebug/rxdebug.c: - Access the stats packet through a union instead of casting and dereferencing util/uuid.c: - Access the seed through a union and an array instead of that incrementing-pointer approach Reviewed-on: http://gerrit.openafs.org/599 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 7197d35ef181bdbbe813ec7fd9c7e5173b801bdb Author: Jeffrey Altman Date: Thu Oct 8 08:35:09 2009 -0400 Windows: use xdr_alloc to allocate memory for Callback data structs xdr_alloc must be used instead of malloc in SRXAFSCB_GetLocalCell and SRXAFSCB_GetCacheConfig LICENSE MIT Reviewed-on: http://gerrit.openafs.org/606 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Reviewed-by: Derrick Brashear commit 7f7b4c9aad5deb5be62825ed6b88ca17093c0da6 Author: Marc Dionne Date: Thu Oct 8 08:12:28 2009 -0400 authclient.c: fix 64-bit specific warnings Commit 36be36e034141ded8fff5ff2edab3223b23c9fcf introduced some casts from an integer type to void *. This generates warnings on a 64-bit platform. Use uintptr_t casts to make the compiler happy. Reviewed-on: http://gerrit.openafs.org/605 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3ea144bde535f405f1cef101daa461e0bbbf0fc5 Author: Jeffrey Altman Date: Thu Oct 8 07:25:24 2009 -0400 Add missing variable to afsio Callback variable missing in WriteFile LICENSE BSD Reviewed-on: http://gerrit.openafs.org/604 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Reviewed-by: Hartmut Reuter Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e249aace420e20996fef8ace2b5051d5bbdcd809 Author: Jeffrey Altman Date: Tue Oct 6 14:46:09 2009 -0400 Permit DNS SRV record lookups to be used by the Windows afsconf_GetAfsdbInfo Permit DNS SRV record lookups to be used by the Windows afsconf_GetAfsdbInfo As per the published DNS SRV internet draft for the AFS3 protocol, DNS SRV records are to replace AFSDB records as the primary method of looking up AFS3 service location information. In order to make that happen for Windows: 1. afsconf_GetAfsdbInfo must be able to translate from internal service names to IANA assigned service names. 2. The Windows getAFSServer() API must accept IANA service and protocol parameters as well as the port number to use if AFSDB record fallback is required. 3. The Windows cache manager must pay attention to the port number stored within the sockaddr_in structure instead of using hard coded values based upon the server type. For afsconf_GetAfsdbInfo, in addition to searching for the requested IANA service, if that service is prserver or kaserver fallback to the vlserver record (if any). LICENSE MIT Reviewed-on: http://gerrit.openafs.org/593 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 38ffa111190548f2648f15dd7f1d3469c7f96e08 Author: Andrew Deason Date: Wed Oct 7 17:14:08 2009 -0500 xdrproc_t functions take a caddr_t, not caddr_t* Callers of xdrproc_t functions give the function a foo* as the second argument, not a foo**, and the xdrproc_t functions themselves expect this. Make the xdrproc_t typedef accurately reflect that, thereby ridding us of some warnings. Reviewed-on: http://gerrit.openafs.org/603 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 1d8118d3da8251ecbb18743fbaff6ebd3330f484 Author: Andrew Deason Date: Wed Oct 7 16:39:18 2009 -0500 Ignore libafsrpc warnings for shlibafsrpc also Some warnings were ignored in libafsrpc, but not in shlibafsrpc. Ignore them in both places. Reviewed-on: http://gerrit.openafs.org/601 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 8ef41263cfaff03cd5c33a0278d327596c68b730 Author: Andrew Deason Date: Wed Oct 7 17:07:52 2009 -0500 Fix warnings in lwp/process.c -- The EP/ep function does not return anything; declare the function pointer accordingly -- Explicitly cast &stackvar to char* to avoid a warning Reviewed-on: http://gerrit.openafs.org/598 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 36be36e034141ded8fff5ff2edab3223b23c9fcf Author: Andrew Deason Date: Wed Oct 7 17:48:52 2009 -0500 Fix warnings in kauth/authclient.c -- In ka_Authenticate, explicitly cast 'start' and 'end' to void*, since kawrap_ubik_Call takes all arguments as void*s -- Fix kawrap_ubik_Call to not be an old-style declaration -- Only ignore strict prototypes and implicit function declaration warnings Reviewed-on: http://gerrit.openafs.org/597 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f512597b0ad288081930c1e578f76a3d417aab23 Author: Andrew Deason Date: Wed Oct 7 17:16:30 2009 -0500 Remove a pointer->integer warning in fstrace.c Explicitly cast eparm to a long in afs_syscall when calling proc_afs_syscall, to avoid a warning. Reviewed-on: http://gerrit.openafs.org/596 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 72c2473724e1b0a8cdc4a9e3e7639d80e5ec1086 Author: Andrew Deason Date: Wed Oct 7 17:19:22 2009 -0500 Prototype strcasestr in afsmonitor.c If we HAVE_STRCASESTR, we lack the prototype for strcasestr in afsmonitor.c unless we def _GNU_SOURCE before including string.h on GNU systems. To avoid side-effects or pulling in extra stuff, just prototype strcasestr ourselves for the time being (if we have it) instead of def'ing _GNU_SOURCE. Reviewed-on: http://gerrit.openafs.org/595 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit db949b7fade69d7eb1e38ad85d5b822c443306cb Author: Andrew Deason Date: Wed Oct 7 14:52:02 2009 -0500 Correct and use AFS_SIZET_FMT On *nix, a size_t needs either %lu or %u to be interpolated in a string, depending on if we're on an ILP32 arch or not. Define AFS_SIZET_FMT accordingly, and actually use AFS_SIZET_FMT when we try to print a size_t. This removes numerous -Wformat warnings, at least when building on i386_linux26. Reviewed-on: http://gerrit.openafs.org/592 Reviewed-by: Matt Benjamin Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 6ef4627412ed554f3a3c0d7c2e1b9132b3a624d0 Author: Michael Meffie Date: Sat Jul 25 15:28:07 2009 -0400 Allow gnu-style long options New users are surprised when OpenAFS command options cannot be prefixed with two dashes, as is common with most modern tools. Permit an extra dash for common commands when more than one character is given. For example vos listvol --server foo.bar.com is equivalent to vos listvol -server foo.bar.com, but vos listvol --s foo.bar.com is an error. Reviewed-on: http://gerrit.openafs.org/216 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1793f454e4bb4f0eb5cbe9009ddb6bd48cc1cfd3 Author: Hartmut Reuter Date: Wed Oct 7 15:26:42 2009 +0200 pioctl with VIOC_FS_CMD removed This should ease the ingtegration for Windows. Instead RXAFS_FetchStatus is called. Reviewed-on: http://gerrit.openafs.org/590 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 811418887df505b9012a96802aa3dc3281b302e7 Author: Jeffrey Altman Date: Tue Oct 6 11:03:27 2009 -0400 Build afsio on Windows; remove many warnings With this commit afsio builds on Windows. It will not work until the VIOC_FS_CMD OSD extension is implemented in the Windows Cache Manager. Required changes: * Export ugen_ClientInit from libafsauthent.dll * Fix util_GetInt64 and util_GetUInt64 to return afs_int32 instead of afs_int64 since it is just returning success or error * Define VIOC_FS_CMD for Windows even though it isn't implemented LICENSE BSD Reviewed-on: http://gerrit.openafs.org/587 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 906403c6d770026fd9da606ea468e47ee911f896 Author: Andrew Deason Date: Wed Oct 7 12:14:11 2009 -0500 Make namei convertROtoRW'd volumes usable Right now, if you convertROtoRW a volume on namei, the converted volume appears to need a salvage before it is usable, and the header of the old (now empty) RO volume is kept around. Fix this: -- Set inUse = 0 on the converted volume, so the fileserver will be able to attach the volume when we give it back -- Unlink the RO header file, instead of trying to unlink the VI_VOLINFO file twice -- Log the actual error code (errno) in the error message for the last unlink Reviewed-on: http://gerrit.openafs.org/591 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e3d1eaf0ca6bfddede5aba1d1fc3f1e25cdb259e Author: Simon Wilkinson Date: Fri Oct 2 23:15:26 2009 +0100 Use page_offset() on Linux Since time began, Linux has provided page_offset() to turn a page index into an offset into the corresponding file. Make us use this everywhere we calculate a page offset, rather than doing our own maths. Reviewed-on: http://gerrit.openafs.org/581 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5d7084fc5e5cfb47a36ea2d26a74b0b5bbd7724a Author: Jeffrey Altman Date: Tue Oct 6 09:33:45 2009 -0400 Windows: fs listacl -cmd Add the new functionality from the Unix fs command to Windows. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/585 Tested-by: Jeffrey Altman Reviewed-by: Hartmut Reuter Reviewed-by: Jeffrey Altman commit e74f81955568f68ed2d5166f5dea3f20706bf4f3 Author: Jeffrey Altman Date: Tue Oct 6 09:48:57 2009 -0400 documentation for "fs listacl -cmd" LICENSE BSD Reviewed-on: http://gerrit.openafs.org/586 Reviewed-by: Matt Benjamin Reviewed-by: Hartmut Reuter Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit ea78369ab6e67dfc7d9fbc355efe333ec057a50d Author: Derrick Brashear Date: Mon Oct 5 12:45:26 2009 -0400 afs_FindService should handle iana portnames right now we compare against /etc/services, and a hardcoded array. but since there's no guarantee /etc/services will be useful, this can mean inconsistent behavior. hardcode the iana names in the table, and take the internal structure used private at the same time. LICENSE BSD Reviewed-on: http://gerrit.openafs.org/577 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e5cf14ba043f29b8b81440e6c32cf6f1cc91851c Author: Hartmut Reuter Date: Tue Oct 6 09:10:45 2009 +0200 New option '-cmd' for 'fs listacl' prints 'fs setacl' commands necessary to create the current ACLs. This is useful for backup scripts using TSM (or others) to save the ACLs into a file to allow for later restore. Reviewed-on: http://gerrit.openafs.org/556 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f7d601eefa0b98dd54720a4639ed746039d2675c Author: Simon Wilkinson Date: Fri Oct 2 23:43:46 2009 +0100 Use standard Linux paths for all headers As we're being built by the standard Linux module build system, we can use the normal #include convention from including kernel headers. Reviewed-on: http://gerrit.openafs.org/582 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f8cf2a44ab2e896b3c22c9a9e39cc9ade839545e Author: Claudio Bisegni Date: Mon Oct 5 13:42:27 2009 +0200 OSX Launchd Startup Manage with Preference Pane OpenAFS preference pane has been updated to manage the new launchd startup mode. Has been delete the custom startup and shutdown file now is user the /Library/OpenAFS/Tools/root.client/usr/vice/etc/afs.rc OpenAFS.postinstall has been modified to remove the old existing /Library/StartupItems/OpenAFS directory OpenAFS.pre_upgrade has been modified to shutdown daemon, if it is runnig, and remove the old preference pane to permit the one to be installed Reviewed-on: http://gerrit.openafs.org/578 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4e3d3d50496cc96799a84cf98873d6f68e9a8ca7 Author: Hartmut Reuter Date: Wed Sep 30 10:06:14 2009 +0200 afsio is a command to pipe data into or out of afs files afsio bypasses the cache manager to achieve higher throughput. However, it uses the cache manager to stat or create files over the AFS path. Besides 'apropos' and 'help' there are 3 subcommands: 'write' pipes data into a new or empty AFS file 'append' pipes data at the end of an existing AFS file 'read' pipes data out of an AFS file for 'write' there is an option '-md5' which calculates on the fly the md5 chscksum and prints it to stdout. (Useful when you create long time archives to keep it separately for later ...) for 'write' there is also an option '-synthesize ' to do just performance tests. It creates a file which contains at the begin of each 4 KB block the offset printed in ascii. for all subcommands exists a '-verbose' option which writes to stderr data rate and timing information. All three subcommands may also be used prefixed with 'fid' accepting then a Fid instead of an AFS path. With the 'fid' prefix also a '-cell' option is allowed. Reviewed-on: http://gerrit.openafs.org/555 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit db23268f682564000f2ac4f9f845d4fd261d4c90 Author: Marc Dionne Date: Thu Sep 17 16:57:52 2009 -0400 Linux: 2.6.32 - Adapt to writeback changes Adapt to the writeback changes in kernel 2.6.32 - Since we define our own backing_dev, it needs to be registered with the writeback code and attached to the super_block. Otherwise it might get ignored when writeback is needed. - Each backing_dev now gets its own kernel thread. The name of the thread is based on the registered name - the openafs one will appear as "flush-afs". Reviewed-on: http://gerrit.openafs.org/574 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit fa8766d220e37d5c11fc6ac72e3de40f5054cfff Author: Marc Dionne Date: Sun Oct 4 13:40:10 2009 -0400 rxfs_storePadd: return 0 on success On success, storePadd should return 0, not the number of bytes written by the last rx_Write call. In some cases this return value would leak all the way out to the close() system call, causing it to fail. Reviewed-on: http://gerrit.openafs.org/573 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 6d9ad2e4d0c5e87a8d2d02834134ca68122b8e33 Author: Simon Wilkinson Date: Fri Oct 2 14:34:50 2009 +0100 Refactor linux readpage support The readpage call on Linux was becoming horribly complex. This patch refactors it into three main components - a function which fills a locked page (without unlocking it), a function which triggers a cache bypass operation on a page, and a function which does conditional prefetch, based on the properties of the page that was just read. In addition, we abstract out the cache bypass code further, and provide static inline variants which are simply stubbed out when cache bypass is disabled. Reviewed-on: http://gerrit.openafs.org/569 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3e164335affa617137ebf280fe4c82a51c99894e Author: Simon Wilkinson Date: Fri Oct 2 13:43:01 2009 +0100 Rationalise some #ifdefs in the LINUX osi layer Introduce osi_compat.h, a place to hide compatibility #ifdefs. Make a start on using this by purging #ifdefs from osi_vnodeops, and pushing changes into inline compatibility functions. The general idea here is to create a single location where we can do our multiple version compatibility magic, and by doing so reduce the complexity of the rest of the code. The approach is that where the kernel introduces a new interface, we should switch to using it in the rest of the code, and add a compatibility function (in osi_compat.h) which implements the new interface in terms of the old one, suitably protected by #ifdefs. Where an interface changes signature, but not name, we should implement an afs_ version of the function which has the signature of the newest version, and within that call out to the real kernel versions, mapping between the different parameters as appropriate. Reviewed-on: http://gerrit.openafs.org/568 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 109927bf6f54b58b76ac48ba41c2012c74937fed Author: Simon Wilkinson Date: Fri Oct 2 11:51:52 2009 +0100 Remove pre-Linux 2.6 support This change removes support for kernels before Linux 2.6.0 from src/afs/LINUX. Older kernels should be supported by the src/afs/LINUX24 code. Reviewed-on: http://gerrit.openafs.org/567 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b7cc8bf2850c5650a9e47416af8bd488f9be9161 Author: Derrick Brashear Date: Thu Oct 1 16:09:17 2009 -0400 create LINUX24 directory shadow src/afs/LINUX into .../LINUX24, removing 2.6 code from it same for rx/LINUX cheat and simply modify MKAFS_OSTYPE in MakefileProto.LINUX.in Reviewed-on: http://gerrit.openafs.org/565 Reviewed-by: Matt Benjamin Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 2ea379b9f9a1df59327fb2b05b8d9af3bf6615af Author: Simon Wilkinson Date: Fri Oct 2 18:36:24 2009 +0100 There can be only one ... MD5 The cache manager has two implementations of md5 - one in afs_md5.c (used by afs_NewCell) and one in afs_util.c - used by Linux's MD5-inode code. Remove the one in afs_util.c in favour of using the common implementation in afs_md5.c Reviewed-on: http://gerrit.openafs.org/572 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 69290ffe9488ea5d5b3c3b9ccc875d1a0bab393c Author: Derrick Brashear Date: Thu Oct 1 04:34:09 2009 -0400 launchdaemon support for MacOS the changes needed to switch from a StartupItem to a LaunchDaemon for the MacOS OpenAFS client Reviewed-on: http://gerrit.openafs.org/564 Tested-by: Claudio Bisegni Tested-by: Derrick Brashear Reviewed-by: Claudio Bisegni Reviewed-by: Derrick Brashear commit d192fec670e6c5fce8910b40322da22f95fa5010 Author: Simon Wilkinson Date: Thu Oct 1 21:27:11 2009 +0100 Remove page past end of file optimisations The kernel checks itself for read() calls which attempt to fetch pages past the current file extents. Remove ours. Reviewed-on: http://gerrit.openafs.org/566 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 031f5eb528c94c1ad13fb1485db5cd40bc2877c2 Author: Andrew Deason Date: Wed Sep 30 16:50:07 2009 -0500 DAFS: Wait until preattach to service FSSYNC reqs Make FSYNC_sync wait until VInit == 2 before serving FSSYNC requests. This follows the existing similar behavior of waiting until after volume preattachment is completed before serving RPC requests in DAFS. This prevents FSSYNC clients from being denied requests simply due to a volume not having been preattached yet, at the small cost of delaying how soon we can serve FSSYNC requests. This does not alter the behavior of non-DAFS, which still only waits until VInit == 1, since volume attachment takes significantly longer than preattachment. Reviewed-on: http://gerrit.openafs.org/563 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d88c03492d1ea9a7533298977d8d6bec5e91ebcd Author: Andrew Deason Date: Wed Sep 30 16:42:46 2009 -0500 DAFS: Avoid volserver segfault in GetVolInfo It is possible for GetVolObject to return success, but result in a NULL fs_tv. In particular, when the fileserver responds with FSYNC_WRONG_PART or FSYNC_UNKNOWN_VOLID. It is possible, though difficult, for the fileserver to respond with FSYNC_UNKNOWN_VOLID if the requested volume hasn't been preattached on the fileserver yet. So, in GetVolInfo, also check fs_tv, so we don't try to dereference it later. Reviewed-on: http://gerrit.openafs.org/562 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b5c4dbf861a0be675e5dbe775059e3bf7628f127 Author: Jeffrey Altman Date: Wed Sep 30 21:43:45 2009 +0200 Windows version 1.5.65 Reviewed-on: http://gerrit.openafs.org/560 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 1937eadfdad6e7616f6db97d802c3b8c5000f5d6 Author: Derrick Brashear Date: Wed Sep 30 17:28:36 2009 -0400 openafs 1.5.65 make openafs 1.5.65 for unix Reviewed-on: http://gerrit.openafs.org/561 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 75dbaa82cd54bdbfc99a8c66a9d7a7327041863b Author: Jeffrey Altman Date: Wed Sep 30 21:42:16 2009 +0200 Windows: change log for 1.5.65 LICENSE: MIT Reviewed-on: http://gerrit.openafs.org/559 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d5b40d99a9e8284c1ce8784a6b8fcc7fb7453532 Author: Simon Wilkinson Date: Wed Sep 30 11:44:51 2009 +0200 Add configure test for pagevec_lru_add_file pagevec_lru_add_file isn't available on all Linux kernels. Fallback to using pagevec_lru_add where necessary. Reviewed-on: http://gerrit.openafs.org/558 Tested-by: Marc Dionne Reviewed-by: Marc Dionne Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 2f270a3e9206344464f1414cb04895090d93590d Author: Tom Keiser Date: Tue Sep 29 10:25:55 2009 -0400 make VOL_STATE_VLRU_ADD exclusive VLRU_Add_r() places a volume into VOL_STATE_VLRU_ADD before calling VLRU_Wait_r(), which drops VOL_LOCK while waiting for the required VLRU queue to quiesce. Thus, it is essential that state VOL_STATE_VLRU_ADD be marked exclusive so that another thread cannot mutate state until the VLRU generation add transaction completes. Reviewed-on: http://gerrit.openafs.org/554 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 06520711cbbb731da57e34cf955e525140bef33a Author: Jeffrey Altman Date: Tue Sep 29 14:29:55 2009 +0200 Windows: short circuit background volume checks for shutdown If the service is shutting down or the machine is entering a suspend state, short circuit the background volume checks to permit faster shutdown. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/552 Reviewed-by: Derrick Brashear Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit af9c9d905a08f28dc672dda6e5a6b9437f1650a8 Author: Simon Wilkinson Date: Wed Jul 15 00:02:31 2009 +0100 Add support for background page copies LICENSE BSD This patch adds support for backgrounding the page copies which are caused by a call to readpages() In theory, this should improve the throughput of the AFS kernel module as it permits processes to start work whilst data is still being read into the page cache for later pages. Reviewed-on: http://gerrit.openafs.org/537 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f75d84c404761a03ebf24406db12bfaff4bc3e74 Author: Simon Wilkinson Date: Tue Jul 14 23:55:18 2009 +0100 Add support for blocking readahead This patchset adds support for the readpages() system call, and enables readahead on Linux. At the moment each page read causes readpages to block, so the client won't see much benefit from readahead, beyond the reduction in call overhead. Reviewed-on: http://gerrit.openafs.org/536 Reviewed-by: Matt Benjamin Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f5c55d23a2a745e848c6e013c8b42cf3292c4691 Author: Simon Wilkinson Date: Tue Sep 29 12:26:55 2009 +0200 Demand attach warning fixes Fix a whole host of warnings in the demand attach code. Make a broken tvolser build stop the build, rather than carrying on regardless. Reviewed-on: http://gerrit.openafs.org/551 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 36700b51b34bbab515e947ed60104ada5ba6f827 Author: Simon Wilkinson Date: Tue Sep 29 10:25:53 2009 +0200 Don't use volatile when it makes no sense The demand attach code defines volume pointers as volatile in a number of places, despite the fact that the values in question aren't being shared between multiple threads. It then also passes these volatile pointers into functions which don't treat them as volatile (and even to some which assign them to registers). This patch simply removes the use of volatile in this situation. Reviewed-on: http://gerrit.openafs.org/550 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit ca8890245b44cc3abf311797ae62d2f0aaca5429 Author: Derrick Brashear Date: Tue Sep 29 10:26:23 2009 -0400 intptr fallout some kernels don't have e.g. uintptr_t; revert this hunk for now. also, autoconf as recent as what's in rhel5 has no macros. provide some. Reviewed-on: http://gerrit.openafs.org/553 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 88a037585d65e31e9d832bea89bb1cc1f107ab0f Author: Simon Wilkinson Date: Tue Jul 14 23:39:44 2009 +0100 Use readpage, not read for fastpath access Modify the fast path case so that it uses readpage(), rather than read() to access data in the cache. This removes a lot of the hidden, uncessary work that the kernel was doing behind the scenes, and takes advantage of the fact that we know a page read will always result in a page read against the backing cache. Reviewed-on: http://gerrit.openafs.org/535 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit c4bffd7efbcf27f7a8c9c0f81c4b79d3251a5d3a Author: Derrick Brashear Date: Tue Sep 29 05:25:46 2009 -0400 irix compile fixes fix compilation for irix (and warning for solaris) for icreate as well as more stdint.h fixes Reviewed-on: http://gerrit.openafs.org/548 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e0bbecf2693c2a7e3ec06fbb9335254f841c8e71 Author: Jeffrey Altman Date: Mon Sep 28 16:58:25 2009 +0200 Windows: Trace log smb_FindFID errors To assist with debugging, add consistent trace log messages for smb operations that generate an error because smb_FindFID failed. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/545 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit d9d3902894d1bde920feda7f5f1a798037b52cf8 Author: Claudio Bisegni Date: Tue Sep 29 09:57:52 2009 +0200 OS Preference pane clean for final version Has been removed from license file the reference to menucracker for hack NSMenuExtra, that is no more needed. Reviewed-on: http://gerrit.openafs.org/547 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 45e98a4455e1da7e79b70a4c42dccb07ab9102a6 Author: Jeffrey Altman Date: Mon Sep 28 16:22:31 2009 +0200 Windows: cm_GetBuffer does not need to contact file server when extended a file If cm_GetBuffer is being called in order to obtain a buffer to store data beyond the end of the existing file as known to the file server there is no reason to contact the file server. Instead use the cached status info in order to allocate a new buffer zero initialized. This logic avoids triggering the FetchData bug in all file servers older than 1.4.12 and 1.5.65 in which the file server returns a large negative number (filesize - requested_offset) when a FetchData is received where the requested_offset is larger than the filesize. It also avoids unnecessary work. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/542 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 50e98677ca5b62b3b82608c6da3e719956d3a03d Author: Jeffrey Altman Date: Mon Sep 28 16:52:45 2009 +0200 Windows: Directories do not have a default stream When enumerating streams for objects, do not offer a default stream for directory objects (including mount points). LICENSE MIT Reviewed-on: http://gerrit.openafs.org/544 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit fee0efedc12a90605f2c2e3e10d2492be5f42be3 Author: Andrew Deason Date: Mon Sep 28 10:14:23 2009 -0500 Formatting typo in vos_setfields manpage The POD formatting code for bold is B, not b. Reviewed-on: http://gerrit.openafs.org/546 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 158043416326d67708880ed801de53653d9453ad Author: Simon Wilkinson Date: Mon Sep 28 16:21:21 2009 +0200 Don't try to print the thread ID pthread_t is defined as being opaque - there's no way to portably print it on a way that makes sense on all platforms. Remove this output. Reviewed-on: http://gerrit.openafs.org/541 Reviewed-by: Tom Keiser Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 4f65bec3fc4d0c1157aa80323c8d7ecc8a53d3a1 Author: Simon Wilkinson Date: Mon Sep 28 16:50:20 2009 +0200 Fix warnings in new dumptag code 3f2dd80697959f5922032f4d4a7c9ef0cfadf35c contained a number of new warnings. This patch fixes them. It also adds the AFS_UNUSED_FUNCTION macro which can be used to portably mark functions as unused. Reviewed-on: http://gerrit.openafs.org/543 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 6d628bbb7c188e5644e27b3657d824c1481034b6 Author: Simon Wilkinson Date: Sat Sep 26 17:44:06 2009 +0100 Squash more viced warnings Get rid of more warnings in viced - Cast fids that we pass into the Dir package to avoid type warnings - Add ()s to a && b || c, to clarify its meaning - (a && b ) || c - Don't use %ld to print ints - Prototype another function from the host package Reviewed-on: http://gerrit.openafs.org/539 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e287f72e4e4de82fd2ab5c4a4137aa58a5f45b55 Author: Derrick Brashear Date: Mon Sep 28 09:53:11 2009 -0400 irix UCRED is already a struct just like everywhere else. move the one last struct UCRED to UCRED like everywhere else Reviewed-on: http://gerrit.openafs.org/538 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 0ec76649b62919cff3244eb0a6390662f72d7950 Author: Simon Wilkinson Date: Tue Jul 14 23:33:16 2009 +0100 Minimise crref() and add a fastpath for cache hits Reduce the number of times we cref() unnecessarily, and add a fastpath at the beginning of readpage() to handle the cache hit case. Refactor the Linux implementation of afs_open to provide a directly callable version that bypasses the OSI layer. Add a non-blocking variant of ObtainReadLock() Reviewed-on: http://gerrit.openafs.org/534 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit be34175e0f089cbf8a90a0afc7362432be004e06 Author: Derrick Brashear Date: Mon Sep 28 09:21:59 2009 -0400 macos 10.6 warning fixes due to 32/64 and a newer compiler, macos 10.6 finds more warnings. these are fixes for some of them. Reviewed-on: http://gerrit.openafs.org/533 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit f63a8662a7b05c60e85f5e525b58ccf476bc1753 Author: Derrick Brashear Date: Mon Sep 28 08:05:15 2009 -0400 kauth should use static_inline for irix et al "static inline" doesn't work on various still-supported systems. use the workaround macro Reviewed-on: http://gerrit.openafs.org/532 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit efe8258a924903e3c9d7b339349f83861d6be0d1 Author: Simon Wilkinson Date: Mon Sep 28 12:01:54 2009 +0200 Use configured compiler for libuafs on Darwin There's no need to hardcode 'cc' for libuafs builds on Darwin. Let the user specify the compiler to use, in the same way as for the rest of the tree. Reviewed-on: http://gerrit.openafs.org/531 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 6d51ebd6c8d4d5d6ddc42b539be5814e7c468d9c Author: Simon Wilkinson Date: Mon Sep 28 12:07:58 2009 +0200 Add support for warning checked builds This patch adds a '--enable-checking' configuration option. When this option is supplied, and gcc is in use, the compiler will treat any warnings as errors. This will hopefully help stop new warnings from creeping into the tree. In order to still be able to build, all of the currently existing warnings are accepted (these are documented in README.WARNINGS). With this set of warning inhibitions, the tree is known to build on 32bit Leopard - other systems may vary. Warning inhibition may be disabled by supplying --enable-checking=all - in this case the tree will definitely not build! If --enabled-checking is not specified, the existing compilation behaviour is maintained, so there is no user-visible change. Gcc 4.2, or later, is required to use the pragma sets contained within this patch. Again, they are not visible unless --enable-checking is given. Reviewed-on: http://gerrit.openafs.org/526 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 5afd2c34699c60ba247b1de8ec42efbed1c09e39 Author: Derrick Brashear Date: Mon Sep 28 07:54:02 2009 -0400 conditionalize stdint.h inclusion in lwp Irix has no stdint.h; wrap in ifdefs so we don't include when we don't have it. Reviewed-on: http://gerrit.openafs.org/530 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 5d3400f4e103a7c4d7027cb809c8a109bf003316 Author: Derrick Brashear Date: Mon Sep 28 07:46:48 2009 -0400 afsmonitor warnings fix again, add missing format strings to *printf to eliminate warnings Reviewed-on: http://gerrit.openafs.org/529 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 9ee76d8a8fe326c64a08aeb0e1785d009b9ffb36 Author: Derrick Brashear Date: Mon Sep 28 06:32:09 2009 -0400 kill cnvldb warnings previously we used fprintf without a format string in some cases. now we don't Reviewed-on: http://gerrit.openafs.org/528 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 3f2dd80697959f5922032f4d4a7c9ef0cfadf35c Author: Hartmut Reuter Date: Fri Sep 11 12:29:45 2009 +0200 Implementation of new dump tag and length standard The implementation follows the specification from October 2007. All old tags are accecpted as before. New tags 0x06-0x60 (capital letters) are followed by a 1 byte length field which may contain directly the length (up to 127) or the length of the then following length field (max 8) ored with 0x80. New tags 0x61-0x77a are directly followed by 4 bytes building a 32bit integer. 0x7b-0xf are single-byte tags, 0x7e meaning next tag is critical. On this basis unknown tags can be skipped unless they were marked critical. In this case the restore is aborted. in dump.h tags following the new standard are marked by an asterisk Last update: added parameter types for HandleUnknownTag. Reviewed-on: http://gerrit.openafs.org/191 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 9a82cdae42512dc6cd55dcc961eec6b1932e707f Author: Simon Wilkinson Date: Mon Sep 28 11:41:52 2009 +0200 Avoid redefinition errors for AFS_NONFSTRANS Some parts of the build provide -DAFS_NONFSTRANS on the command line. This causes an error when the 'param' file redefines it. Fix this by #undef ing the token before defining it. Reviewed-on: http://gerrit.openafs.org/510 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d7b00d5f19e7dfd7d8ee3d600d0184e4364fa7be Author: Marc Dionne Date: Fri Aug 28 17:03:44 2009 -0400 Use intptr_t and uintptr_t for integer/pointer conversions Use intptr_t and uintptr_t casts to appease the compiler when values are converted between 32-bit integers and pointers. This generates many warnings (currently ~170 on linux amd64) when pointers are 64-bit. These types are normally defined in stdint.h, and get defined by autoconf if that's not the case. In a few places, NULL is simply replaced with 0 where compared with an integer. Reviewed-on: http://gerrit.openafs.org/474 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 01aa7055142936f73919c48468707ee90df73dbd Author: Simon Wilkinson Date: Mon Sep 28 10:43:24 2009 +0200 Make butc logging use va_args Change the logging functions in butc so that they use va_args. This means that we can prototype the logging functions, and kill a bunch more compiler warnings. Reviewed-on: http://gerrit.openafs.org/509 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit a53732ef5f425706abc1c5e511df23cecb2f6113 Author: Simon Wilkinson Date: Sat Sep 26 18:11:53 2009 +0100 Miscellaneous warning cleanup Assorted warning cleanup, that it didn't seem to make sense having one patch per file for. This patch - Adds some casting for syscall pointers - ANSIfies SRXAFSCB_GetDE in fsprobe - Loads sys/ioctl.h on some more platforms in usd - Includes some missing header files - Removes unused variables - Makes it clear that VIsSalvager does handle all enumerated types - Adds some more prototypes Reviewed-on: http://gerrit.openafs.org/508 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 6dcf37d8109a31ec1b95438a70e485a66fede848 Author: Simon Wilkinson Date: Sat Sep 26 18:04:06 2009 +0100 Remove some more warnings from rx The mtu variable in InitPeerParams is in the wrong place. It's only required when the (never used) AFS_USERSPACE_IP_ADDR code is enabled. Move the variable to the appropriate location, and indent the if and endif directives in this section to try to make it clearer what the control flow is (my brain hurt) Remove the unused rx_pthread_n_event_wakeups variable ANSIfy rxi_syscall - we can't prototype it yet, sadly. Reviewed-on: http://gerrit.openafs.org/503 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 9d42c45e6513ebfa405ecd1d5404f753a0b2045b Author: Simon Wilkinson Date: Sat Sep 26 22:12:11 2009 +0100 Warning fixes for afs_fetchstore The recent afs_fetchstore refactoring added a load of warnings. Remove them. Reviewed-on: http://gerrit.openafs.org/502 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 4c1c92c0bdd2b62845187c19a5f5821fe08cf47b Author: Simon Wilkinson Date: Sat Sep 26 17:34:48 2009 +0100 Fix signed/unsigned warnings in XDR Our xdr routines use the same native functions to read signed, and unsigned integers from the wire. This leads to compiler warnings when the unsigned versions of these functions are called. This patch always casts to (afs_int32 *) when calling PUT_INT32 and GET_INT32, to resolve these warnings Reviewed-on: http://gerrit.openafs.org/507 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 4bbc4a5a1dc3c07ac130e9afdfab03ac5a245a16 Author: Simon Wilkinson Date: Sat Sep 26 17:50:04 2009 +0100 Tidy up unlog Remove warnings from the unlog code - Prototype internal functions, and make them static - Define variables appropriately - Remove uneccesary local function defintions Reviewed-on: http://gerrit.openafs.org/505 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit ace95ffa63f718c15a3ef362482c030e1f69186f Author: Simon Wilkinson Date: Sat Sep 26 17:52:57 2009 +0100 Remove warnings in the update client and server rx_Read and rx_Write take a datablock which is a char *, rather than a void *. Cast appropriately. Reviewed-on: http://gerrit.openafs.org/506 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit fabe41d6443586778cd992ad0aa8fad41b130114 Author: Simon Wilkinson Date: Sat Sep 26 17:56:48 2009 +0100 Squish some warnings in ubik/ Remove some more warnings from the ubik/ directory - Remove a dangling else case from an if statement - Prototype ubik_dprint_25 - Don't do (a || b()) - it's horrible, and causes warnings! Replace with if (!a) b(); Reviewed-on: http://gerrit.openafs.org/504 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e14e5aa0cfba456eee9252c47294d863e935f67b Author: Simon Wilkinson Date: Sat Sep 26 20:54:06 2009 +0100 Relax compiler specification on Darwin 9 and 10 Commit 1992b702f64f561c75cc74d4645bb0e1afeec6bd made it possible to relax the compiler choice on a per architecture basis. That commit allowed the user to specify their compiler of choice on all Linux systems, but hardcoded 'cc' everywhere else. This patch permits Darwin 9 and 10 users to also override the default compiler for user space builds. Reviewed-on: http://gerrit.openafs.org/501 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 291d31e55f64992d8d529522f3479e5ffe5fd607 Author: Marc Dionne Date: Sat Sep 26 09:32:46 2009 -0400 fetchOps: fix more() prototype Adjust the prototype in the fetchOps structure to match the recent change to rxfs_fetchMore(). Reviewed-on: http://gerrit.openafs.org/499 Reviewed-by: Simon Wilkinson Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 529d487d65d8561f5d0a43a4dc71f72b86efd975 Author: Derrick Brashear Date: Fri Sep 25 03:15:40 2009 -0400 viced cap fetchdata len to avoid negative when trying to read from a short or zero length file, it's possible for sanity checking to knock the length below zero. set a floor at zero. Reviewed-on: http://gerrit.openafs.org/494 Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit bc6559d62c21ee046c4082aba282097a8c1de9ac Author: Simon Wilkinson Date: Sat Sep 26 10:06:27 2009 +0100 Attempt to fix CForeign moredata behaviour The fetchstore patches changed the behaviour of the multiple chunk handling that's used in FetchData when the vnode's CForeign bit is set. In the original code, the data would be read as (length, payload) chunks. The new code does (length, length, payload), which corrupts the incoming data. This patch restores the original control flow. Reviewed-on: http://gerrit.openafs.org/498 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 5d765426e597c60228e66bddaa21bf2453c74a85 Author: Derrick Brashear Date: Fri Sep 25 05:19:33 2009 -0400 h_GetHost_r cleanup cases avoid potentially leaking a cb_in or a capabilities blob; use a common exit function and free when these were left set. Reviewed-on: http://gerrit.openafs.org/496 Tested-by: Alistair Ferguson Reviewed-by: Alistair Ferguson Reviewed-by: Jeffrey Altman commit ce9da0d76c53127e7f2f2142832602b52dd78f10 Author: Claudio Bisegni Date: Thu Sep 24 19:03:28 2009 +0200 AFSPreference Pane, has changed the content of launchd xml control file for AFSBackgrounder has been used Program instead of ProgramArgument Reviewed-on: http://gerrit.openafs.org/495 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f6f9ee5402f1718f330a00ec89fb34b05c3cd360 Author: Simon Wilkinson Date: Fri Sep 25 00:27:40 2009 +0100 Fix CacheFetchProc in cases where the fileserver hates us In some situations, the fileserver returns a large negative number as the length in an FetchData64 call. The old FetchProc code used an int32 to hold this number, and checked length > 0 before attempting to read more data. The new code uses a uint32, and does while (length), which causes the cache manage to loop until RX aborts the connection. This patch restores the old behaviour. length becomes a signed int once more (and the original 32 bit length from the wire is used, rather than truncating the 64 bit value), and the conditional checks for > 0. Reviewed-on: http://gerrit.openafs.org/493 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 29ee678f3ab051a27cae46b02a0d42e0958a6bc8 Author: Andrew Deason Date: Mon Sep 21 12:48:30 2009 -0500 Unlink correct files in salvager Fallout from 0ac956b3384842b3c60e72bde78a4baf58a5877f; a couple of unlink() calls were not updated to use the absolute path. Update them, and log errors from unlink(), since otherwise it is difficult to tell that anything is going wrong. Reviewed-on: http://gerrit.openafs.org/479 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 07b1dc861bee97c44507f437685d7f8c3d094807 Author: Andrew Deason Date: Tue Sep 22 16:59:34 2009 -0500 Solaris: Default to fs_pathconf in afs_pathconf Instead of returning EINVAL in afs_pathconf when we don't recognize the pathconf command, return the result of fs_pathconf. fs_pathconf provides sensible defaults or correctly represents a filesystem not implementing a particular pathconf cmd; all in-tree (Open)Solaris filesystems call fs_pathconf for unimplemented commands. Returning EINVAL allegedly represents that the fileystem does not support pathconf at all. Also, account for OpenSolaris adding another parameter to pathconf-related calls. Reviewed-on: http://gerrit.openafs.org/488 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b56a794f8d77987df07d2efcb8af5f9d63f6e678 Author: Simon Wilkinson Date: Wed Sep 23 18:18:34 2009 +0100 Refactor the cache bypass determination code The code which determines whether the cache can be bypassed occurs in multiple locations in this file. Make a single static inline function that can do this, and use it. Reviewed-on: http://gerrit.openafs.org/489 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3567441f92349bb21bb42405ecf6ada4844551e5 Author: Andrew Deason Date: Tue Sep 22 17:36:38 2009 -0500 Remove one more AFS_UCRED struct After 8a8244dd351f865af2da3b5ebb746ba57723b6a9, AFS_UCRED is no longer assumed to be a struct. Fix one instance that still declares it as a struct. Reviewed-on: http://gerrit.openafs.org/487 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 7edc6694e7632c9736bd1516935604a638165313 Author: Simon Wilkinson Date: Tue Sep 22 17:18:34 2009 +0100 Whitespace cleanup (sorry) The cache bypass code changed the indentation of afs_linux_readpage so that pullups from 1.4 no longer works. This patch simply restores the original (correct) indentation. Sorry for a whitespace change, but this will make things much easier going forwards. Reviewed-on: http://gerrit.openafs.org/486 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f3c3e4da18519571ef3a8a868297510ed4e132a3 Author: Derrick Brashear Date: Tue Sep 22 04:51:15 2009 -0400 DAFS protocol state diagrams update DAFS protocol state diagrams FIXES 124990 Reviewed-on: http://gerrit.openafs.org/485 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 40b18318e4a04a323dbdd9e3c4a73d3b2e92104d Author: Andrew Deason Date: Mon Sep 21 16:57:01 2009 -0500 Implement _PC_FILESIZEBITS for solaris pathconf Using recent NFS clients and servers with the translator under Solaris causes AFS to be queried for the _PC_FILESIZEBITS pathconf value. Right now we don't implement it and return EINVAL, causing at least some modern NFS clients to be unable to mount AFS via the translator on at least some modern NFS servers. So, return _PC_FILESIZEBITS as either 32 or 64, depending on whether we are a 64-bit client or not. Reviewed-on: http://gerrit.openafs.org/481 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit b7ae31a7484b609cd22d029fd753798001f72864 Author: Andrew Deason Date: Mon Sep 21 14:28:29 2009 -0500 Avoid salvager vol header read assert When we read the volume header in order to write it back with a modified inUse while salvaging, we were aborting if we couldn't read the header. Since we can fail to read the header data if the volume header file isn't associated with any data (and will be deleted by the salvager), don't abort. Do still abort if we can't write the data back, since if the data can be read but not written, other programs may think that the volume is not being salvaged. Reviewed-on: http://gerrit.openafs.org/480 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 759c756b0fa51b774e3894d5f9a5029955232612 Author: Andrew Deason Date: Mon Sep 21 11:09:56 2009 -0500 DAFS: Put back volumes we get in FSSYNC handlers fssync-server.c has a few issues with not properly VPutVolume_r'ing volumes that were VGetVolume_r'd. The most important of these was that the handler for FSYNC_VOL_MOVE can put back a volume it did not get, when DAFS is enabled. Fix that, and another erroneous edge case in the FSYNC_VOL_QUERY_HDR handler when DAFS is not enabled. Reviewed-on: http://gerrit.openafs.org/477 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 1542d943df24de94e4b61e0303db542f0e2c982d Author: Derrick Brashear Date: Mon Sep 21 12:33:37 2009 -0400 make 1.5.64 for unix update version strings to 1.5.64 Reviewed-on: http://gerrit.openafs.org/478 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e646a3e4dc62aaccebb81dada9d6d744ac19354f Author: Felix Frank Date: Sun Sep 20 14:43:34 2009 +0200 Use the padd op. When the padd operation was added, the change that makes actual use of it got lost somewhere along the line. Fixed now. Originally introduction of the padd op: 6220ede6a96d06c53eddd848435764cff96be1b4 Reviewed-on: http://gerrit.openafs.org/471 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 4fd7101577613bbafcf4488f3d82dd03642b01c0 Author: Jeffrey Altman Date: Mon Sep 21 17:11:25 2009 +0100 Windows version number 1.5.64 Reviewed-on: http://gerrit.openafs.org/476 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 91d9ca106def5cde2b75e2b03ad0111a44551868 Author: Jeffrey Altman Date: Mon Sep 21 17:07:23 2009 +0100 Windows: 1.5.64 updates for Windows Notes LICENSE MIT Reviewed-on: http://gerrit.openafs.org/475 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 10706d8208df865ac0bc89f6d83a5779b9794128 Author: Jeffrey Altman Date: Sun Sep 20 11:06:07 2009 -0400 Windows: uninitialized variable in cm_GetBuffer Initialize code and code1 to zero. Otherwise, a non-zero value on the stack can result in an incorrect error value being passed to cm_Analyze(). LICENSE MIT Reviewed-on: http://gerrit.openafs.org/473 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 65d1d94634c2d31aeecf1c512828a1bcbd93bbe5 Author: Jeffrey Altman Date: Sun Sep 20 11:04:07 2009 -0400 Windows: Protect against null serverp in cm_Analyze If cm_Analyze is called with both 'serverp' and 'connp' set to NULL and an RX error is provided, a null pointer dereference will occur. Test for non-NULL serverp before dereferencing LICENSE MIT Reviewed-on: http://gerrit.openafs.org/472 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 427b27a87fd34035f855ff8b1b9ec3ad618829c8 Author: Jeffrey Altman Date: Sat Sep 19 13:52:32 2009 -0400 Windows: Do not mark server down due to Store / Fetch Data protocol error When performing a StoreData or FetchData operation there are several data validation checks performed to ensure that the lengths of data obtained with rx_Write and rx_Read are consistent with the RXAFS_FetchData and RXAFS_StoreData protocol operations. When an inconsistency is detected the cache manager terminates the call and returns an error to the caller which is passed to cm_Analyze(). The cache manager was returning -1 as the error code which is equivalent to RX_CALL_DEAD which in turn will result in the server being marked down. This commit makes the following changes: . add trace logging to permit monitoring this case . instead of returning -1 return either RX_PROTOCOL_ERROR or RX_EOF depending on the situation . in cm_Analyze do not mark a server as down for rx errors other than RX_CALL_DEAD. Instead, force a new connection and retry until the request timeout limit is reached. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/470 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 5b5dc4a85bde6e959a0943ac694833784a838164 Author: Jeffrey Altman Date: Mon Sep 14 07:59:54 2009 -0700 Windows: more pioctl output validation Add output validation checks to the Explorer Shell and the Client configuration control panel. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/458 Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit 72e8bac22201e194242e715a107f3b3cb8a480df Author: Jeffrey Altman Date: Sat Sep 19 04:55:09 2009 -0400 Windows: Use "Name not found" instead of "File not found" When a file cannot be opened because the name of the file or a directory in the path cannot be found, return "Name not found" instead of "File not found". "File not found" is the error returned by the smb redirector to the application when the file cannot be located in the search path. "Name not found" indicates that the entry is not present at the location requested. The use of "File not found" prevented execution of applications from the \\AFS name space on Windows 7. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/469 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 3be5d2ca5f2a1af97502f5fd0f5b25f382b123c4 Author: Jeffrey Altman Date: Fri Sep 18 10:46:07 2009 -0400 Windows: trace logging changes for smb_ReceiveTran2QPathInfo Add new trace log entries in smb_ReceiveTran2QPathInfo to help track down the reason for queries in which the path and tidPath are both the empty string. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/467 Tested-by: Asanka Herath Reviewed-by: Asanka Herath Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 2c54ae82a49f6df7f7c76d333d3fe00a0b1cff28 Author: Jeffrey Altman Date: Fri Sep 18 10:41:14 2009 -0400 Windows: Improve WKSSRC and SRVSVC compatibility with Windows This commit includes several changes to improve compatibility with Windows (in particular Windows 2000). 1. Specify a Lan Workgroup name. We use "AFS". 2. Ensure that the server name returned does not include leading slash or backslash characters. The name provided might include them but they are not part of the name and cannot be returned. 3. The NetrWkstaGetInfo and NetrServerGetInfo responses must be consistent. Otherwise, the Explorer Shell will get confused and refuse to provide access to the server shares. This commit also includes some minor comment changes. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/466 Tested-by: Asanka Herath Reviewed-by: Asanka Herath Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 211a23a06fd762478aa2f420b9cc638320857463 Author: Jeffrey Altman Date: Fri Sep 18 10:25:59 2009 -0400 Windows: Trace wkssvc and srvsvc rpc calls Add osi_Log statements identifying which RPCs are being called from the wkssvc and srvsvc modules LICENSE MIT Reviewed-on: http://gerrit.openafs.org/465 Tested-by: Asanka Herath Reviewed-by: Asanka Herath Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit ccb02bf6eb7395bbb3d66c11b99a576c19d033d4 Author: Jeffrey Altman Date: Fri Sep 18 10:01:10 2009 -0400 Windows: No rand_s on Windows 2000 Even if the rand_s() function is supported by the compiler it is not supported on Windows 2000 because the kernel level functionality it requires does not exist on that platform. Calling rand_s() on Windows 2000 will throw an exception and terminate the service. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/464 Reviewed-by: Derrick Brashear Tested-by: Asanka Herath Reviewed-by: Asanka Herath Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 1ba9e95715a5c769580adbbda2ca19aae62eef75 Author: Andrew Deason Date: Fri Sep 18 13:23:46 2009 -0500 DAFS assert correction in GetVolume FSSYNC_VolOpRunningUnknown is a vol op state, not a pointer to a vol op itself. Reviewed-on: http://gerrit.openafs.org/468 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 48589b5d3957c27a5944e23fd770687adc078934 Author: Marc Dionne Date: Mon Sep 14 17:40:23 2009 -0400 Linux: Restore aklog -setpag functionality for kernel 2.6.32+ With kernel 2.6.32 it is now possible for a process to copy its session keyring to its parent through the use of the KEYCTL_SESSION_TO_PARENT function of the keyctl syscall. We can't use this easily from kernel space to cover all calls to VIOCSETTOK with the setpag flag - we'd need to make a syscall or have keyctl exported. Instead, a hook is added to ktc_SetToken to make it honour the AFS_SETTOK_SETPAG flag, which was ineffective with recent kernels. This should cover the most common cases (ex: aklog) where this is needed. The syscall is coded directly to avoid introducing a dependency on the keyutils library or header files which may not be installed everywhere. Reviewed-on: http://gerrit.openafs.org/463 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 1ea845ebc953bb49afc354afe036f7f01cd05db8 Author: Claudio Bisegni Date: Tue Sep 15 09:29:21 2009 +0200 Manage the login in the OSX Fast User Switch mode AFSBackgrounder has been update to get notification for switch in/off in the "Fast User Switch" mode, and in switch in it try to get tokens. Reviewed-on: http://gerrit.openafs.org/460 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 8af8af05f0a87af154f11bc8a7a7ec3f2505291e Author: Simon Wilkinson Date: Mon Sep 14 13:49:22 2009 +0100 Remove unecessary initialisation We already memset av to contain all 0s, therefore we don't need to initialise individual elements to 0 as well. Inspired by Rainer Toebbicke's patch for RT 125355 (which is 1.4.x only) Reviewed-on: http://gerrit.openafs.org/456 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 090b61e9d731d1cc55707fcb9ea6dbc7bc7b5018 Author: Brant Gurganus Date: Sun Sep 13 22:02:10 2009 -0400 Corrects file_CmdRef_1_fs_chgrp_html and file_CmdRef_1_fs_chown_html sharing short names. Reviewed-on: http://gerrit.openafs.org/455 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit bb4a5038d9f8d0585ed39ba3d82d459d7ca5d398 Author: Jeffrey Altman Date: Sun Sep 13 10:32:12 2009 -0400 Add indexing to Windows Release Notes An initial pass at adding indexing to the Windows release notes. The next pass should refine the index terms and add appropriate secondary index values. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/454 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit d190d2400eeef7f736338edea943ba8b93f64c69 Author: Jeffrey Altman Date: Sun Sep 13 01:45:48 2009 -0400 Windows Release Notes XML Reformat the Registry and Environment Values in Appendix A so that they are easier to identify in the table of contents. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/453 Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit a747e934c40040061386d8ca591eba09b9745287 Author: Derrick Brashear Date: Sun Sep 13 01:00:45 2009 -0400 cm fetchstore should dereference unset ops if rxfs_fetchInit fails, ops will not be set; calling the destroy op unconditionally thus leads to a panic. Reviewed-on: http://gerrit.openafs.org/452 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 4b6fafa440fa51652d12d6522769c8f156b7bda1 Author: Derrick Brashear Date: Fri Sep 11 13:26:01 2009 -0400 macos package updates make the readme correct; allow back reving (downgrades) Reviewed-on: http://gerrit.openafs.org/447 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 431b54f642c5c34e260a1b35ecfca17d5e3dcde5 Author: Jeffrey Altman Date: Fri Sep 11 11:44:41 2009 -0400 Windows: Version 1.5.63 Reviewed-on: http://gerrit.openafs.org/445 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit d15ca10da0074bd14a777a0590e7271fe28ecf01 Author: Derrick Brashear Date: Fri Sep 11 13:30:29 2009 -0400 unix 1.5.63 make 1.5.63 for unix Reviewed-on: http://gerrit.openafs.org/448 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 60c44cc6ddf101b8085f242f2c1bf85896563923 Author: Jeffrey Altman Date: Fri Sep 11 11:41:01 2009 -0400 Windows: changelog updates for 1.5.63 LICENSE MIT Reviewed-on: http://gerrit.openafs.org/444 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 5b6e5019453952f122523354d0001b04189271a7 Author: Derrick Brashear Date: Tue Sep 8 14:31:09 2009 -0400 make fileserver avoid salvage loop on init failure if the vlserver or prserver setup can't succeed, it doesn't indicate a condition which salvaging is required to fix; instead, come up and retry in the background. Reviewed-on: http://gerrit.openafs.org/428 Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 133fed07384aec910e22b4fd315f86440dff2fb2 Author: Felix Frank Date: Thu Jul 16 08:26:55 2009 +0200 Code beautifications. * get rid of register declarations * remove unused local var InStatus * comment prototypes properly (correct .c file) * save some linebreaks in function headers Reviewed-on: http://gerrit.openafs.org/135 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit bffbc55c220bd28c20856b5d00ed423f878319d8 Author: Felix Frank Date: Mon Jul 13 13:40:26 2009 +0200 More cosmetics. * FetchProc: length loop shorter condition * added fancyspace in FillStore call. * removed unused bsent variable * shortened some conditions * storeDestry: saved the code2 variable. Reviewed-on: http://gerrit.openafs.org/134 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit e99490ffd31edef1a349f06f975949b82707a0ee Author: Felix Frank Date: Mon Jul 13 13:28:41 2009 +0200 Cosmetics in CacheStoreDCaches, CacheStoreVCache and storeInit. * StoreProc: renamed alen to size. * StoreProc: Make connection before do {} * rename fP to tfile. * Declare nchunks later in StoreProc. * Fixed order of storeInit parameters. * storeInit: renamed tlen to length. Reviewed-on: http://gerrit.openafs.org/133 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit d47eb8f21b2782d9441c2ea4d0261c21cb423a19 Author: Felix Frank Date: Mon Jul 13 11:13:21 2009 +0200 Immediately abort call when not able to fetch length (fetchInit). Reviewed-on: http://gerrit.openafs.org/132 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 63abaf515c6f16907fdd9a226797bdc310dd704a Author: Felix Frank Date: Mon Jul 13 10:26:47 2009 +0200 Locking comment in FetchProc Reviewed-on: http://gerrit.openafs.org/131 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 46f7bbb19dbb697e626a20363ff23ad2fe0ee4c0 Author: Andrew Deason Date: Wed Sep 9 09:22:02 2009 -0500 Do not respond to SYNC_COM_CHANNEL_CLOSE requests SYNC clients, when closing a channel, send a SYNC_COM_CHANNEL_CLOSE command, and immediately disconnect before waiting for a response. So, don't send a SYNC response, since by the time we send it, the other end will most likely have already hung up, causing a lot of needless 'SYNC_putRes: write failed' messages whenever a SYNC channel is closed (e.g. when a demand-salvage finishes). Reviewed-on: http://gerrit.openafs.org/434 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c1c8da78b680964b0259266207b2c07df54b5ef1 Author: Jeffrey Altman Date: Fri Sep 11 11:54:27 2009 -0400 Windows: Handle "(Default)" regsitry value in MountGlobalDrivesThread In MountGlobalDrivesThread(), if the "(Default)" registry value is defined that should be interpreted as a drive mapping to a device with no name. This is specified using NULL instead of the nul-string. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/446 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit bef42619ba3cf7f4b20783942c989e6d96185104 Author: Felix Frank Date: Mon Jul 13 10:08:37 2009 +0200 fetchDestroy can end calls now too. Reviewed-on: http://gerrit.openafs.org/130 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit b961dc1630baf9e6e1171c66430074fc1e7f9ef8 Author: Felix Frank Date: Mon Jul 13 10:06:50 2009 +0200 Included proper 64bit case in fetchClose() and storeClose(). Reviewed-on: http://gerrit.openafs.org/129 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 3898524693e7297e228ded03f34125558f225d58 Author: Derrick Brashear Date: Fri Sep 11 01:59:08 2009 -0400 darwin knet avoid rx socket during shutdown theoretically a user thread can race us during shutdown and end up panicing us if the soclose happens at the wrong time. if we're shutting down just return. using afs_shuttingdown would have the side effect that we'd lose the ability to add any graceful behavior. Reviewed-on: http://gerrit.openafs.org/443 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit cc7938e8ff2a56575122066a8750e881c4d280b0 Author: Felix Frank Date: Mon Jul 13 09:07:17 2009 +0200 Added guard against missing call and moved alength assignment in fetchInit. The returned value of rx_NewCall is important of course and must be taken into account before trying to start RPCs. Do assign the length output variable ASAP. Also fixes an overlong line and the type of the pos local var to unsigned. More style fixes: * Moved length64 to use proper scope, initialized code. * Generally make more tidy Reviewed-on: http://gerrit.openafs.org/128 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 98f9b6ae2bafe69440c090443efb2f71ec15309c Author: Derrick Brashear Date: Fri Sep 11 01:28:49 2009 -0400 des crypt cope with 64 bit longs we test for them in configure; instead of hardcoding it in yet another place, use the information we have Reviewed-on: http://gerrit.openafs.org/442 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit e24d64f2a696eb85b44fb471326f6dbb525d60a0 Author: Jeffrey Altman Date: Fri Sep 11 00:35:04 2009 -0400 Windows: Add pioctl data output validation to fs and symlink command line tools pioctl data buffer output was not being validated to ensure that buffers were not overwritten or accessed beyond their limits. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/441 Reviewed-by: Derrick Brashear Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit fdea6a3418315cd7b88219778118857fd32e9da6 Author: Russ Allbery Date: Thu Sep 10 11:02:46 2009 -0700 Windows: update build system for restorevol man page move restorevol moved from section 8 to section 1. The Windows build system needed corresponding changes. Reviewed-on: http://gerrit.openafs.org/440 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit d96ec9ec031d0d15d1cfe3b86e58c12c4c267c00 Author: Russ Allbery Date: Fri Aug 21 18:59:01 2009 -0700 Stop using sig_t acinclude.m4 was adding to afsconfig.h some code to define sig_t as the type of a signal handler. This definition was in terms of RETSIGTYPE, which is deprecated by Autoconf. It also adds an unnecessary abstraction for only two places in the AFS source code where it was used. Remove it and change those two spots to use the standard C declaration of the function pointer. Reviewed-on: http://gerrit.openafs.org/335 Tested-by: Simon Wilkinson Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear commit d6df1a8cec39edf7c0d2598921c735ac6aca70d7 Author: Russ Allbery Date: Fri Aug 21 18:12:39 2009 -0700 Move restorevol to bin from sbin restorevol only requires access to a dump file and write access to the directory in which the dump is being unpacked. It doesn't require being a superuser, so it should be installed in bin instead of sbin. Also move the man page to section 1 and update references accordingly. Reviewed-on: http://gerrit.openafs.org/333 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit c46689c05ffd56299a12f9883645e8fcf50fa29a Author: Derrick Brashear Date: Tue Sep 1 11:18:19 2009 -0400 redhat spec dkms don't strip modules provide a debug module which is unstripped. this is necessary for debugging problems. Reviewed-on: http://gerrit.openafs.org/391 Reviewed-by: Russ Allbery Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 96a176ed5872f54402e1625f6e67ce2979e48875 Author: Derrick Brashear Date: Thu Aug 13 10:05:44 2009 -0400 make salvager able to cope with corrupt class index right now if a directory ends up in the small vnode index, the salvager will never fix it. unlinking from the index (and recovering an orphan later) beats crashing forever Reviewed-on: http://gerrit.openafs.org/309 Reviewed-by: Russ Allbery Tested-by: Russ Allbery commit 754a4b628a14657db2e00931926311a1c703558b Author: Derrick Brashear Date: Wed Sep 9 18:49:29 2009 -0400 macos panic decoder should handle 64 bit kernel in 32 bit mode panic from 64 bit should be decodable in 32 bit mode. make it so. add -k switch to allow a path to a kernel to be specified. Reviewed-on: http://gerrit.openafs.org/438 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 392e3dab970c998af63ddb43665655e0f3815c45 Author: Marc Dionne Date: Wed Sep 9 19:00:49 2009 -0400 Avoid __USE_XOPEN redefinition Only define __USE_XOPEN if not already defined. This eliminates a few build warnings where __USE_XOPEN is already defined in system header files. Reviewed-on: http://gerrit.openafs.org/439 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit 12a7afa6481e8e4a9c0ef8115eaf328dc7af3029 Author: Marc Dionne Date: Wed Sep 9 18:39:24 2009 -0400 Remove extraneous + character in src/volser/common.c Remove an unneeded extra + character at the end of line - probably from a typing accident. This generates a warning at compile time. Reviewed-on: http://gerrit.openafs.org/437 Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear commit f041bd25343f40986c035ed6c0a087709ed64bc4 Author: Felix Frank Date: Mon Jul 13 08:54:23 2009 +0200 Cosmetics: Rename some variables, fix types. * Replaced tsize by new local var llbytes in rxfs_storeInit. * Make int32 lengths unsigned in rxfs_storeInit. * Renamed lengthFound to length64. * renamed abase to base. Reviewed-on: http://gerrit.openafs.org/127 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 23143230e68516c89f3acf76999223dad4af612f Author: Christof Hanke Date: Wed Sep 9 16:21:44 2009 +0200 Moved CForeign check to rxfs_storeInit/storeMore. This is rxfs-specific, so move it out of CacheStoreProc. It must be done before entering the do { } while (moredata) loop proper now, as rxfs_fetchMore is never called during the first iteration (moredata is always 0), but the length may need fixing (note that this was done after what is now the fetchMore op originally). Thus it appears in rxfs_fetchInit. To prevent a bogus call during the first loop iteration, also check for length!=0. Finally, don't bother with fetchMore at all unless CForeign is set. In rxfs_fetchInit, we added an additional check for length_hi being zero. uploade patchset 8. Reviewed-on: http://gerrit.openafs.org/126 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear commit 01fae602425b91647b54888c82450091d4c89714 Author: Jeffrey Altman Date: Tue Sep 8 16:36:32 2009 -0400 Windows: Use secure ctime and strncpy in afs_ctime Microsoft compilers version 1400 and above provide secure versions of ctime and strncpy. Use them in afs_ctime. Correction to sha1:359c64bb674ea0606e64b91fd8252297310a9862 Thanks to Andrew Deason for identifing the mistake. Reviewed-on: http://gerrit.openafs.org/429 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 5d1efd3cd86f12d6be073e9b8103f16bf33d8bab Author: Jeffrey Altman Date: Tue Sep 8 16:43:01 2009 -0400 Windows: secure rand() rand_s() is available on Visual Studio 2005 and above (aka 1400 and above) LICENSE MIT Reviewed-on: http://gerrit.openafs.org/430 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 0f7efd94fa12cf82efe6c31ee33d9b3ca51666e1 Author: Jeffrey Altman Date: Sun Sep 6 15:10:56 2009 -0400 Windows: Add data validation to ktc_xxxx functions that perform pioctls The ktc_GetToken and ktc_ListTokens functions perform a pioctl and then parse the response data. There is no validation that the data required is not longer than the pioctl output or that the data received fits into the data structures that are being written. As a result, random crashes have occurred when the wrong data has been received from the pioctl. This commit adds data validation to at least ensure that these functions cannot read beyond the data provided or write beyond the allocated memory. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/405 Reviewed-by: Derrick Brashear Reviewed-by: Asanka Herath Tested-by: Asanka Herath Reviewed-by: Jeffrey Altman Tested-by: Jeffrey Altman commit f7085c38e15db15e2795ff33e9b54977e703a097 Author: Marc Dionne Date: Tue Sep 8 17:58:41 2009 -0400 build fix: ubik_client is a struct Fix a build failure - ubik_client is a struct and not a type Reviewed-on: http://gerrit.openafs.org/431 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman commit 359c64bb674ea0606e64b91fd8252297310a9862 Author: Jeffrey Altman Date: Sun Sep 6 18:47:54 2009 -0400 Windows: Use secure ctime and strncpy in afs_ctime Microsoft compilers version 1500 and above provide secure versions of ctime and strncpy. Use them in afs_ctime. Reviewed-on: http://gerrit.openafs.org/408 Reviewed-by: Derrick Brashear Tested-by: Asanka Herath Reviewed-by: Asanka Herath Tested-by: Derrick Brashear Reviewed-by: Jeffrey Altman commit 1992b702f64f561c75cc74d4645bb0e1afeec6bd Author: Russ Allbery Date: Sat Aug 22 00:31:22 2009 -0700 Only force a specific compiler where necessary Rather than setting the compiler to cc on all platforms by default, use the Autoconf default unless the specific compiler might matter. Conservatively set the compiler to cc for all non-Linux, non-BSD operating systems that previously didn't explicitly set it. Fix a few places on Linux where the compiler was set to gcc explicitly rather than using the Autoconf result.