-
Bug
-
Resolution: Unresolved
-
Undefined
-
False
-
-
False
-
None
-
rhel-se-kernel
-
-
The beaker job: https://beaker.engineering.redhat.com/jobs/10813401
This could be reproduce by using the `vm` with low memories always:
The resultoutputfile.log:
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :: bz1804092-rhel7-KMALLOC_MAX_SIZE-reports-wrong-value :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :: [ 19:12:30 ] :: [ LOG ] :: Runnning eval bz1804092, with 3600 seconds timeout :: [ 19:12:30 ] :: [ FAIL ] :: Command 'insmod /mnt/tests/repo.usersys.redhat.com/kernel-tests/general/memory/regression/reg-suit/testcase/module/bz1804092.ko' (Expected 0, got 1) :: [ 19:12:36 ] :: [ FAIL ] :: Command 'rmmod bz1804092' (Expected 0, got 1) :: [ 19:12:36 ] :: [ LOG ] :: Command ended itself, I am not killing it. :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :: Duration: 7s :: Assertions: 0 good, 2 bad :: RESULT: FAIL (bz1804092-rhel7-KMALLOC_MAX_SIZE-reports-wrong-value)
The dmesg logs:
[ 6038.310828] reg-suit bz1804092-rhel7-KMALLOC_MAX_SIZE-reports-wrong-value start
[ 6038.542957] KMALLOC_MAX_ORDER: 13
[ 6038.543901] KMALLOC_MAX_SIZE : 536870912
[ 6038.560140] insmod: page allocation failure: order:13, mode:0x6040c0(GFP_KERNEL|__GFP_COMP), nodemask=(null),cpuset=/,mems_allowed=0
[ 6038.563207] CPU: 0 PID: 3588318 Comm: insmod Kdump: loaded Tainted: PF OE --------- - - 4.18.0-372.142.1.el8_6.aarch64 #1
[ 6038.566274] Hardware name: QEMU KVM Virtual Machine, BIOS 0.0.0 02/06/2015
[ 6038.568024] Call trace:
[ 6038.568650] dump_backtrace+0x0/0x160
[ 6038.569601] show_stack+0x28/0x38
[ 6038.570469] dump_stack+0x5c/0x74
[ 6038.571317] warn_alloc+0x10c/0x190
[ 6038.572215] __alloc_pages_nodemask+0xd30/0xd68
[ 6038.573363] alloc_pages_current+0x90/0x100
[ 6038.574427] kmalloc_order+0x44/0xb0
[ 6038.575351] kmalloc_order_trace+0x40/0x100
[ 6038.576412] mod_init+0x48/0x10000 [bz1804092]
[ 6038.577539] do_one_initcall+0x58/0x1f0
[ 6038.578666] do_init_module+0x64/0x238
[ 6038.579681] load_module+0x13e8/0x1678
[ 6038.580706] __se_sys_finit_module+0xa4/0x100
[ 6038.581882] __arm64_sys_finit_module+0x28/0x38
[ 6038.583048] do_el0_svc+0xb4/0x188
[ 6038.583910] el0_sync_handler+0xf8/0x11c
[ 6038.584909] el0_sync+0x140/0x180
[ 6038.585810] Mem-Info:
[ 6038.586373] active_anon:1640 inactive_anon:6533 isolated_anon:0
active_file:2969 inactive_file:3602 isolated_file:0
unevictable:0 dirty:0 writeback:1
slab_reclaimable:743 slab_unreclaimable:3026
mapped:1134 shmem:60 pagetables:201 bounce:0
free:49492 free_pcp:54 free_cma:0
[ 6038.594655] Node 0 active_anon:104960kB inactive_anon:415488kB active_file:111872kB inactive_file:126336kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:72576kB dirty:0kB writeback:64kB shmem:3840kB shmem_thp: 0kB shmem_pmdmapped: 0kB anon_thp: 0kB writeback_tmp:0kB kernel_stack:357760kB pagetables:12864kB all_unreclaimable? no
[ 6038.602056] Node 0 DMA32 free:1532480kB min:111104kB low:138880kB high:166656kB active_anon:5376kB inactive_anon:22912kB active_file:576kB inactive_file:896kB unevictable:0kB writepending:0kB present:3145728kB managed:2245696kB mlocked:0kB bounce:0kB free_pcp:1920kB local_pcp:0kB free_cma:0kB
[ 6038.608255] lowmem_reserve[]: 0 189 189
[ 6038.609266] Node 0 Normal free:1820480kB min:154880kB low:193600kB high:232320kB active_anon:95872kB inactive_anon:397568kB active_file:117056kB inactive_file:119424kB unevictable:0kB writepending:64kB present:3145728kB managed:3129024kB mlocked:0kB bounce:0kB free_pcp:2112kB local_pcp:0kB free_cma:0kB
[ 6038.617287] lowmem_reserve[]: 0 0 0
[ 6038.618251] Node 0 DMA32: 424*64kB (UM) 368*128kB (UM) 415*256kB (UM) 352*512kB (UM) 245*1024kB (UM) 154*2048kB (UM) 91*4096kB (UM) 19*8192kB (UM) 3*16384kB (UM) 1*32768kB (U) 0*65536kB 0*131072kB 0*262144kB 0*524288kB = 1537280kB
[ 6038.623946] Node 0 Normal: 2417*64kB (UME) 1074*128kB (ME) 679*256kB (ME) 653*512kB (ME) 428*1024kB (ME) 157*2048kB (ME) 47*4096kB (ME) 8*8192kB (ME) 1*16384kB (E) 0*32768kB 0*65536kB 0*131072kB 0*262144kB 0*524288kB = 1834560kB
[ 6038.629464] Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=16777216kB
[ 6038.632611] Node 0 hugepages_total=1 hugepages_free=1 hugepages_surp=0 hugepages_size=524288kB
[ 6038.634868] Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB
[ 6038.636950] 4058 total pagecache pages
[ 6038.637978] 304 pages in swap cache
[ 6038.638920] Swap cache stats: add 205935, delete 205645, find 131490/143599
[ 6038.640638] Free swap = 6151040kB
[ 6038.641462] Total swap = 6295488kB
[ 6038.642415] 98304 pages RAM
[ 6038.643217] 0 pages HighMem/MovableOnly
[ 6038.644259] 14324 pages reserved
[ 6038.645202] 0 pages hwpoisoned
Form the above we can see that the total memories are around 2G. While the test case is trying allocate `512M` memories, but only `4058 pages X 16K(page size) =63M` are available.