Greeting,
FYI, we noticed the following commit (built with gcc-9):
commit: 912661015315cefbd60e7a0f7fdada88835cf04d ("printk: add pr_flush()")
https://git.kernel.org/cgit/linux/kernel/git/rt/linux-rt-devel.git linux-5.9.y-rt-rebase
in testcase: boot
on test machine: qemu-system-x86_64 -enable-kvm -cpu SandyBridge -smp 2 -m 8G
caused below changes (please refer to attached dmesg/kmsg for entire log/backtrace):
+-----------------------------+------------+------------+
| | d932e1b1aa | 9126610153 |
+-----------------------------+------------+------------+
| boot_successes | 4 | 0 |
| boot_failures | 0 | 6 |
| BUG:scheduling_while_atomic | 0 | 5 |
| Kernel_panic-not_syncing | 0 | 1 |
+-----------------------------+------------+------------+
If you fix the issue, kindly add following tag
Reported-by: kernel test robot <rong.a.chen(a)intel.com>
[ 18.469688] BUG: scheduling while atomic: lkp-setup-rootf/360/0x00000002
[ 18.470528] Modules linked in: sr_mod cdrom ata_generic intel_rapl_msr
intel_rapl_common crct10dif_pclmul crc32_pclmul bochs_drm crc32c_intel ghash_clmulni_intel
drm_vram_helper ppdev ata_piix drm_ttm_helper ttm joydev parport_pc drm_kms_helper libata
serio_raw syscopyarea sysfillrect parport sysimgblt fb_sys_fops drm i2c_piix4
[ 18.473964] CPU: 0 PID: 360 Comm: lkp-setup-rootf Not tainted
5.9.1-00064-g912661015315ce #1
[ 18.475002] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1
04/01/2014
[ 18.476019] Call Trace:
[ 18.477021] dump_stack+0x57/0x80
[ 18.478096] __schedule_bug.cold+0x47/0x54
[ 18.478609] __schedule+0x6e5/0x8a0
[ 18.479035] ? vprintk_store+0x1f6/0x540
[ 18.479510] schedule+0x6e/0x100
[ 18.479903] schedule_timeout+0x1a0/0x300
[ 18.480392] ? __next_timer_interrupt+0x100/0x100
[ 18.480965] ? msleep+0x25/0x60
[ 18.481350] msleep+0x39/0x60
[ 18.481717] kmsg_dump+0xa5/0x180
[ 18.482143] emergency_restart+0xf/0x20
[ 18.482609] __handle_sysrq.cold+0x43/0x108
[ 18.483119] write_sysrq_trigger+0x3f/0x4a
[ 18.483603] proc_reg_write+0x53/0x80
[ 18.484069] vfs_write+0xe9/0x240
[ 18.484490] ksys_write+0x5f/0xe0
[ 18.484900] do_syscall_64+0x33/0x40
[ 18.485350] entry_SYSCALL_64_after_hwframe+0x44/0xa9
[ 18.485976] RIP: 0033:0x7f51bf57eab4
[ 18.486461] Code: 00 f7 d8 64 89 02 48 c7 c0 ff ff ff ff eb b3 0f 1f 80 00 00 00 00 48
8d 05 89 07 0d 00 8b 00 85 c0 75 13 b8 01 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 54
c3 0f 1f 00 41 54 49 89 d4 55 48 89 f5 53
[ 18.488716] RSP: 002b:00007fff36856fd8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
[ 18.489634] RAX: ffffffffffffffda RBX: 00007f51bf4936c0 RCX: 00007f51bf57eab4
[ 18.490475] RDX: 0000000000000002 RSI: 000055a7f6c6ae40 RDI: 0000000000000001
[ 18.491341] RBP: 0000000000000002 R08: 000055a7f6467d20 R09: 000055a7f6c7c040
[ 18.492188] R10: 0000000000000000 R11: 0000000000000246 R12: 000055a7f6c6ae40
[ 18.493039] R13: 0000000000000001 R14: 0000000000000001 R15: 00007fff36857040
[ 18.500239] printk: console [ttyS0]: printing thread stopped
To reproduce:
# build kernel
cd linux
cp config-5.9.1-00064-g912661015315ce .config
make HOSTCC=gcc-9 CC=gcc-9 ARCH=x86_64 olddefconfig prepare modules_prepare bzImage
git clone
https://github.com/intel/lkp-tests.git
cd lkp-tests
bin/lkp qemu -k <bzImage> job-script # job-script is attached in this email
Thanks,
Rong Chen