afs: Fix the dynamic root's d_delete to always delete unused dentries
authorDavid Howells <dhowells@redhat.com>
Mon, 11 Dec 2023 15:08:57 +0000 (15:08 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 1 Jan 2024 12:42:33 +0000 (12:42 +0000)
commit9ff7ae01a0c03d89a435f6ebe046d638411838a8
tree124b8e0c35120ef8e49cdae7f6fae3911bfc9cd2
parent337ca88fde4da0f0fbdf1f24c6db2267e5ac54b9
afs: Fix the dynamic root's d_delete to always delete unused dentries

[ Upstream commit 71f8b55bc30e82d6355e07811213d847981a32e2 ]

Fix the afs dynamic root's d_delete function to always delete unused
dentries rather than only deleting them if they're positive.  With things
as they stand upstream, negative dentries stemming from failed DNS lookups
stick around preventing retries.

Fixes: 66c7e1d319a5 ("afs: Split the dynroot stuff out and give it its own ops tables")
Signed-off-by: David Howells <dhowells@redhat.com>
Tested-by: Markus Suvanto <markus.suvanto@gmail.com>
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/afs/dynroot.c