libswap: Fix tst_max_swapfiles() for c9s-latest
PATCH 1/1 libswap: Fix tst_max_swapfiles() for c9s-latest
Code change (merged in -441.el9) removes the CONFIG_PTE_MARKER, so that configuration impacts the 'SWP_PTE_MAKER_NUM' judgement inside that testcase, so we need to do is adjust the swapon03 testcase to get correct numbers of MAX_SWAPFILES to test.
--- libs/libltpswap/libswap.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
libs/libltpswap/libswap.c +7 -1
@@ -255,6 +255,12 @@ int tst_max_swapfiles(void) { NULL, NULL}, }; +struct tst_kern_exv kvers_marker_migration2[] = { +/* RHEL9 kernel has patch ca92ea3dc5a since 5.14.0-441 */ + {"RHEL9" ,"5.14.0-441" }, + {NULL ,NULL }, + }; +struct tst_kern_exv kvers_device[] = {/* SLES12-SP4 has patch 5042db43cc26 since 4.12.14-5.5 */ { "SLES", "4.12.14-5.5" },
@@ -285,7 +291,7 @@ int tst_max_swapfiles(void)if ((marker.choice =='y' &&tst_kvercmp2 (5 ,19 ,0 , kvers_marker_migration) >=0 ) - ||tst_kvercmp (6 ,2 ,0 ) >=0 ) { + ||tst_kvercmp2 (6 ,2 ,0 , kvers_marker_migration2) >=0 ) { swp_pte_marker_num =1 ; }
Signature · 5 lines
2.45.2 -- Mailing list info: https://lists.linux.it/listinfo/ltp
Hi Li,
Quoted 4 lines
Code change (merged in -441.el9) removes the
CONFIG_PTE_MARKER, so that configuration impacts the 'SWP_PTE_MAKER_NUM' judgement inside that testcase, so we need to do is adjust the swapon03 testcase to get correct numbers ofMAX_SWAPFILESto test.
Kind regards,
Petr
Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
Quoted 9 lines · Petr Vorel
Hi Li,
Quoted 4 lines
Code change (merged in -441.el9) removes the
CONFIG_PTE_MARKER, so that configuration impacts the 'SWP_PTE_MAKER_NUM' judgement inside that testcase, so we need to do is adjust the swapon03 testcase to get correct numbers ofMAX_SWAPFILESto test.Acked-by Petr Vorel <[email protected]>
Patch applied, thank you so much Petr.
Signature · 5 lines
Regards, Li Wang -- Mailing list info: https://lists.linux.it/listinfo/ltp