From: Greg Kroah-Hartman Date: Mon, 1 Sep 2025 12:15:38 +0000 (+0200) Subject: 5.15-stable patches X-Git-Tag: v5.4.298~24 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2e6d6aa200e8e6136a833a234d54ba6b390f7c48;p=thirdparty%2Fkernel%2Fstable-queue.git 5.15-stable patches added patches: udf-fix-directory-iteration-for-longer-tail-extents.patch --- diff --git a/queue-5.15/series b/queue-5.15/series index 2f9a025e7c..c41761dde1 100644 --- a/queue-5.15/series +++ b/queue-5.15/series @@ -5,6 +5,7 @@ asoc-codecs-tx-macro-correct-tx_macro_component_drv-.patch nfs-fold-nfs_page_group_lock_subrequests-into-nfs_lock_and_join_requests.patch nfs-fix-a-race-when-updating-an-existing-write.patch vhost-net-protect-ubufs-with-rcu-read-lock-in-vhost_net_ubuf_put.patch +udf-fix-directory-iteration-for-longer-tail-extents.patch net-ipv4-fix-regression-in-local-broadcast-routes.patch powerpc-kvm-fix-ifdef-to-remove-build-warning.patch bluetooth-hci_event-detect-if-hci_ev_num_comp_pkts-i.patch diff --git a/queue-5.15/udf-fix-directory-iteration-for-longer-tail-extents.patch b/queue-5.15/udf-fix-directory-iteration-for-longer-tail-extents.patch new file mode 100644 index 0000000000..8c391d441a --- /dev/null +++ b/queue-5.15/udf-fix-directory-iteration-for-longer-tail-extents.patch @@ -0,0 +1,31 @@ +From 1ea1cd11c72d1405a6b98440a9d5ea82dfa07166 Mon Sep 17 00:00:00 2001 +From: Jan Kara +Date: Wed, 25 Jan 2023 11:43:03 +0100 +Subject: udf: Fix directory iteration for longer tail extents + +From: Jan Kara + +commit 1ea1cd11c72d1405a6b98440a9d5ea82dfa07166 upstream. + +When directory's last extent has more that one block and its length is +not multiple of a block side, the code wrongly decided to move to the +next extent instead of processing the last partial block. This led to +directory corruption. Fix the rounding issue. + +Signed-off-by: Jan Kara +Signed-off-by: Greg Kroah-Hartman +--- + fs/udf/directory.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/fs/udf/directory.c ++++ b/fs/udf/directory.c +@@ -171,7 +171,7 @@ static struct buffer_head *udf_fiiter_br + static int udf_fiiter_advance_blk(struct udf_fileident_iter *iter) + { + iter->loffset++; +- if (iter->loffset < iter->elen >> iter->dir->i_blkbits) ++ if (iter->loffset < DIV_ROUND_UP(iter->elen, 1<dir->i_blkbits)) + return 0; + + iter->loffset = 0;