based on comments and suggestion from Srikanth Vishwanathan <vsrikanth@in.ibm.com>
avoid deadlock. send back variable length list. allocate what we need to, and
be care to clean up after ourselves if there's an error. whether this
should be variable length is arguable but it's pretty clear no one was using
this before.
Delay calling afs_ProcessFS() and upgrading the shared vcache lock
until after the dcache locks have been released, to obey lock ordering
and avoid deadlock.
Garry Zacheiss [Wed, 29 May 2002 21:59:51 +0000 (21:59 +0000)]
uuencode binary files used by the test suite (KeyFile and sample kaserver
database). Keeping binary files in CVS is annoying, and this way "cvs rdiff"
will work again.
But then, why not just allocate a whole identP and be happy. A afsUUID
is not that bloted (16 bytes) so I can't see why way this is
chosen. 20 bytes will probably be allocated on 32 bit platforms for
the whole struct Identity.
Derek Atkins [Wed, 15 May 2002 21:04:15 +0000 (21:04 +0000)]
osi_linux_unmask() needs to explicitly flush_signals() before calling
recalc_sigpending(), otherwise recent kernels don't appear to deliver
new instances of any signals already received.
Revert back to using SIGKILL at shutdown time, but use SIGKILL instead of
explicitly using signal 9, because abstraction is your friend.
liberal debugging code and hammering produced a failure where newslot was
actually walking on another call to newslot because the bufferlock was
being dropped before newslot incremented lockers on the buffer it
was allocating, allowing someone else to come along and also think they
could allocate it.
by holding the bufferlock just a little longer we avoid this
doesn't fix any problem that i can find, but results in ihandles not
having thousands of bogus references (and may fix problems if refcnt were to wrap)
Garry Zacheiss [Tue, 7 May 2002 21:01:27 +0000 (21:01 +0000)]
Use vsu_ExtractName() to get the RW volume name before doing the vid lookup
for addsite and remsite operations, since "vos addsite foo.bar.readonly" is
such a common thinko.
Undo need-prototype-for-osi-dnlc-lookup-20020503, as it created
double inclusion of afs_osidnlc.h.
An equivalent patch was already present in the mainline as part of
linux-dcache-inconsistency-fix-20020115, but its pullup to the stable
branch, STABLE12-linux-dcache-inconsistency-fix-20020120, was oddly
missing this particular part of the diff.
this does fix some potential problems, even if none of them are the
CopyOnWrite problem. basically, ih_reallyclose() could reinsert a now-unref'd
fd handle into the wrong list when cleaning up, and this cleans up the code
considerably.
Don't spawn a separate kernel thread for rx kernel listener under
Solaris, but instead just use the afsd fork for the listener. Use
of newproc() is deprecated, according to Frank.Batschulat@Sun.COM.
Make h_Lookup_r return the host held, and ensure that it's not
deleted at that point; otherwise, the host may be deleted by
another thread between a call to h_Lookup_r and the time when
we actually get around to h_Hold'ing it.
Initial fakestat support (fake mountpoint directory attributes).
Useful for quickly stat'ing everything under /afs, for instance.
Reasonably tested on Solaris, and appears to work on Linux too.
Enable with 'afsd -fakestat'.
This adds /useexisting to use current AFS creds, bypassing the initial authentication
dialog box. It's useful if you're not running kaserver (i.e. if you've moved
over to kerberos 5) and can't authenticate again by the normal AFS means.
based on patch by Srikanth Vishwanathan and modifications based on suggestions
from Ted Anderson applicable to this part of the code.
the original theory we operated under, namely that negative dentries
could be banished entirely, causes file creation to stop working
under linux 2.2 kernels. reverting that change means we have to deal with
these negative dentries, and Srikanth's original suggested patch does so.
even though right now a vnode and an inode are basically but not exactly
the same, part of the usefulness of this change is the ability to convert
to inodes linked from vcaches later. make the macros fit with this view of the
fture
Verify that name lengths are at most AFSNAMEMAX and symlink
contents are at most AFSPATHMAX (notably, the Linux kernel
doesn't check this for us); bug report by nneul@umr.edu.
prototyping caught this; the usage is inconsistent with other cases and
i believe this is the correct fix. it's not clear to me why we weren't seeing
problems from this, though
to export syscalls as functions you need the magic exp file
====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================
and also reinstall them for the user cache manager library
Allocate the exact string length needed for the string in symlink
contents, rather than assuming that symlink data never contains
nulls (or that it's of the length we expect).
drop locks when rxi_Alloc fails, and rework SRXAFSCB_GetCellServDB to use
afs_GetCellByIndex. He suggested same for GetLocalCell, and as long as cell 1
and not CPrimary is the local cell indicator that works, but I left that part
of the code as is for now.
based on report from mattiasa@e.kth.se who has the following feedback from
lha@e.kth.se:
Patch from Love to make filserver not loop on MUTEX_ENTER() in
rx_SetSpecific()
The problem is that on 2.4 the 'code' variable is over-written during
the path walk, such that by the time it's checking if the inode
exists, code is already '0'. But if the inode does not exist, code
should be ENOENT to show that the file does not exist.