Linux filesystem development
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: stable@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	patches@lists.linux.dev, David Howells <dhowells@redhat.com>,
	Marc Dionne <marc.dionne@auristor.com>,
	linux-afs@lists.infradead.org, linux-fsdevel@vger.kernel.org,
	"Christian Brauner (Amutable)" <brauner@kernel.org>
Subject: [PATCH 6.18 1052/1250] afs: Fix missing kunmap in afs_dir_search_bucket()
Date: Thu, 17 Sep 2026 16:14:07 +0100	[thread overview]
Message-ID: <20260917151620.634632291@linuxfoundation.org> (raw)
In-Reply-To: <20260917151551.901433442@linuxfoundation.org>

6.18-stable review patch.  If anyone has any objections, please let me know.

------------------

From: David Howells <dhowells@redhat.com>

commit 950ae84b5cc944fbe27d81806d0b76af765f779c upstream.

Fix afs_dir_search_bucket() to kunmap the block it's using in the "bad:"
path.

Fixes: a5b5beebcf96 ("afs: Use the contained hashtable to search a directory")
Closes: https://sashiko.dev/#/patchset/20260716103030.3065561-1-dhowells%40redhat.com
Signed-off-by: David Howells <dhowells@redhat.com>
Link: https://patch.msgid.link/20260902121024.3328255-2-dhowells@redhat.com
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
cc: linux-fsdevel@vger.kernel.org
cc: stable@vger.kernel.org
Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 fs/afs/dir_search.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

--- a/fs/afs/dir_search.c
+++ b/fs/afs/dir_search.c
@@ -173,12 +173,11 @@ int afs_dir_search_bucket(struct afs_dir
 
 	ret = -ENOENT;
 found:
+bad:
 	if (iter->block) {
 		kunmap_local(iter->block);
 		iter->block = NULL;
 	}
-
-bad:
 	if (ret == -ESTALE)
 		afs_invalidate_dir(iter->dvnode, afs_dir_invalid_iter_stale);
 	_leave(" = %d", ret);



  parent reply	other threads:[~2026-09-17 17:34 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20260917151551.901433442@linuxfoundation.org>
2026-09-17 14:57 ` [PATCH 6.18 0028/1250] hfsplus: fix issue of direct writes beyond end-of-file Greg Kroah-Hartman
2026-09-17 14:58 ` [PATCH 6.18 0103/1250] hfsplus: rework hfsplus_readdir() logic Greg Kroah-Hartman
2026-09-17 15:00 ` [PATCH 6.18 0249/1250] hfs: " Greg Kroah-Hartman
2026-09-17 15:04 ` [PATCH 6.18 0486/1250] cachefiles: Fix double fput Greg Kroah-Hartman
2026-09-17 15:04 ` [PATCH 6.18 0487/1250] netfs: Fix decision whether to disallow write-streaming due to fscache use Greg Kroah-Hartman
2026-09-17 15:06 ` [PATCH 6.18 0582/1250] netfs: Fix barriering when walking subrequest list Greg Kroah-Hartman
2026-09-17 15:07 ` [PATCH 6.18 0642/1250] netfs: Fix unbuffered/DIO write partial transfer error return Greg Kroah-Hartman
2026-09-17 15:07 ` [PATCH 6.18 0643/1250] netfs: Fix error vs transferred passed to ->ki_complete() Greg Kroah-Hartman
2026-09-17 15:07 ` [PATCH 6.18 0644/1250] netfs: Fix i_size update for partial transfer Greg Kroah-Hartman
2026-09-17 15:07 ` [PATCH 6.18 0645/1250] netfs: Fix subreq ref leak Greg Kroah-Hartman
2026-09-17 15:07 ` [PATCH 6.18 0647/1250] cachefiles: Fix potential UAF/KASAN warning Greg Kroah-Hartman
2026-09-17 15:14 ` Greg Kroah-Hartman [this message]
2026-09-17 15:14 ` [PATCH 6.18 1053/1250] afs: Fix double-unmap of directory block Greg Kroah-Hartman
2026-09-17 15:14 ` [PATCH 6.18 1054/1250] afs: Fix incorrect free in candidate cleanup in afs_lookup_server() Greg Kroah-Hartman
2026-09-17 15:14 ` [PATCH 6.18 1055/1250] afs: Clear stale peer app data after address list changes Greg Kroah-Hartman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260917151620.634632291@linuxfoundation.org \
    --to=gregkh@linuxfoundation.org \
    --cc=brauner@kernel.org \
    --cc=dhowells@redhat.com \
    --cc=linux-afs@lists.infradead.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=marc.dionne@auristor.com \
    --cc=patches@lists.linux.dev \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox