[PATCH net v10 13/14] afs: Fix uncleared op->call pointer
From: David Howells
Date: Mon Sep 14 2026 - 13:46:41 EST
Fix uncleared op->call pointer in afs_wait_for_operation() lest server
rotation occur and try to reuse the call. Note that afs_read_receive()
already does this. Note that this was spotted by AI code inspection rather
than by hitting an issue.
Fixes: 6f2ff7e89bd0 ("afs: Don't put afs_call in afs_wait_for_call_to_complete()")
Link: https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20260907113743.1453210-1-dhowells%40redhat.com
Signed-off-by: David Howells <dhowells@xxxxxxxxxx>
cc: Marc Dionne <marc.dionne@xxxxxxxxxxxx>
cc: Eric Dumazet <edumazet@xxxxxxxxxx>
cc: "David S. Miller" <davem@xxxxxxxxxxxxx>
cc: Jakub Kicinski <kuba@xxxxxxxxxx>
cc: Paolo Abeni <pabeni@xxxxxxxxxx>
cc: Simon Horman <horms@xxxxxxxxxx>
cc: linux-afs@xxxxxxxxxxxxxxxxxxx
---
fs/afs/fs_operation.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/fs/afs/fs_operation.c b/fs/afs/fs_operation.c
index 20801b29521d..94fa65548d71 100644
--- a/fs/afs/fs_operation.c
+++ b/fs/afs/fs_operation.c
@@ -297,6 +297,7 @@ void afs_wait_for_operation(struct afs_operation *op)
op->call_error = op->call->error;
op->call_responded = op->call->responded;
afs_put_call(op->call);
+ op->call = NULL;
}
}