This issue can be reproduced with 5.15.0-1040-realtime as well.
[ 417.611745] ------------[ cut here ]------------ [ 417.611762] WARNING: CPU: 0 PID: 15 at kernel/sched/core.c:3106 set_task_cpu+0x168/0x214 [ 417.611801] Modules linked in: binfmt_misc nls_iso8859_1 hisi_hpre arm_spe_pmu ipmi_ssif ecdh_generic hisi_zip libcurve25519_generic hisi_sec2 hns_roce_hw_v2 hisi_qm ecc authenc uacce acpi_ipmi ipmi_si ipmi_devintf ipmi_msghandler hisi_trng_v2 hisi_uncore_hha_pmu hisi_uncore_ddrc_pmu hisi_uncore_l3c_pmu hisi_uncore_pmu cppc_cpufreq sch_fq_codel dm_multipath scsi_dh_rdac scsi_dh_emc scsi_dh_alua ramoops reed_solomon pstore_blk pstore_zone efi_pstore ip_tables x_tables autofs4 btrfs blake2b_generic zstd_compress raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor xor_neon raid6_pq libcrc32c raid1 raid0 multipath linear ses enclosure mlx5_ib ib_uverbs ib_core hibmc_drm drm_vram_helper drm_ttm_helper ttm i2c_algo_bit drm_kms_helper mlx5_core syscopyarea sysfillrect sysimgblt fb_sys_fops cec rc_core mlxfw realtek crct10dif_ce ghash_ce sha2_ce sha256_arm64 sha1_ce hisi_sas_v3_hw psample hns3 hisi_sas_main tls hclge drm libsas xhci_pci hnae3 xhci_pci_renesas ahci [ 417.612153] scsi_transport_sas spi_dw_mmio gpio_dwapb spi_dw aes_neon_bs aes_neon_blk aes_ce_blk crypto_simd cryptd aes_ce_cipher [ 417.612201] CPU: 0 PID: 15 Comm: ksoftirqd/0 Not tainted 5.15.0-1040-realtime #45-Ubuntu [ 417.612216] Hardware name: Huawei TaiShan 2280 V2/BC82AMDC, BIOS 2280-V2 CS V3.B160.01 01/15/2020 [ 417.612224] pstate: 604000c9 (nZCv daIF +PAN -UAO -TCO -DIT -SSBS BTYPE=--) [ 417.612239] pc : set_task_cpu+0x168/0x214 [ 417.612254] lr : detach_tasks+0x138/0x454 [ 417.612268] sp : ffff80000860ba20 [ 417.612274] x29: ffff80000860ba20 x28: ffff20205bf0d140 x27: ffffcc0780c0a920 [ 417.612295] x26: ffffcc07804794c0 x25: ffffcc07804794c0 x24: ffff203f7fdf5fa8 [ 417.612313] x23: 0000000000000001 x22: ffff203f7fdf54c0 x21: ffffcc0780c07a18 [ 417.612330] x20: 000000000000005f x19: ffff20205bf0d140 x18: 000000000ecb1fd6 [ 417.612347] x17: 0000000006e190ba x16: ffffcc077e8d1eb0 x15: 0000000024632e0a [ 417.612365] x14: ffffcc0780c3a2f8 x13: ffffcc0780c39dc8 x12: 000000000000005f [ 417.612382] x11: 0000000000000004 x10: ffffcc0780c07b50 x9 : ffffcc077e62e7d8 [ 417.612399] x8 : 000000000000005f x7 : ffffffff80000000 x6 : 000000000000005f [ 417.612414] x5 : 00000000000001bb x4 : 0000000000000001 x3 : 0000000000000000 [ 417.612431] x2 : 000000042188ec2c x1 : ffffcc077fc36578 x0 : 0000000000000001 [ 417.612448] Call trace: [ 417.612454] set_task_cpu+0x168/0x214 [ 417.612470] detach_tasks+0x138/0x454 [ 417.612482] load_balance+0x260/0x834 [ 417.612497] rebalance_domains+0x280/0x3f4 [ 417.612512] _nohz_idle_balance.constprop.0.isra.0+0x1ec/0x34c [ 417.612528] run_rebalance_domains+0x84/0xb0 [ 417.612543] __do_softirq+0x170/0x468 [ 417.612554] run_ksoftirqd+0x80/0x150 [ 417.612565] smpboot_thread_fn+0x260/0x2e4 [ 417.612578] kthread+0x158/0x16c [ 417.612594] ret_from_fork+0x10/0x20 [ 417.612610] ---[ end trace 0000000000000002 ]---
This issue can be reproduced with 5.15.0- 1040-realtime as well.
[ 417.611745] ------------[ cut here ]------------ sched/core. c:3106 set_task_ cpu+0x168/ 0x214 generic hisi_sec2 hns_roce_hw_v2 hisi_qm ecc authenc uacce acpi_ipmi ipmi_si ipmi_devintf ipmi_msghandler hisi_trng_v2 hisi_uncore_hha_pmu hisi_uncore_ ddrc_pmu hisi_uncore_l3c_pmu hisi_uncore_pmu cppc_cpufreq sch_fq_codel dm_multipath scsi_dh_rdac scsi_dh_emc scsi_dh_alua ramoops reed_solomon pstore_blk pstore_zone efi_pstore ip_tables x_tables autofs4 btrfs blake2b_generic zstd_compress raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor xor_neon raid6_pq libcrc32c raid1 raid0 multipath linear ses enclosure mlx5_ib ib_uverbs ib_core hibmc_drm drm_vram_helper drm_ttm_helper ttm i2c_algo_bit drm_kms_helper mlx5_core syscopyarea sysfillrect sysimgblt fb_sys_fops cec rc_core mlxfw realtek crct10dif_ce ghash_ce sha2_ce sha256_arm64 sha1_ce hisi_sas_v3_hw psample hns3 hisi_sas_main tls hclge drm libsas xhci_pci hnae3 xhci_pci_renesas ahci 1040-realtime #45-Ubuntu cpu+0x168/ 0x214 tasks+0x138/ 0x454 cpu+0x168/ 0x214 tasks+0x138/ 0x454 0x260/0x834 domains+ 0x280/0x3f4 balance. constprop. 0.isra. 0+0x1ec/ 0x34c domains+ 0x84/0xb0 0x170/0x468 0x80/0x150 thread_ fn+0x260/ 0x2e4 fork+0x10/ 0x20
[ 417.611762] WARNING: CPU: 0 PID: 15 at kernel/
[ 417.611801] Modules linked in: binfmt_misc nls_iso8859_1 hisi_hpre arm_spe_pmu ipmi_ssif ecdh_generic hisi_zip libcurve25519_
[ 417.612153] scsi_transport_sas spi_dw_mmio gpio_dwapb spi_dw aes_neon_bs aes_neon_blk aes_ce_blk crypto_simd cryptd aes_ce_cipher
[ 417.612201] CPU: 0 PID: 15 Comm: ksoftirqd/0 Not tainted 5.15.0-
[ 417.612216] Hardware name: Huawei TaiShan 2280 V2/BC82AMDC, BIOS 2280-V2 CS V3.B160.01 01/15/2020
[ 417.612224] pstate: 604000c9 (nZCv daIF +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[ 417.612239] pc : set_task_
[ 417.612254] lr : detach_
[ 417.612268] sp : ffff80000860ba20
[ 417.612274] x29: ffff80000860ba20 x28: ffff20205bf0d140 x27: ffffcc0780c0a920
[ 417.612295] x26: ffffcc07804794c0 x25: ffffcc07804794c0 x24: ffff203f7fdf5fa8
[ 417.612313] x23: 0000000000000001 x22: ffff203f7fdf54c0 x21: ffffcc0780c07a18
[ 417.612330] x20: 000000000000005f x19: ffff20205bf0d140 x18: 000000000ecb1fd6
[ 417.612347] x17: 0000000006e190ba x16: ffffcc077e8d1eb0 x15: 0000000024632e0a
[ 417.612365] x14: ffffcc0780c3a2f8 x13: ffffcc0780c39dc8 x12: 000000000000005f
[ 417.612382] x11: 0000000000000004 x10: ffffcc0780c07b50 x9 : ffffcc077e62e7d8
[ 417.612399] x8 : 000000000000005f x7 : ffffffff80000000 x6 : 000000000000005f
[ 417.612414] x5 : 00000000000001bb x4 : 0000000000000001 x3 : 0000000000000000
[ 417.612431] x2 : 000000042188ec2c x1 : ffffcc077fc36578 x0 : 0000000000000001
[ 417.612448] Call trace:
[ 417.612454] set_task_
[ 417.612470] detach_
[ 417.612482] load_balance+
[ 417.612497] rebalance_
[ 417.612512] _nohz_idle_
[ 417.612528] run_rebalance_
[ 417.612543] __do_softirq+
[ 417.612554] run_ksoftirqd+
[ 417.612565] smpboot_
[ 417.612578] kthread+0x158/0x16c
[ 417.612594] ret_from_
[ 417.612610] ---[ end trace 0000000000000002 ]---