The culprit for the 256 33 page allocations (that causes the fragmentation mentioned in comment #8) is the hisi_sas_v3_hw driver:
[ 21.220867] Call trace: [ 21.223301] dump_backtrace+0x0/0x1b0 [ 21.226948] show_stack+0x24/0x30 [ 21.230251] dump_stack+0x90/0xb4 [ 21.233554] cma_alloc+0x3f4/0x430 [ 21.236942] dma_alloc_from_contiguous+0x70/0x80 [ 21.241544] __dma_direct_alloc_pages+0x14c/0x228 [ 21.246234] dma_direct_alloc_pages+0x48/0xc0 [ 21.250576] dma_direct_alloc+0x50/0x80 [ 21.254397] dma_alloc_attrs+0x94/0x128 [ 21.258218] dmam_alloc_attrs+0x68/0xb8 [ 21.262043] hisi_sas_alloc+0x360/0x538 [hisi_sas_main] [ 21.267257] hisi_sas_shost_alloc_pci+0xfc/0x170 [hisi_sas_v3_hw] [ 21.273337] hisi_sas_v3_probe+0xd8/0x360 [hisi_sas_v3_hw] [ 21.278810] local_pci_probe+0x44/0xa8 [ 21.282544] work_for_cpu_fn+0x20/0x30 [ 21.286279] process_one_work+0x1f0/0x430 [ 21.290274] worker_thread+0x248/0x488 [ 21.294009] kthread+0x134/0x138 [ 21.297223] ret_from_fork+0x10/0x18
I wonder if it'd be possible to adjust this allocation somehow.
The culprit for the 256 33 page allocations (that causes the fragmentation mentioned in comment #8) is the hisi_sas_v3_hw driver:
[ 21.220867] Call trace: 0x0/0x1b0 0x24/0x30 0x90/0xb4 0x3f4/0x430 from_contiguous +0x70/0x80 alloc_pages+ 0x14c/0x228 alloc_pages+ 0x48/0xc0 alloc+0x50/ 0x80 attrs+0x94/ 0x128 attrs+0x68/ 0xb8 alloc+0x360/ 0x538 [hisi_sas_main] shost_alloc_ pci+0xfc/ 0x170 [hisi_sas_v3_hw] v3_probe+ 0xd8/0x360 [hisi_sas_v3_hw] probe+0x44/ 0xa8 cpu_fn+ 0x20/0x30 one_work+ 0x1f0/0x430 thread+ 0x248/0x488 fork+0x10/ 0x18
[ 21.223301] dump_backtrace+
[ 21.226948] show_stack+
[ 21.230251] dump_stack+
[ 21.233554] cma_alloc+
[ 21.236942] dma_alloc_
[ 21.241544] __dma_direct_
[ 21.246234] dma_direct_
[ 21.250576] dma_direct_
[ 21.254397] dma_alloc_
[ 21.258218] dmam_alloc_
[ 21.262043] hisi_sas_
[ 21.267257] hisi_sas_
[ 21.273337] hisi_sas_
[ 21.278810] local_pci_
[ 21.282544] work_for_
[ 21.286279] process_
[ 21.290274] worker_
[ 21.294009] kthread+0x134/0x138
[ 21.297223] ret_from_
I wonder if it'd be possible to adjust this allocation somehow.