diff --git a/patches.suse/bcache-remove-redundant-assignment-to-variable-cur_i-be93.patch b/patches.suse/bcache-remove-redundant-assignment-to-variable-cur_i-be93.patch new file mode 100644 index 0000000..399624b --- /dev/null +++ b/patches.suse/bcache-remove-redundant-assignment-to-variable-cur_i-be93.patch @@ -0,0 +1,41 @@ +From be93825f0e6428c2d3f03a6e4d447dc48d33d7ff Mon Sep 17 00:00:00 2001 +From: Colin Ian King +Date: Mon, 20 Nov 2023 13:24:56 +0800 +Subject: [PATCH] bcache: remove redundant assignment to variable cur_idx +Git-commit: be93825f0e6428c2d3f03a6e4d447dc48d33d7ff +Patch-mainline: v6.7-rc3 +References: git-fixes + +Variable cur_idx is being initialized with a value that is never read, +it is being re-assigned later in a while-loop. Remove the redundant +assignment. Cleans up clang scan build warning: + +drivers/md/bcache/writeback.c:916:2: warning: Value stored to 'cur_idx' +is never read [deadcode.DeadStores] + +Signed-off-by: Colin Ian King +Reviewed-by: Coly Li +Signed-off-by: Coly Li +Link: https://lore.kernel.org/r/20231120052503.6122-4-colyli@suse.de +Signed-off-by: Jens Axboe + +--- + drivers/md/bcache/writeback.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/md/bcache/writeback.c b/drivers/md/bcache/writeback.c +index 24c049067f61..c3e872e0a6f2 100644 +--- a/drivers/md/bcache/writeback.c ++++ b/drivers/md/bcache/writeback.c +@@ -913,7 +913,7 @@ static int bch_dirty_init_thread(void *arg) + int cur_idx, prev_idx, skip_nr; + + k = p = NULL; +- cur_idx = prev_idx = 0; ++ prev_idx = 0; + + bch_btree_iter_init(&c->root->keys, &iter, NULL); + k = bch_btree_iter_next_filter(&iter, &c->root->keys, bch_ptr_bad); +-- +2.35.3 + diff --git a/series.conf b/series.conf index 9173d71..3193a6a 100644 --- a/series.conf +++ b/series.conf @@ -44844,6 +44844,7 @@ patches.suse/HID-multitouch-Add-quirk-for-HONOR-GLO-GXXX-touchpad.patch patches.suse/bcache-avoid-oversize-memory-allocation-by-small-str-baf8.patch patches.suse/bcache-check-return-value-from-btree_node_alloc_repl-7779.patch + patches.suse/bcache-remove-redundant-assignment-to-variable-cur_i-be93.patch patches.suse/md-fix-bi_status-reporting-in-md_end_clone_io-45b4.patch patches.suse/s390-dasd-protect-device-queue-against-concurrent-access.patch patches.suse/nvmet-nul-terminate-the-NQNs-passed-in-the-connect-c.patch