2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-25 13:43:55 +08:00
linux-next/fs/afs
David Howells 27a3ee3a04 afs: Use the vnode ID uniquifier in the cache key not the aux data
AFS vnodes (files) are referenced by a triplet of { volume ID, vnode ID,
uniquifier }.  Currently, kafs is only using the vnode ID as the file key
in the volume fscache index and checking the uniquifier on cookie
acquisition against the contents of the auxiliary data stored in the cache.

Unfortunately, this is subject to a race in which an FS.RemoveFile or
FS.RemoveDir op is issued against the server but the local afs inode isn't
torn down and disposed off before another thread issues something like
FS.CreateFile.  The latter then gets given the vnode ID that just got
removed, but with a new uniquifier and a cookie collision occurs in the
cache because the cookie is only keyed on the vnode ID whereas the inode is
keyed on the vnode ID plus the uniquifier.

Fix this by keying the cookie on the uniquifier in addition to the vnode ID
and dropping the uniquifier from the auxiliary data supplied.

Signed-off-by: David Howells <dhowells@redhat.com>
2018-04-04 13:41:25 +01:00
..
addr_list.c afs: Fix missing cursor clearance 2018-02-06 14:36:54 +00:00
afs_cm.h afs: support the CB.ProbeUuid RPC op 2008-04-29 08:06:26 -07:00
afs_fs.h afs: Overhaul volume and server record caching and fileserver rotation 2017-11-13 15:38:19 +00:00
afs_vl.h afs: Make use of the YFS service upgrade to fully support IPv6 2017-11-13 15:38:19 +00:00
afs.h afs: Overhaul permit caching 2017-11-13 15:38:18 +00:00
cache.c afs: Use the vnode ID uniquifier in the cache key not the aux data 2018-04-04 13:41:25 +01:00
callback.c afs: Overhaul volume and server record caching and fileserver rotation 2017-11-13 15:38:19 +00:00
cell.c sched/wait, fs/afs: Convert wait_on_atomic_t() usage to the new wait_var_event() API 2018-03-20 08:23:19 +01:00
cmservice.c afs: Protect call->state changes against signals 2017-11-13 15:38:21 +00:00
dir.c afs: Support the AFS dynamic root 2018-02-06 14:43:37 +00:00
file.c afs: Trace page dirty/clean 2017-11-13 15:38:21 +00:00
flock.c afs: Fix file locking 2017-11-17 10:06:13 +00:00
fsclient.c afs: convert to new i_version API 2018-01-29 06:42:20 -05:00
inode.c afs: Invalidate cache on server data change 2018-04-04 13:41:25 +01:00
internal.h rxrpc, afs: Use debug_ids rather than pointers in traces 2018-03-27 23:03:00 +01:00
Kconfig fs/afs: remove depends on CONFIG_EXPERIMENTAL 2013-01-21 14:39:04 -08:00
main.c afs: Overhaul volume and server record caching and fileserver rotation 2017-11-13 15:38:19 +00:00
Makefile afs: Overhaul volume and server record caching and fileserver rotation 2017-11-13 15:38:19 +00:00
misc.c afs: Consolidate abort_to_error translators 2017-11-13 15:38:17 +00:00
mntpt.c afs: Support the AFS dynamic root 2018-02-06 14:43:37 +00:00
netdevices.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
proc.c afs: Overhaul volume and server record caching and fileserver rotation 2017-11-13 15:38:19 +00:00
rotate.c afs: Rearrange afs_select_fileserver() a little 2018-02-06 14:43:37 +00:00
rxrpc.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2018-04-03 14:04:18 -07:00
security.c afs: Fix permit refcounting 2017-12-01 11:40:43 +00:00
server_list.c afs: Fix server list handling 2018-02-06 14:36:54 +00:00
server.c sched/wait, fs/afs: Convert wait_on_atomic_t() usage to the new wait_var_event() API 2018-03-20 08:23:19 +01:00
super.c afs: Support the AFS dynamic root 2018-02-06 14:43:37 +00:00
vlclient.c afs: Fix server list handling 2018-02-06 14:36:54 +00:00
volume.c afs: Fix server list handling 2018-02-06 14:36:54 +00:00
write.c afs: Fix missing error handling in afs_write_end() 2018-01-02 10:02:19 +00:00
xattr.c afs: Overhaul volume and server record caching and fileserver rotation 2017-11-13 15:38:19 +00:00