Subject: [next-20220405] powerpc booted with 'bad: scheduling from the idle thread!'

From: Abdul Haleem <[email-masked]>
Date: Thu, 14 Apr 2022 23:50:55 +0530

Greeting's

With 5.18.0-rc1-next-20220405 linux-next kernel we are seeing repeated 
call traces while booting my powerpc box

Fallback order for Node 29: 29 0
Fallback order for Node 30: 30 0
Fallback order for Node 31: 31 0
Built 1 zonelists, mobility grouping on.  Total pages: 491040
Policy zone: Normal
Kernel command line: BOOT_IMAGE=/boot/vmlinuz-4.18.0-147.el8.ppc64le 
root=UUID=664cd220-b5e4-4fa4-85fe-4f6b71456669 ro crashkernel=2048M 
biosdevname=0
Unknown kernel command line parameters 
"BOOT_IMAGE=/boot/vmlinuz-4.18.0-147.el8.ppc64le biosdevname=0", will be 
passed to user space.
Dentry cache hash table entries: 4194304 (order: 9, 33554432 bytes, linear)
Inode-cache hash table entries: 2097152 (order: 8, 16777216 bytes, linear)
mem auto-init: stack:off, heap alloc:off, heap free:off
Memory: 29120512K/31457280K available (12992K kernel code, 5568K rwdata, 
4160K rodata, 3904K init, 2453K bss, 2336768K reserved, 0K cma-reserved)
SLUB: HWalign=128, Order=0-3, MinObjects=0, CPUs=24, Nodes=32
trace event string verifier disabled
rcu: Hierarchical RCU implementation.
rcu:     RCU event tracing is enabled.
rcu:     RCU restricting CPUs from NR_CPUS=2048 to nr_cpu_ids=24.
rcu:     RCU debug extended QS entry/exit.
rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
rcu: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=24
NR_IRQS: 512, nr_irqs: 512, preallocated irqs: 16
rcu: srcu_init: Setting srcu_struct sizes based on contention.
random: get_random_u64 called from start_kernel+0x65c/0x8c4 with crng_init=0
time_init: 56 bit decrementer (max: 7fffffffffffff)
clocksource: timebase: mask: 0xffffffffffffffff max_cycles: 
0x761537d007, max_idle_ns: 440795202126 ns
clocksource: timebase mult[1f40000] shift[24] registered
Console: colour dummy device 80x25
printk: console [hvc0] enabled
printk: console [hvc0] enabled
printk: bootconsole [udbg0] disabled
printk: bootconsole [udbg0] disabled
pid_max: default: 32768 minimum: 301
LSM: Security Framework initializing
Yama: becoming mindful.
SELinux:  Initializing.
SELinux: CONFIG_SECURITY_SELINUX_CHECKREQPROT_VALUE is non-zero.  This 
is deprecated and will be rejected in a future kernel release.
SELinux: 
https://github.com/SELinuxProject/selinux-kernel/wiki/DEPRECATE-checkreqprot
bad: scheduling from the idle thread!
CPU: 0 PID: 0 Comm: swapper/0 Not tainted 
5.18.0-rc1-next-20220405-autotest #1
Call Trace:
[c0000000028cfa90] [c0000000006e465c] dump_stack_lvl+0x70/0xa4 (unreliable)
[c0000000028cfad0] [c0000000001b18c4] dequeue_task_idle+0x44/0x80
[c0000000028cfb40] [c000000000190738] dequeue_task+0x48/0x130
[c0000000028cfb80] [c000000000c9a60c] __schedule+0x90c/0xa40
[c0000000028cfc50] [c000000000c9a7a8] schedule+0x68/0x130
[c0000000028cfc80] [c000000000ca30fc] schedule_timeout+0x25c/0x3f0
[c0000000028cfd60] [c00000000022ab0c] msleep+0x3c/0x60
[c0000000028cfd90] [c000000002049cc8] selinux_init+0xa8/0x240
[c0000000028cfe00] [c000000002049330] initialize_lsm+0x6c/0xa4
[c0000000028cfe70] [c000000002049778] security_init+0x360/0x390
[c0000000028cfee0] [c000000002004268] start_kernel+0x7f8/0x8c4
[c0000000028cff90] [c00000000000d29c] start_here_common+0x1c/0x600
bad: scheduling from the idle thread!
CPU: 0 PID: 0 Comm: swapper/0 Not tainted 
5.18.0-rc1-next-20220405-autotest #1
Call Trace:
[c0000000028cfa90] [c0000000006e465c] dump_stack_lvl+0x70/0xa4 (unreliable)
[c0000000028cfad0] [c0000000001b18c4] dequeue_task_idle+0x44/0x80
[c0000000028cfb40] [c000000000190738] dequeue_task+0x48/0x130
[c0000000028cfb80] [c000000000c9a60c] __schedule+0x90c/0xa40
[c0000000028cfc50] [c000000000c9a7a8] schedule+0x68/0x130
[c0000000028cfc80] [c000000000ca30fc] schedule_timeout+0x25c/0x3f0
[c0000000028cfd60] [c00000000022ab0c] msleep+0x3c/0x60
[c0000000028cfd90] [c000000002049cc8] selinux_init+0xa8/0x240
[c0000000028cfe00] [c000000002049330] initialize_lsm+0x6c/0xa4
[c0000000028cfe70] [c000000002049778] security_init+0x360/0x390
[c0000000028cfee0] [c000000002004268] start_kernel+0x7f8/0x8c4
[c0000000028cff90] [c00000000000d29c] start_here_common+0x1c/0x600
bad: scheduling from the idle thread!

Was able to login after 100s of call traces ended

Consistently recreated daily and on today's kernel 5.18.0-rc2-next-20220413

-- 
Regard's

Abdul Haleem
IBM Linux Technology Center