linux-yocto/fs/afs
David Howells 0e8ed2d66d afs: Give an afs_server object a ref on the afs_cell object it points to
[ Upstream commit 1f0fc3374f ]

Give an afs_server object a ref on the afs_cell object it points to so that
the cell doesn't get deleted before the server record.

Whilst this is circular (cell -> vol -> server_list -> server -> cell), the
ref only pins the memory, not the lifetime as that's controlled by the
activity counter.  When the volume's activity counter reaches 0, it
detaches from the cell and discards its server list; when a cell's activity
counter reaches 0, it discards its root volume.  At that point, the
circularity is cut.

Fixes: d2ddc776a4 ("afs: Overhaul volume and server record caching and fileserver rotation")
Signed-off-by: David Howells <dhowells@redhat.com>
cc: Marc Dionne <marc.dionne@auristor.com>
cc: Simon Horman <horms@kernel.org>
cc: linux-afs@lists.infradead.org
Link: https://patch.msgid.link/20250218192250.296870-6-dhowells@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-03-07 18:25:29 +01:00
..
addr_list.c afs: Remove the unimplemented afs_cmp_addr_list() 2024-01-01 16:37:26 +00:00
addr_prefs.c afs: Fix merge preference rule failure condition 2025-01-23 17:22:57 +01:00
afs_cm.h
afs_fs.h
afs_vl.h afs: Fix the maximum cell name length 2025-01-17 13:40:43 +01:00
afs.h afs: Fix the maximum cell name length 2025-01-17 13:40:43 +01:00
callback.c afs: Overhaul invalidation handling to better support RO volumes 2024-01-01 16:37:27 +00:00
cell.c afs: Overhaul invalidation handling to better support RO volumes 2024-01-01 16:37:27 +00:00
cmservice.c rxrpc, afs: Allow afs to pin rxrpc_peer objects 2023-12-24 15:22:50 +00:00
dir_edit.c afs: Fix missing subdir edit when renamed between parent dirs 2024-10-24 13:50:27 +02:00
dir_silly.c afs: Simplify error handling 2023-12-24 15:22:53 +00:00
dir.c afs: Fix EEXIST error returned from afs_rmdir() to be ENOTEMPTY 2025-02-08 09:56:50 +01:00
dynroot.c afs: Remove afs_dynroot_d_revalidate() as it is redundant 2024-01-22 22:30:14 +00:00
file.c afs: Fix missing wire-up of afs_retry_request() 2024-09-27 18:29:19 +02:00
flock.c afs: adapt to breakup of struct file_lock 2024-02-05 13:11:42 +01:00
fs_operation.c afs: Fix the setting of the server responding flag 2024-09-27 18:29:20 +02:00
fs_probe.c afs: Fix possible infinite loop with unresponsive servers 2024-09-27 18:29:19 +02:00
fsclient.c netfs: Speed up buffered reading 2024-09-12 12:20:41 +02:00
inode.c afs: Fix post-setattr file edit to do truncation correctly 2024-08-24 16:09:16 +02:00
internal.h afs: Fix cleanup of immediately failed async calls 2025-02-08 09:56:50 +01:00
Kconfig
main.c afs: Fix ignored callbacks over ipv4 2024-02-20 09:51:21 +01:00
Makefile afs: Move the vnode/volume validity checking code into its own file 2024-01-01 16:37:27 +00:00
misc.c afs: Simplify error handling 2023-12-24 15:22:53 +00:00
mntpt.c afs: Don't cross .backup mountpoint from backup volume 2024-05-25 14:02:40 +02:00
proc.c afs: Fix missing/incorrect unlocking of RCU read lock 2024-01-22 22:30:38 +00:00
protocol_afs.h
protocol_uae.h
protocol_yfs.h
rotate.c afs: Fix possible infinite loop with unresponsive servers 2024-09-27 18:29:19 +02:00
rxrpc.c afs: Fix cleanup of immediately failed async calls 2025-02-08 09:56:50 +01:00
security.c
server_list.c afs: Fix the server_list to unuse a displaced server rather than putting it 2025-03-07 18:25:29 +01:00
server.c afs: Give an afs_server object a ref on the afs_cell object it points to 2025-03-07 18:25:29 +01:00
super.c vfs-6.8.netfs 2024-01-19 09:10:23 -08:00
validation.c afs: Use alternative invalidation to using launder_folio 2024-05-01 18:07:34 +01:00
vl_alias.c afs: Fix the maximum cell name length 2025-01-17 13:40:43 +01:00
vl_list.c afs: Dispatch vlserver probes in priority order 2024-01-01 16:37:27 +00:00
vl_probe.c afs: Keep a record of the current fileserver endpoint state 2024-01-01 16:37:27 +00:00
vl_rotate.c afs: Add some more info to /proc/net/afs/servers 2024-01-01 16:36:58 +00:00
vlclient.c afs: Fix the maximum cell name length 2025-01-17 13:40:43 +01:00
volume.c afs: Increase buffer size in afs_update_volume_status() 2024-02-20 09:51:21 +01:00
write.c netfs: Move max_len/max_nr_segs from netfs_io_subrequest to netfs_io_stream 2024-09-05 11:00:41 +02:00
xattr.c afs: Add __counted_by for struct afs_acl and use struct_size() 2023-12-01 09:51:43 -08:00
xdr_fs.h afs: Fix directory format encoding struct 2025-02-08 09:56:50 +01:00
yfsclient.c afs: Fix the fallback handling for the YFS.RemoveFile2 RPC call 2025-02-08 09:56:53 +01:00