summaryrefslogtreecommitdiffstats
path: root/fs/afs/inode.c
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2020-06-16 01:34:09 +0200
committerDavid Howells <dhowells@redhat.com>2020-06-16 17:26:57 +0200
commit728279a5a1fd9fa9fa268f807391c4d19ad2822c (patch)
tree14449edf632b36d26b200931233b844fdaab9683 /fs/afs/inode.c
parentafs: Remove afs_operation::abort_code (diff)
downloadlinux-728279a5a1fd9fa9fa268f807391c4d19ad2822c.tar.xz
linux-728279a5a1fd9fa9fa268f807391c4d19ad2822c.zip
afs: Fix use of afs_check_for_remote_deletion()
afs_check_for_remote_deletion() checks to see if error ENOENT is returned by the server in response to an operation and, if so, marks the primary vnode as having been deleted as the FID is no longer valid. However, it's being called from the operation success functions, where no abort has happened - and if an inline abort is recorded, it's handled by afs_vnode_commit_status(). Fix this by actually calling the operation aborted method if provided and having that point to afs_check_for_remote_deletion(). Fixes: e49c7b2f6de7 ("afs: Build an abstraction around an "operation" concept") Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'fs/afs/inode.c')
-rw-r--r--fs/afs/inode.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/afs/inode.c b/fs/afs/inode.c
index 70c925978d10..56e60d561f37 100644
--- a/fs/afs/inode.c
+++ b/fs/afs/inode.c
@@ -324,6 +324,7 @@ static const struct afs_operation_ops afs_fetch_status_operation = {
.issue_afs_rpc = afs_fs_fetch_status,
.issue_yfs_rpc = yfs_fs_fetch_status,
.success = afs_fetch_status_success,
+ .aborted = afs_check_for_remote_deletion,
};
/*