From: Greg Kroah-Hartman Date: Tue, 6 Jan 2026 14:56:26 +0000 (+0100) Subject: 6.12-stable patches X-Git-Tag: v6.12.64~9 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=930060b7c292ab3204f2bc84bfbded6fdba6ee64;p=thirdparty%2Fkernel%2Fstable-queue.git 6.12-stable patches added patches: iomap-allocate-s_dio_done_wq-for-async-reads-as-well.patch misc-rtsx_pci-add-separate-cd-wp-pin-polarity-reversal-support.patch mm-damon-tests-core-kunit-handle-alloc-failres-in-damon_test_new_filter.patch mm-damon-tests-core-kunit-handle-alloc-failures-on-damon_test_split_regions_of.patch mm-damon-tests-vaddr-kunit-handle-alloc-failures-on-damon_do_test_apply_three_regions.patch --- diff --git a/queue-6.12/iomap-allocate-s_dio_done_wq-for-async-reads-as-well.patch b/queue-6.12/iomap-allocate-s_dio_done_wq-for-async-reads-as-well.patch new file mode 100644 index 0000000000..295ed0e81c --- /dev/null +++ b/queue-6.12/iomap-allocate-s_dio_done_wq-for-async-reads-as-well.patch @@ -0,0 +1,46 @@ +From 7fd8720dff2d9c70cf5a1a13b7513af01952ec02 Mon Sep 17 00:00:00 2001 +From: Christoph Hellwig +Date: Mon, 24 Nov 2025 15:00:13 +0100 +Subject: iomap: allocate s_dio_done_wq for async reads as well + +From: Christoph Hellwig + +commit 7fd8720dff2d9c70cf5a1a13b7513af01952ec02 upstream. + +Since commit 222f2c7c6d14 ("iomap: always run error completions in user +context"), read error completions are deferred to s_dio_done_wq. This +means the workqueue also needs to be allocated for async reads. + +Fixes: 222f2c7c6d14 ("iomap: always run error completions in user context") +Reported-by: syzbot+a2b9a4ed0d61b1efb3f5@syzkaller.appspotmail.com +Signed-off-by: Christoph Hellwig +Link: https://patch.msgid.link/20251124140013.902853-1-hch@lst.de +Tested-by: syzbot+a2b9a4ed0d61b1efb3f5@syzkaller.appspotmail.com +Reviewed-by: Dave Chinner +Reviewed-by: Darrick J. Wong +Signed-off-by: Christian Brauner +Signed-off-by: Greg Kroah-Hartman +--- + fs/iomap/direct-io.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +--- a/fs/iomap/direct-io.c ++++ b/fs/iomap/direct-io.c +@@ -674,12 +674,12 @@ __iomap_dio_rw(struct kiocb *iocb, struc + } + goto out_free_dio; + } ++ } + +- if (!wait_for_completion && !inode->i_sb->s_dio_done_wq) { +- ret = sb_init_dio_done_wq(inode->i_sb); +- if (ret < 0) +- goto out_free_dio; +- } ++ if (!wait_for_completion && !inode->i_sb->s_dio_done_wq) { ++ ret = sb_init_dio_done_wq(inode->i_sb); ++ if (ret < 0) ++ goto out_free_dio; + } + + inode_dio_begin(inode); diff --git a/queue-6.12/misc-rtsx_pci-add-separate-cd-wp-pin-polarity-reversal-support.patch b/queue-6.12/misc-rtsx_pci-add-separate-cd-wp-pin-polarity-reversal-support.patch new file mode 100644 index 0000000000..2519785508 --- /dev/null +++ b/queue-6.12/misc-rtsx_pci-add-separate-cd-wp-pin-polarity-reversal-support.patch @@ -0,0 +1,236 @@ +From 807221d3c5ff6e3c91ff57bc82a0b7a541462e20 Mon Sep 17 00:00:00 2001 +From: Ricky Wu +Date: Tue, 12 Aug 2025 14:35:21 +0800 +Subject: misc: rtsx_pci: Add separate CD/WP pin polarity reversal support +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: Ricky Wu + +commit 807221d3c5ff6e3c91ff57bc82a0b7a541462e20 upstream. + +Previously, the Card Detect (CD) and Write Protect (WP) pins shared the +same reverse polarity setting in the configuration space. This meant both +signals were reversed together, without the ability to configure them +individually. + +This patch introduces two new parameters: +sd_cd_reverse_en – enable reverse polarity for the CD pin. +sd_wp_reverse_en – enable reverse polarity for the WP pin. + +With this change, the controller can now support: +1.Reversing both CD and WP pins together (original behavior). +2.Reversing CD and WP pins separately (newly added behavior), if +supported by the configuration space. + +This provides greater flexibility when dealing with devices that have +independent polarity requirements for CD and WP pins. + +Signed-off-by: Ricky Wu +Link: https://lore.kernel.org/r/20250812063521.2427696-1-ricky_wu@realtek.com +Cc: JP Dehollain +Signed-off-by: Greg Kroah-Hartman +--- + drivers/misc/cardreader/rts5227.c | 13 ++++++++++--- + drivers/misc/cardreader/rts5228.c | 12 ++++++++++-- + drivers/misc/cardreader/rts5249.c | 16 +++++++++++++--- + drivers/misc/cardreader/rts5264.c | 20 ++++++++++++++++---- + drivers/misc/cardreader/rts5264.h | 1 + + drivers/misc/cardreader/rtsx_pcr.h | 2 ++ + include/linux/rtsx_pci.h | 2 ++ + 7 files changed, 54 insertions(+), 12 deletions(-) + +--- a/drivers/misc/cardreader/rts5227.c ++++ b/drivers/misc/cardreader/rts5227.c +@@ -79,6 +79,10 @@ static void rts5227_fetch_vendor_setting + pcr->sd30_drive_sel_3v3 = rtsx_reg_to_sd30_drive_sel_3v3(reg); + if (rtsx_reg_check_reverse_socket(reg)) + pcr->flags |= PCR_REVERSE_SOCKET; ++ if (rtsx_reg_check_cd_reverse(reg)) ++ pcr->option.sd_cd_reverse_en = 1; ++ if (rtsx_reg_check_wp_reverse(reg)) ++ pcr->option.sd_wp_reverse_en = 1; + } + + static void rts5227_init_from_cfg(struct rtsx_pcr *pcr) +@@ -127,8 +131,10 @@ static int rts5227_extra_init_hw(struct + /* Configure force_clock_req */ + if (pcr->flags & PCR_REVERSE_SOCKET) + rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0x30, 0x30); +- else +- rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0x30, 0x00); ++ else { ++ rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0x20, option->sd_cd_reverse_en << 5); ++ rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0x10, option->sd_wp_reverse_en << 4); ++ } + + if (CHK_PCI_PID(pcr, 0x522A)) + rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, RTS522A_AUTOLOAD_CFG1, +@@ -350,6 +356,8 @@ void rts5227_init_params(struct rtsx_pcr + pcr->ms_pull_ctl_disable_tbl = rts5227_ms_pull_ctl_disable_tbl; + + pcr->reg_pm_ctrl3 = PM_CTRL3; ++ pcr->option.sd_cd_reverse_en = 0; ++ pcr->option.sd_wp_reverse_en = 0; + } + + static int rts522a_optimize_phy(struct rtsx_pcr *pcr) +@@ -508,5 +516,4 @@ void rts522a_init_params(struct rtsx_pcr + pcr->hw_param.interrupt_en |= SD_OC_INT_EN; + pcr->hw_param.ocp_glitch = SD_OCP_GLITCH_10M; + pcr->option.sd_800mA_ocp_thd = RTS522A_OCP_THD_800; +- + } +--- a/drivers/misc/cardreader/rts5228.c ++++ b/drivers/misc/cardreader/rts5228.c +@@ -84,6 +84,10 @@ static void rtsx5228_fetch_vendor_settin + pcr->sd30_drive_sel_3v3 = rtsx_reg_to_sd30_drive_sel_3v3(reg); + if (rtsx_reg_check_reverse_socket(reg)) + pcr->flags |= PCR_REVERSE_SOCKET; ++ if (rtsx_reg_check_cd_reverse(reg)) ++ pcr->option.sd_cd_reverse_en = 1; ++ if (rtsx_reg_check_wp_reverse(reg)) ++ pcr->option.sd_wp_reverse_en = 1; + } + + static int rts5228_optimize_phy(struct rtsx_pcr *pcr) +@@ -432,8 +436,10 @@ static int rts5228_extra_init_hw(struct + + if (pcr->flags & PCR_REVERSE_SOCKET) + rtsx_pci_write_register(pcr, PETXCFG, 0x30, 0x30); +- else +- rtsx_pci_write_register(pcr, PETXCFG, 0x30, 0x00); ++ else { ++ rtsx_pci_write_register(pcr, PETXCFG, 0x20, option->sd_cd_reverse_en << 5); ++ rtsx_pci_write_register(pcr, PETXCFG, 0x10, option->sd_wp_reverse_en << 4); ++ } + + /* + * If u_force_clkreq_0 is enabled, CLKREQ# PIN will be forced +@@ -720,4 +726,6 @@ void rts5228_init_params(struct rtsx_pcr + hw_param->interrupt_en |= SD_OC_INT_EN; + hw_param->ocp_glitch = SD_OCP_GLITCH_800U; + option->sd_800mA_ocp_thd = RTS5228_LDO1_OCP_THD_930; ++ option->sd_cd_reverse_en = 0; ++ option->sd_wp_reverse_en = 0; + } +--- a/drivers/misc/cardreader/rts5249.c ++++ b/drivers/misc/cardreader/rts5249.c +@@ -60,6 +60,7 @@ static void rtsx_base_fetch_vendor_setti + + pci_read_config_dword(pdev, PCR_SETTING_REG1, ®); + pcr_dbg(pcr, "Cfg 0x%x: 0x%x\n", PCR_SETTING_REG1, reg); ++ pci_write_config_dword(pdev, 0x718, 0x0007C000); + + if (!rtsx_vendor_setting_valid(reg)) { + pcr_dbg(pcr, "skip fetch vendor setting\n"); +@@ -82,6 +83,10 @@ static void rtsx_base_fetch_vendor_setti + pcr->sd30_drive_sel_3v3 = rtsx_reg_to_sd30_drive_sel_3v3(reg); + if (rtsx_reg_check_reverse_socket(reg)) + pcr->flags |= PCR_REVERSE_SOCKET; ++ if (rtsx_reg_check_cd_reverse(reg)) ++ pcr->option.sd_cd_reverse_en = 1; ++ if (rtsx_reg_check_wp_reverse(reg)) ++ pcr->option.sd_wp_reverse_en = 1; + } + + static void rts5249_init_from_cfg(struct rtsx_pcr *pcr) +@@ -254,9 +259,11 @@ static int rts5249_extra_init_hw(struct + /* Configure driving */ + rts5249_fill_driving(pcr, OUTPUT_3V3); + if (pcr->flags & PCR_REVERSE_SOCKET) +- rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0xB0, 0xB0); +- else +- rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0xB0, 0x80); ++ rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0x30, 0x30); ++ else { ++ rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0x20, option->sd_cd_reverse_en << 5); ++ rtsx_pci_add_cmd(pcr, WRITE_REG_CMD, PETXCFG, 0x10, option->sd_wp_reverse_en << 4); ++ } + + rtsx_pci_send_cmd(pcr, CMD_TIMEOUT_DEF); + +@@ -572,6 +579,9 @@ void rts5249_init_params(struct rtsx_pcr + option->ltr_l1off_sspwrgate = LTR_L1OFF_SSPWRGATE_5249_DEF; + option->ltr_l1off_snooze_sspwrgate = + LTR_L1OFF_SNOOZE_SSPWRGATE_5249_DEF; ++ ++ option->sd_cd_reverse_en = 0; ++ option->sd_wp_reverse_en = 0; + } + + static int rts524a_write_phy(struct rtsx_pcr *pcr, u8 addr, u16 val) +--- a/drivers/misc/cardreader/rts5264.c ++++ b/drivers/misc/cardreader/rts5264.c +@@ -473,8 +473,16 @@ static void rts5264_init_from_hw(struct + + pcr->rtd3_en = rts5264_reg_to_rtd3(lval2); + +- if (rts5264_reg_check_reverse_socket(lval2)) +- pcr->flags |= PCR_REVERSE_SOCKET; ++ if (rts5264_reg_check_reverse_socket(lval2)) { ++ if (is_version_higher_than(pcr, PID_5264, RTS5264_IC_VER_B)) ++ pcr->option.sd_cd_reverse_en = 1; ++ else ++ pcr->flags |= PCR_REVERSE_SOCKET; ++ } ++ ++ if (rts5264_reg_check_wp_reverse(lval2) && ++ is_version_higher_than(pcr, PID_5264, RTS5264_IC_VER_B)) ++ pcr->option.sd_wp_reverse_en = 1; + + pci_read_config_dword(pdev, setting_reg1, &lval1); + pcr_dbg(pcr, "Cfg 0x%x: 0x%x\n", setting_reg1, lval1); +@@ -568,8 +576,10 @@ static int rts5264_extra_init_hw(struct + + if (pcr->flags & PCR_REVERSE_SOCKET) + rtsx_pci_write_register(pcr, PETXCFG, 0x30, 0x30); +- else +- rtsx_pci_write_register(pcr, PETXCFG, 0x30, 0x00); ++ else { ++ rtsx_pci_write_register(pcr, PETXCFG, 0x20, option->sd_cd_reverse_en << 5); ++ rtsx_pci_write_register(pcr, PETXCFG, 0x10, option->sd_wp_reverse_en << 4); ++ } + + /* + * If u_force_clkreq_0 is enabled, CLKREQ# PIN will be forced +@@ -883,4 +893,6 @@ void rts5264_init_params(struct rtsx_pcr + hw_param->interrupt_en |= (SD_OC_INT_EN | SD_OVP_INT_EN); + hw_param->ocp_glitch = SD_OCP_GLITCH_800U | SDVIO_OCP_GLITCH_800U; + option->sd_800mA_ocp_thd = RTS5264_LDO1_OCP_THD_1150; ++ option->sd_cd_reverse_en = 0; ++ option->sd_wp_reverse_en = 0; + } +--- a/drivers/misc/cardreader/rts5264.h ++++ b/drivers/misc/cardreader/rts5264.h +@@ -14,6 +14,7 @@ + #define rts5264_reg_to_aspm(reg) \ + (((~(reg) >> 28) & 0x02) | (((reg) >> 28) & 0x01)) + #define rts5264_reg_check_reverse_socket(reg) ((reg) & 0x04) ++#define rts5264_reg_check_wp_reverse(reg) ((reg) & 0x8000) + #define rts5264_reg_to_sd30_drive_sel_1v8(reg) (((reg) >> 22) & 0x03) + #define rts5264_reg_to_sd30_drive_sel_3v3(reg) (((reg) >> 16) & 0x03) + #define rts5264_reg_to_rtd3(reg) ((reg) & 0x08) +--- a/drivers/misc/cardreader/rtsx_pcr.h ++++ b/drivers/misc/cardreader/rtsx_pcr.h +@@ -100,6 +100,8 @@ static inline u8 map_sd_drive(int idx) + #define rtsx_reg_to_sd30_drive_sel_3v3(reg) (((reg) >> 5) & 0x03) + #define rtsx_reg_to_card_drive_sel(reg) ((((reg) >> 25) & 0x01) << 6) + #define rtsx_reg_check_reverse_socket(reg) ((reg) & 0x4000) ++#define rtsx_reg_check_cd_reverse(reg) ((reg) & 0x800000) ++#define rtsx_reg_check_wp_reverse(reg) ((reg) & 0x400000) + #define rts5209_reg_to_aspm(reg) (((reg) >> 5) & 0x03) + #define rts5209_reg_check_ms_pmos(reg) (!((reg) & 0x08)) + #define rts5209_reg_to_sd30_drive_sel_1v8(reg) (((reg) >> 3) & 0x07) +--- a/include/linux/rtsx_pci.h ++++ b/include/linux/rtsx_pci.h +@@ -1160,6 +1160,8 @@ struct rtsx_cr_option { + bool ocp_en; + u8 sd_400mA_ocp_thd; + u8 sd_800mA_ocp_thd; ++ u8 sd_cd_reverse_en; ++ u8 sd_wp_reverse_en; + }; + + /* diff --git a/queue-6.12/mm-damon-tests-core-kunit-handle-alloc-failres-in-damon_test_new_filter.patch b/queue-6.12/mm-damon-tests-core-kunit-handle-alloc-failres-in-damon_test_new_filter.patch new file mode 100644 index 0000000000..4e4de1a2d9 --- /dev/null +++ b/queue-6.12/mm-damon-tests-core-kunit-handle-alloc-failres-in-damon_test_new_filter.patch @@ -0,0 +1,41 @@ +From 28ab2265e9422ccd81e4beafc0ace90f78de04c4 Mon Sep 17 00:00:00 2001 +From: SeongJae Park +Date: Sat, 1 Nov 2025 11:20:07 -0700 +Subject: mm/damon/tests/core-kunit: handle alloc failres in damon_test_new_filter() + +From: SeongJae Park + +commit 28ab2265e9422ccd81e4beafc0ace90f78de04c4 upstream. + +damon_test_new_filter() is assuming all dynamic memory allocation in it +will succeed. Those are indeed likely in the real use cases since those +allocations are too small to fail, but theoretically those could fail. In +the case, inappropriate memory access can happen. Fix it by appropriately +cleanup pre-allocated memory and skip the execution of the remaining tests +in the failure cases. + +Link: https://lkml.kernel.org/r/20251101182021.74868-14-sj@kernel.org +Fixes: 2a158e956b98 ("mm/damon/core-test: add a test for damos_new_filter()") +Signed-off-by: SeongJae Park +Cc: Brendan Higgins +Cc: David Gow +Cc: Kefeng Wang +Cc: [6.6+] +Signed-off-by: Andrew Morton +Signed-off-by: SeongJae Park +Signed-off-by: Greg Kroah-Hartman +--- + mm/damon/tests/core-kunit.h | 2 ++ + 1 file changed, 2 insertions(+) + +--- a/mm/damon/tests/core-kunit.h ++++ b/mm/damon/tests/core-kunit.h +@@ -505,6 +505,8 @@ static void damos_test_new_filter(struct + struct damos_filter *filter; + + filter = damos_new_filter(DAMOS_FILTER_TYPE_ANON, true); ++ if (!filter) ++ kunit_skip(test, "filter alloc fail"); + KUNIT_EXPECT_EQ(test, filter->type, DAMOS_FILTER_TYPE_ANON); + KUNIT_EXPECT_EQ(test, filter->matching, true); + KUNIT_EXPECT_PTR_EQ(test, filter->list.prev, &filter->list); diff --git a/queue-6.12/mm-damon-tests-core-kunit-handle-alloc-failures-on-damon_test_split_regions_of.patch b/queue-6.12/mm-damon-tests-core-kunit-handle-alloc-failures-on-damon_test_split_regions_of.patch new file mode 100644 index 0000000000..79cca8c921 --- /dev/null +++ b/queue-6.12/mm-damon-tests-core-kunit-handle-alloc-failures-on-damon_test_split_regions_of.patch @@ -0,0 +1,68 @@ +From eded254cb69044bd4abde87394ea44909708d7c0 Mon Sep 17 00:00:00 2001 +From: SeongJae Park +Date: Sat, 1 Nov 2025 11:20:02 -0700 +Subject: mm/damon/tests/core-kunit: handle alloc failures on damon_test_split_regions_of() + +From: SeongJae Park + +commit eded254cb69044bd4abde87394ea44909708d7c0 upstream. + +damon_test_split_regions_of() is assuming all dynamic memory allocation in +it will succeed. Those are indeed likely in the real use cases since +those allocations are too small to fail, but theoretically those could +fail. In the case, inappropriate memory access can happen. Fix it by +appropriately cleanup pre-allocated memory and skip the execution of the +remaining tests in the failure cases. + +Link: https://lkml.kernel.org/r/20251101182021.74868-9-sj@kernel.org +Fixes: 17ccae8bb5c9 ("mm/damon: add kunit tests") +Signed-off-by: SeongJae Park +Cc: Brendan Higgins +Cc: David Gow +Cc: Kefeng Wang +Cc: [5.15+] +Signed-off-by: Andrew Morton +Signed-off-by: SeongJae Park +Signed-off-by: Greg Kroah-Hartman +--- + mm/damon/tests/core-kunit.h | 20 ++++++++++++++++++++ + 1 file changed, 20 insertions(+) + +--- a/mm/damon/tests/core-kunit.h ++++ b/mm/damon/tests/core-kunit.h +@@ -278,15 +278,35 @@ static void damon_test_split_regions_of( + struct damon_target *t; + struct damon_region *r; + ++ if (!c) ++ kunit_skip(test, "ctx alloc fail"); + t = damon_new_target(); ++ if (!t) { ++ damon_destroy_ctx(c); ++ kunit_skip(test, "target alloc fail"); ++ } + r = damon_new_region(0, 22); ++ if (!r) { ++ damon_destroy_ctx(c); ++ damon_free_target(t); ++ kunit_skip(test, "region alloc fail"); ++ } + damon_add_region(r, t); + damon_split_regions_of(t, 2); + KUNIT_EXPECT_LE(test, damon_nr_regions(t), 2u); + damon_free_target(t); + + t = damon_new_target(); ++ if (!t) { ++ damon_destroy_ctx(c); ++ kunit_skip(test, "second target alloc fail"); ++ } + r = damon_new_region(0, 220); ++ if (!r) { ++ damon_destroy_ctx(c); ++ damon_free_target(t); ++ kunit_skip(test, "second region alloc fail"); ++ } + damon_add_region(r, t); + damon_split_regions_of(t, 4); + KUNIT_EXPECT_LE(test, damon_nr_regions(t), 4u); diff --git a/queue-6.12/mm-damon-tests-vaddr-kunit-handle-alloc-failures-on-damon_do_test_apply_three_regions.patch b/queue-6.12/mm-damon-tests-vaddr-kunit-handle-alloc-failures-on-damon_do_test_apply_three_regions.patch new file mode 100644 index 0000000000..f1f6d93a18 --- /dev/null +++ b/queue-6.12/mm-damon-tests-vaddr-kunit-handle-alloc-failures-on-damon_do_test_apply_three_regions.patch @@ -0,0 +1,47 @@ +From 2b22d0fcc6320ba29b2122434c1d2f0785fb0a25 Mon Sep 17 00:00:00 2001 +From: SeongJae Park +Date: Sat, 1 Nov 2025 11:20:11 -0700 +Subject: mm/damon/tests/vaddr-kunit: handle alloc failures on damon_do_test_apply_three_regions() + +From: SeongJae Park + +commit 2b22d0fcc6320ba29b2122434c1d2f0785fb0a25 upstream. + +damon_do_test_apply_three_regions() is assuming all dynamic memory +allocation in it will succeed. Those are indeed likely in the real use +cases since those allocations are too small to fail, but theoretically +those could fail. In the case, inappropriate memory access can happen. +Fix it by appropriately cleanup pre-allocated memory and skip the +execution of the remaining tests in the failure cases. + +Link: https://lkml.kernel.org/r/20251101182021.74868-18-sj@kernel.org +Fixes: 17ccae8bb5c9 ("mm/damon: add kunit tests") +Signed-off-by: SeongJae Park +Cc: Brendan Higgins +Cc: David Gow +Cc: Kefeng Wang +Cc: [5.15+] +Signed-off-by: Andrew Morton +Signed-off-by: SeongJae Park +Signed-off-by: Greg Kroah-Hartman +--- + mm/damon/tests/vaddr-kunit.h | 6 ++++++ + 1 file changed, 6 insertions(+) + +--- a/mm/damon/tests/vaddr-kunit.h ++++ b/mm/damon/tests/vaddr-kunit.h +@@ -136,8 +136,14 @@ static void damon_do_test_apply_three_re + int i; + + t = damon_new_target(); ++ if (!t) ++ kunit_skip(test, "target alloc fail"); + for (i = 0; i < nr_regions / 2; i++) { + r = damon_new_region(regions[i * 2], regions[i * 2 + 1]); ++ if (!r) { ++ damon_destroy_target(t); ++ kunit_skip(test, "region alloc fail"); ++ } + damon_add_region(r, t); + } + diff --git a/queue-6.12/series b/queue-6.12/series index eaaa2f2185..b07658a777 100644 --- a/queue-6.12/series +++ b/queue-6.12/series @@ -561,3 +561,8 @@ media-amphion-add-a-frame-flush-mode-for-decoder.patch media-amphion-make-some-vpu_v4l2-functions-static.patch media-amphion-remove-vpu_vb_is_codecconfig.patch vfio-pci-disable-qword-access-to-the-pci-rom-bar.patch +mm-damon-tests-core-kunit-handle-alloc-failures-on-damon_test_split_regions_of.patch +mm-damon-tests-core-kunit-handle-alloc-failres-in-damon_test_new_filter.patch +mm-damon-tests-vaddr-kunit-handle-alloc-failures-on-damon_do_test_apply_three_regions.patch +misc-rtsx_pci-add-separate-cd-wp-pin-polarity-reversal-support.patch +iomap-allocate-s_dio_done_wq-for-async-reads-as-well.patch