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 <shadow@dementia.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
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 <shadow@dementia.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
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 <shadow@dementia.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
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 <jaltman@openafs.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Commit eb8e55bba7 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 <marc.c.dionne@gmail.com>
Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Commit 50f6529cf1 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 <alistair.ferguson@mac.com>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <marc.c.dionne@gmail.com>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <marc.c.dionne@gmail.com>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Reviewed-by: Russ Allbery <rra@stanford.edu>
Tested-by: Russ Allbery <rra@stanford.edu>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
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 <summatusmentis@gmail.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
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 <shadow@dementia.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
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 <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
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 <jaltman@openafs.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
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 <adeason@sinenomine.net>
Reviewed-by: Marc Dionne <marc.c.dionne@gmail.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <marc.c.dionne@gmail.com>
Tested-by: Marc Dionne <marc.c.dionne@gmail.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
*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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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. 5f720faab9 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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
f6ce2af008 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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <sxw@inf.ed.ac.uk>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <rra@stanford.edu>
Reviewed-by: Simon Wilkinson <sxw@inf.ed.ac.uk>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Commit eb8e55bba7 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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <tkula@umich.edu>
Tested-by: Russ Allbery <rra@stanford.edu>
Reviewed-by: Russ Allbery <rra@stanford.edu>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
With commit cfce015ead (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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <marc.c.dionne@gmail.com>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <sxw@inf.ed.ac.uk>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <adeason@sinenomine.net>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
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 <marc.c.dionne@gmail.com>
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>