Commit Graph

10262 Commits

Author SHA1 Message Date
Niklas Jonsson
3c16a2b296 Auth: increase size of DNS resolver answer buffer
This patchset increases the size of the res_search() answer
buffer from 1024 octets to 4096 octets.   This is not a proper
long term solution but will permit sites with longer response
lists to make use of SRV and AFSDB records.

This patchset only impacts UNIX systems.  Windows uses the
Win32 DNS resolver which dynamically allocates memory based
upon the size of the response.

FIXES 130936

Change-Id: I8434e128fb5918839c216209851b37a17cf94065
Reviewed-on: http://gerrit.openafs.org/7575
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
2012-06-20 14:01:25 -07:00
Simon Wilkinson
5019ecd5fa rx: provide mechanism to send a bare abort packet
simply put an abort on the wire

Change-Id: I0486e1826da9466a2982ac07c3749876848a7f66
Reviewed-on: http://gerrit.openafs.org/7562
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 19:36:03 -07:00
Simon Wilkinson
4660b53e69 opr: Add simple time type
Add a simple time type to the opr library, which provides helper
routines to implement the 100ns time format selected for on-the-wire
use for AFS-3 (this also provides a handy single integer internal
time format)

Change-Id: I1f2d81e61a3e4124e0dd49830a115b72d7a7b37f
Reviewed-on: http://gerrit.openafs.org/7559
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 15:23:02 -07:00
Simon Wilkinson
ba300e35a5 viced: Abstract out peer mapping code
Pull the code which gets the peer information for an incoming connection
into its own function.

Reformat this function a little to avoid if-ladders.

Change-Id: I4a48e0079f00cca4fe651161fb19453f63527336
Reviewed-on: http://gerrit.openafs.org/7561
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 12:53:54 -07:00
Simon Wilkinson
fa1f2687af viced: Tidy up VL initialization
Tidy up the routines which initialize the VL server so that they
don't reopen an already open configuration directory, and so that
some global variables are less globally scoped.

Change-Id: I7e83073b2d984203e03133e94da4ec875d1b8472
Reviewed-on: http://gerrit.openafs.org/7560
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 12:49:21 -07:00
Simon Wilkinson
ed02c6ff8a rxgen: Make input strings const
Modify the code generation routines so that string inputs to RPCs
are declared as (const char *) on the client side. This doesn't affect
callers as we can freely cast from (char *) to (const char *), but means
it is easier to write API wrappers that accept const arguments.

Change-Id: I4719d04f03bd76cbe7ee21ad7511f6f3b3d36163
Reviewed-on: http://gerrit.openafs.org/7556
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 12:45:27 -07:00
Simon Wilkinson
9b97b80dd8 aklog: Fix error message fallback for Heimdal
Since we reverted to using Russ's upstream version of rra-c-util's
krb5.m4, we no longer check for the existence of the pure com_err
error_message().

So, for error message fallback on Heimdal, use krb5_get_error_message()
instead. As we don't have access to the context in which the error
occurred, build one to get the raw com_err error translation - this
won't give us any additional context specific detail.

Change-Id: I4bab080704ec5d08e8b85e6b7ad69cf1f89bf3b3
Reviewed-on: http://gerrit.openafs.org/7554
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 06:46:13 -07:00
Simon Wilkinson
5db615100a viced: Abstract out hpr thread context code
Every hpr lookup function had a copy of the same code to pull a thread
specific ubik context out of the pthread library, and to create one if
one wasn't already there.

Instead of endlessly repeating this code, create a small inline function
to do the job.

Change-Id: I7eac0eaebbd42978e40c90f0ce59b26f2e67d96d
Reviewed-on: http://gerrit.openafs.org/7558
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 05:36:08 -07:00
Simon Wilkinson
c855dd726a rx: Constify rx_opaque_populate
rx_opaque_populate doesn't modify the data passed into it, so
make that argument const

Change-Id: Icc7c121bda43a8abc19f72affc70967baba91e6d
Reviewed-on: http://gerrit.openafs.org/7557
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 05:35:52 -07:00
Simon Wilkinson
fac69a5c88 viced: Remove unused profiling code
src/viced/profile.c is never built, and contains unused code which
is now useless to us. Just remove it from the tree - it is in git if
we ever need it again.

Change-Id: I04da5395f5c4a618968958f1696f638e0db69122
Reviewed-on: http://gerrit.openafs.org/7555
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-14 04:45:44 -07:00
Derrick Brashear
a08604b78f uss: allow disabling by configure switch
provide an option to disable building uss. current heimdal
when built static can leak symbol names for its flex/bison parser
causing symbol conflicts. this is but a workaround, but
sites not needing uss can at least use it.

Change-Id: Ibab1dd189e7fbc41ca01e7ef7479421c056999f5
Reviewed-on: http://gerrit.openafs.org/7553
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-13 15:19:44 -07:00
Derrick Brashear
5d53c12b95 gtx: add configure switch to force not building
allow gtx and associated software to be turned off.

Change-Id: If02427311c79e0784fcc5fb1816a449f7dcdd879
Reviewed-on: http://gerrit.openafs.org/7552
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-13 15:19:28 -07:00
Derrick Brashear
6d3390bc16 aklog: can't assume krb5_524_conv_principal based on convert_creds
add probing for krb5_524_conv_principal directly instead of
assuming finding a 524 library will find it. current heimdal
does not include it.

Change-Id: Iea523e3e7ba4cb51ec5a0d4b38fec9c7df30529d
Reviewed-on: http://gerrit.openafs.org/7551
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Tested-by: Derrick Brashear <shadow@dementix.org>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-13 15:18:25 -07:00
Derrick Brashear
3e0eaec61e viced: fix GetVolumePackage to not bomb always when GetClient called
master only. already correct in 1.6. the gotos for error exit should
be called only when we have an error, due to missing braces that was
not true

Change-Id: I396be7d34ad741e01634a702784a0892f47a2d5a
Reviewed-on: http://gerrit.openafs.org/7549
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Simon Wilkinson <simonxwilkinson@gmail.com>
Reviewed-by: Marc Dionne <marc.c.dionne@gmail.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-11 15:27:46 -07:00
Derrick Brashear
3770ffe416 viced: fix merge error
when 37fc2dfbb9 was merged, the close
bracket went in the wrong place, meaning for non-remote calls
we don't re-enable keepalives. fix it.

Change-Id: I163db9b3b2f42f629d8a5ff22a75902a61a3138b
Reviewed-on: http://gerrit.openafs.org/7548
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Reviewed-by: Simon Wilkinson <simonxwilkinson@gmail.com>
Reviewed-by: Marc Dionne <marc.c.dionne@gmail.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-11 15:27:23 -07:00
Andrew Deason
4f9c3f2be9 vol: Avoid getting stuck in ATTACHING in attach2
Since commit 5fc2365f, a VNOVOL error early in attach2 meant that we
skipped changing the volume state to anything, and just returned
instead. When we do this, the volume is in VOL_STATE_ATTACHING for
DAFS, and so if we return, the volume will forever be in
VOL_STATE_ATTACHING. The next thing that tries to access the volume
will wait forever for the volume to come out of that state.

So, revert half of 5fc2365f, and transition to ERROR state instead.
This code path should not be hit during normal usage, since a
nonexistant volume access for the fileserver will be detected earlier.
If the volume does not appear to exist at this stage of attachment,
something is wrong with the volume, so this warrants the ERROR state.

For the volserver and other volume utilities, we may hit this when a
request just plain references a nonexistant volume for whatever
reason, but in that case the vp should go away soon. For non-DAFS,
this commit does not change much, since the difference between
error_notbroken and unlocked_error is very small.

The other half of 5fc2365f is not changed, since it is correct. For
VOFFLINE errors at this point, the volume has already been
transitioned to VOL_STATE_UNATTACHED, so it is okay to return. Add a
comment to help make this more explicit.

Change-Id: I63853f6e1721020cd204639c6e3ce4b59de08f75
Reviewed-on: http://gerrit.openafs.org/7516
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-11 15:26:53 -07:00
Andrew Deason
a43f0e4717 DAFS: Preattach, not attach, in FSYNC_Drop
FSYNC_Drop currently attaches volumes that were checked out by the
dropped fssync handler, but not checked back in, in order to make the
volume available again. For DAFS, however, a full attachment is
unnecessary; just preattach instead.

Change-Id: I2c9d0b8cf0ddc7f4182347706b2c26d86f69725e
Reviewed-on: http://gerrit.openafs.org/7515
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-11 15:26:00 -07:00
Andrew Deason
fff80cb198 vol-salvage: Unlock volumes before exiting
Normally, volume locks acquired by an exiting salvaging process would
be automatically given up when the process exits, since our FDs are
closed. However, if we exit by calling Exit() or Abort(), we
gracefully shutdown our SYNC channels before exiting. For FSSYNC, this
can result in the fileserver trying to online the volumes we had
checked out but had not yet checked back in, so the fileserver may try
to online a volume we have locked, before the locks have been
released.

To avoid this, unlock all volume locks for all partitions before we
shutdown SYNC channels on exit.

Change-Id: Idcda5fcf4639da7d4b951bea36606ea8daf68f3c
Reviewed-on: http://gerrit.openafs.org/7514
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: Derrick Brashear <shadow@dementix.org>
2012-06-11 15:25:15 -07:00
Andrew Deason
80359f562a vol-salvage: Indent some ifdefs
Change-Id: I213859d35ba4908e088a0ba2117f527ab8db3dc8
Reviewed-on: http://gerrit.openafs.org/7513
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-11 15:24:45 -07:00
Derrick Brashear
9bb876f682 libafs: initialize free dcache list for memcache
reuse the disk cache dcache creation code for memcache, then
call it to prime the list

Change-Id: If63268aa1a89c9642236f944e1ac8328d68aeba5
Reviewed-on: http://gerrit.openafs.org/7446
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: Derrick Brashear <shadow@dementix.org>
2012-06-11 15:23:58 -07:00
Derrick Brashear
a8e35e9fd7 viced: clear optstring before parsing
we try to free the string if there was a value, so
if there's none we should probably ensure we know it

Change-Id: I20fc535e56d65c82f26852ba59528d5660c98e20
Reviewed-on: http://gerrit.openafs.org/7546
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: Derrick Brashear <shadow@dementix.org>
2012-06-08 16:56:16 -07:00
Derrick Brashear
7273c8b4ae cmd: avoid issues with static heimdal
stealing the krb5 parser and linking with static heimdal can cause problems.
remap things we have which duplicate heimdal's private namespace.

Change-Id: I89030967a32997f00a21e97258056c26f2a4cbf6
Reviewed-on: http://gerrit.openafs.org/7545
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: Derrick Brashear <shadow@dementix.org>
2012-06-08 13:30:37 -07:00
Marc Dionne
5227148ae1 Linux 3.5: encode_fh API change
The encode_fh export operation now expects two inode arguments
instead of a dentry and a "connectable" flag.  Use the inode of
the dentry we're interested in, and NULL as the parent inode which
is the same as passing a 0 flag in the previous API.

Change-Id: I05cf146fb2a4bacdca20a9f108d04ccb11530804
Reviewed-on: http://gerrit.openafs.org/7523
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-07 05:13:50 -07:00
Marc Dionne
bc3a32a84f afsd: include sys/resource.h in afsd_kernel.c
With a recent glibc update, sys/wait.h no longer includes
sys/resource.h unless __USE_SVID, __USE_XOPEN or __USE_XOPEN2K8
are set.

Don't rely on the indirect inclusion to get the bits we need;
include it directly in afsd_kernel.c.  This include used to be
there but was dropped when afsd_kernel.c was split off.

Change-Id: I1bfd2e0c340e15ca44472aa89614f088e0c0ce0c
Reviewed-on: http://gerrit.openafs.org/7522
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-06-07 05:13:22 -07:00
Jeffrey Altman
0d2c1dfd55 windows: AFSQueryVolumeInfo exception info
Protect against NULL FileObject or ObjectInformation.

Log additional information when an exception is caught in
AFSQueryVolumeInfo.

Change-Id: I6111345e53edc641f4d809839c1666f7a11a93d3
Reviewed-on: http://gerrit.openafs.org/7525
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-06-06 08:09:28 -07:00
Jeffrey Altman
371af87a23 Windows: SMB GetFileAttributes support
commit 56a2cbb5fb added a
GetFileAttributes query to the pioctl interface to protect
against printing pages on printers with a broken smb protocol
implementation.   This patchset adds support for GetFileAttribute
on _._AFS_IOCTL_._ files to the SMB implementation.

Change-Id: I9d60dc77b7048892eb816e9d1c6e94033711ae7b
Reviewed-on: http://gerrit.openafs.org/7524
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-06-06 08:07:57 -07:00
Jeffrey Altman
6e704d9673 Windows: Introduce AFSFreeExtent()
Consolidate all operations necessary to free an extent in
a single function, AFSFreeExtent().

Change-Id: Id0edd2009136c49cbafb9374e373749d6a906d40
Reviewed-on: http://gerrit.openafs.org/7521
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-06-06 08:07:28 -07:00
Jeffrey Altman
cee6a383d3 Windows: Adjust extent release strategy
All extents were flushed whenever AFSReleaseExtentsWithFlush was
executed.  This included a call at the completion of each
NonCached Read operation which could result in heavy thrashing
as the data would be released prior to it being needed by the
application.

This patchset makes the following adjustments.  First,
AFSReleaseExtentsWithFlush() has been modified to release all
but 1024 extents belonging to the file.  Second, NonCached Reads
only execute AFSReleaseExtentsWithFlush() when there are more
than 4096 extents associated with the file.  Third,
AFSReleaseExtentsWithFlush() now has a 'bReleaseAll' parameter
which is used for calls from AFSCleanup() and AFSFlushExtents()
which need to be able to flush all extents attached to a FCB.

Change-Id: Id8b05f02c59eb46b1881e4d905a511a2597455e8
Reviewed-on: http://gerrit.openafs.org/7520
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-06-06 08:06:44 -07:00
Jeffrey Altman
5335f77bd5 Windows: AFSRedir code cleanup
Remove unnecessary intermediate variables.

Do not drop lock only to reacquire.

Formatting.

Change-Id: I7396047f30ee81755927b90a7b3f990d481d8d3e
Reviewed-on: http://gerrit.openafs.org/7519
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-06-06 08:04:50 -07:00
Jeffrey Altman
ed0eb70f36 Windows: Remove extent from all skip lists
Before freeing the memory for an Extent object, the extent must
be removed from all of the extent skip lists.  Otherwise, the
lists will be corrupted.

Change-Id: I891321477b9f0e194544e9e73dad53473f0865b4
Reviewed-on: http://gerrit.openafs.org/7518
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-06-06 08:01:45 -07:00
Jeffrey Altman
c5f32b3159 Windows: consoldiate NextExtent() implementations
Both AFSExtentsSupport.cpp and AFSIoSupport.cpp provided
NextExtent() implementations.  The AFSExtentsSupport version was
more general.  Use that one for both modules.

Change-Id: I19d17c989b4eadd40dcbb3d6d4186c316c26577e
Reviewed-on: http://gerrit.openafs.org/7517
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-06-06 07:46:37 -07:00
Jeffrey Altman
e94b233869 Windows: Protect against null volp dereference
In cm_RecycleSCache cm_GetVolumeByFID can fail leaving 'volp'
a NULL pointer.  Do not call cm_PutVolume() if cm_GetVolumeByFID
fails.

Change-Id: I57eaf5d40130ecad75a312ef5487cdfa6e7367e3
Reviewed-on: http://gerrit.openafs.org/7506
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-05-31 23:29:41 -07:00
Jeffrey Altman
ce8d0aefd1 Windows: Avoid deadlock on ProcessTree Lock
Change-Id: I2c1be0df615c513eefc27be167d7acda113c06e2
Reviewed-on: http://gerrit.openafs.org/7505
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-05-31 23:29:01 -07:00
Jeffrey Altman
25948ccbc3 Windows: Add CCB NonPaged Resource for synchronization
Add a NonPaged ERESOURCE object to the AFS_CCB structure for
use in synchronizing access to the Ccb->Flags field and the
construction of Directory Snapshots.

Change-Id: I10ecc95619d0e5bd1ca02b044c2f1541a1b9a9f0
Reviewed-on: http://gerrit.openafs.org/7478
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-05-31 16:38:44 -07:00
Jeffrey Altman
fffce9aee4 Windows: Make CCB_FLAGS_DIRECTORY_QUERY_MAPPED consistent
Use CCB_FLAG_DIRECTORY_QUERY_MAPPED instead of
CCB_FLAGS_DIRECTORY_QUERY_MAPPED.

Change-Id: I504b8fda9867a82e5b45d5a1905970a1de11fc27
Reviewed-on: http://gerrit.openafs.org/7477
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-05-31 16:35:55 -07:00
Jeffrey Altman
611436eaec Windows: Remove unused async read/write operations
Removing dead code.

Change-Id: I60f3f098a3afb922143941f59b0146eebf60ac84
Reviewed-on: http://gerrit.openafs.org/7476
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-05-31 16:35:20 -07:00
Jeffrey Altman
06a602bfd4 Windows: Avoid deadlock on VolumeCB->VolumeLock
AFSPrimaryVolumeWorkerThread() holds VolumeCB->VolumeLock SHARED
across the call to AFSCleanupFcb() -> CcPurgeCacheSection().
If a filter driver such as Sophos (savonaccessfilter.sys ->
savonaccesscontrol.sys) triggers an AFSCreate() in response to
the cache section being purged that will force the evaluation of
the file path by AFSLocateNameEntry().  If the path contains a
mount point that requires validation, AFSBuildMountPointTarget()
is called which in turn required the VolumeCB->VolumeLock EXCL.

AFSBuildMountPointTarget() only requires the VolumeCB->VolumeLock
if the VolumeCB->RootFcb == NULL.  That should only be true if
the VolumeCB was allocated by AFSInitVolume() or under very rare
race conditions.

This patchset refactors AFSInitVolume() to ensure that it holds
an extra VolumeCB->VolumeReferenceCount reference.  This reference
is used to assist in the refactoring of AFSBuildRootVolume() and
AFSBuildMountPointTarget() to avoid races with volume root object
invalidation as well as permitting the VolumeCB->VolumeLock to
be ignored in the common case.

Avoiding the acquisition of VolumeCB->VolumeLock during mount
point target evaluation has the additional benefit of reducing
lock contention during path evaluation.

FIXES 130812

Change-Id: Id9b0dcc2bfd91277d522f3724893b60ce4d947f5
Reviewed-on: http://gerrit.openafs.org/7474
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Peter Scott <pscott@kerneldrivers.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
2012-05-31 16:35:01 -07:00
Marc Dionne
02018d729f gtx: remove unused variable numBuffBytes
Commit 9efc255a makes the numBuffBytes variable unnecessary.
Remove it to clear up an "unused but set" warning.

Change-Id: Ifc50c40542e008d76007c76a9ce146fe6ebab4be
Reviewed-on: http://gerrit.openafs.org/7504
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
2012-05-28 20:07:31 -07:00
Marc Dionne
2b33384a4a Linux 3.4: replace end_writeback with clear_inode
end_writeback() is renamed to clear_inode().  Add a configure test
and cope.

Change-Id: Icaf5b6b54d0ee377fabcf0b295d690eaa6b4be5e
Reviewed-on: http://gerrit.openafs.org/7503
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
2012-05-28 20:06:39 -07:00
Garrett Wollman
85626606e9 afsd (FUSE): Avoid a compilation error and spell it "asprintf" not "asprint".
Change-Id: I126e9c57877e4969af68dcc4ec1fd1786ecfbd4e
Reviewed-on: http://gerrit.openafs.org/7479
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Simon Wilkinson <simonxwilkinson@gmail.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-25 04:13:21 -07:00
Andrew Deason
0e81db38b5 afs: Do not QueueVCB before osi_dnlc_purge*
In afs_FlushVCache, when we QueueVCB, we might drop the afs_xvcache
lock (as of 76158df491). The vcache may
still be on the DNLC, so a lookup while xvcache is dropped can cause
someone else to grab a reference to the vcache while it is being
flushed. This can cause panics and failed assertions, since someone
will have a reference to the flushed vcache, which is effectively
freed and many of the structure fields are no longer valid.

So instead, do not call QueueVCB until we have purged the vcache from
the DNLC.

Change-Id: Ia6b51b4a2bb26903346217fbd6fc7d959d87eae7
Reviewed-on: http://gerrit.openafs.org/7430
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:29:04 -07:00
Michael Meffie
7b35b409a4 fix audit init in vl and pr servers
Correct error introduced in commit
0dd7c980ac

Change-Id: I929bb35a6a7070d637f1b332dae50cd182aaf9c5
Reviewed-on: http://gerrit.openafs.org/7447
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:28:38 -07:00
Simon Wilkinson
40123db55e comerr: Don't cast returns from malloc()
malloc() returns a (void *) on all of our current platforms. So,
don't bother casting the return value before assigning it - it is
unnecessary noise.

Change-Id: Idc5f098a20809a5f869c4ea9f3970e598520c0e9
Reviewed-on: http://gerrit.openafs.org/7468
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:25:09 -07:00
Simon Wilkinson
519d2cd5d8 Don't cast returns from malloc()
malloc() returns a (void *) on all of our current platforms. So,
don't bother casting the return value before assigning it - it is
unnecessary noise.

Change-Id: Ie328ebd2d31160bf07b86b760fbb5ce7108a532d
Reviewed-on: http://gerrit.openafs.org/7473
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:24:41 -07:00
Simon Wilkinson
152bda64c6 util: Don't cast returns from malloc()
malloc() returns a (void *) on all of our current platforms. So,
don't bother casting the return value before assigning it - it is
unnecessary noise.

Change-Id: I8287709413fe0e34f417936d1fc64c421fea6d28
Reviewed-on: http://gerrit.openafs.org/7472
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:24:08 -07:00
Simon Wilkinson
1c734bd7e5 update: Don't cast returns from malloc()
malloc() returns a (void *) on all of our current platforms. So,
don't bother casting the return value before assigning it - it is
unnecessary noise.

Change-Id: I6a33ab25b092faa96c764f0a469d052c181344ee
Reviewed-on: http://gerrit.openafs.org/7471
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:19:40 -07:00
Simon Wilkinson
695e3a028e sys: Don't cast returns from malloc()
malloc() returns a (void *) on all of our current platforms. So,
don't bother casting the return value before assigning it - it is
unnecessary noise.

Change-Id: I58b7695e3cf4b99f17869a46e1efca5c7daf6ff7
Reviewed-on: http://gerrit.openafs.org/7470
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:19:18 -07:00
Simon Wilkinson
e33f1dc0b6 xstat: Don't cast returns from malloc()
malloc() returns a (void *) on all of our current platforms. So,
don't bother casting the return value before assigning it - it is
unnecessary noise.

Change-Id: Iaddc6c44041dc77a576f32133b2aa80aefce5cb2
Reviewed-on: http://gerrit.openafs.org/7469
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:18:58 -07:00
Simon Wilkinson
900f7cc5f7 lwp: Don't cast returns from malloc()
malloc() returns a (void *) on all of our current platforms. So,
don't bother casting the return value before assigning it - it is
unnecessary noise.

Change-Id: Ie41f7b831f0ba70796649e2493e014fe44f1c39e
Reviewed-on: http://gerrit.openafs.org/7467
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:08:42 -07:00
Simon Wilkinson
3613d41515 rx: Don't cast returns from allocator
malloc() and osi_Alloc both return (void *). So, don't bother
casting the return value before assigning it - its unnecessary
noise.

Change-Id: I71a66a8fa0d9f49f4833dd77bbb55422e6f20d6f
Reviewed-on: http://gerrit.openafs.org/7466
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
2012-05-24 09:08:18 -07:00