Greeting,
FYI, we noticed BUG:unable_to_handle_page_fault_for_address due to commit (built with gcc-11):
commit: f5c1bb2afe93396d41c5cbdcb909b08a75b8dde4 ("x86/calldepth: Add ret/call counting for debug")
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git master
[test failed on linux-next/master e45fb347b630ee76482fe938ba76cf8eab811290]
in testcase: boot
on test machine: qemu-system-x86_64 -enable-kvm -cpu SandyBridge -smp 2 -m 16G
caused below changes (please refer to attached dmesg/kmsg for entire log/backtrace):
+---------------------------------------------+------------+------------+
| | bbaceb189a | f5c1bb2afe |
+---------------------------------------------+------------+------------+
| boot_successes | 18 | 0 |
| boot_failures | 0 | 18 |
| BUG:unable_to_handle_page_fault_for_address | 0 | 18 |
| Oops:#[##] | 0 | 18 |
| RIP:__switch_to_asm | 0 | 18 |
| Kernel_panic-not_syncing:Fatal_exception | 0 | 18 |
+---------------------------------------------+------------+------------+
If you fix the issue, kindly add following tag
| Reported-by: kernel test robot <[email protected]>
| Link: https://lore.kernel.org/oe-lkp/[email protected]
[ 0.550171][ T0] BUG: unable to handle page fault for address: ffffffff06531208
[ 0.551211][ T0] #PF: supervisor write access in kernel mode
[ 0.551990][ T0] #PF: error_code(0x0002) - not-present page
[ 0.552740][ T0] PGD 3228067 P4D 3228067 PUD 0
[ 0.553361][ T0] Oops: 0002 [#1]
[ 0.553809][ T0] CPU: 0 PID: 0 Comm: swapper Tainted: G T 6.1.0-rc1-00051-gf5c1bb2afe93 #1 589e92d2cdaf7cef9f58e91ccf48515357fc867a
[ 0.555479][ T0] RIP: 0010:__switch_to_asm (arch/x86/entry/entry_64.S:265)
[ 0.556144][ T0] Code: c7 c4 10 00 00 00 e8 01 00 00 00 cc e8 01 00 00 00 cc 48 83 c4 10 49 ff cc 75 eb 0f ae e8 48 c7 04 25 10 4e ed 83 ff ff ff ff <65> 48 ff 04 25 08 72 2a 83 41 5f 41 5e 41 5d 41 5c 5b 5d e9 45 ad
All code
========
0: c7 c4 10 00 00 00 mov $0x10,%esp
6: e8 01 00 00 00 callq 0xc
b: cc int3
c: e8 01 00 00 00 callq 0x12
11: cc int3
12: 48 83 c4 10 add $0x10,%rsp
16: 49 ff cc dec %r12
19: 75 eb jne 0x6
1b: 0f ae e8 lfence
1e: 48 c7 04 25 10 4e ed movq $0xffffffffffffffff,0xffffffff83ed4e10
25: 83 ff ff ff ff
2a:* 65 48 ff 04 25 08 72 incq %gs:0xffffffff832a7208 <-- trapping instruction
31: 2a 83
33: 41 5f pop %r15
35: 41 5e pop %r14
37: 41 5d pop %r13
39: 41 5c pop %r12
3b: 5b pop %rbx
3c: 5d pop %rbp
3d: e9 .byte 0xe9
3e: 45 ad rex.RB lods %ds:(%rsi),%eax
Code starting with the faulting instruction
===========================================
0: 65 48 ff 04 25 08 72 incq %gs:0xffffffff832a7208
7: 2a 83
9: 41 5f pop %r15
b: 41 5e pop %r14
d: 41 5d pop %r13
f: 41 5c pop %r12
11: 5b pop %rbx
12: 5d pop %rbp
13: e9 .byte 0xe9
14: 45 ad rex.RB lods %ds:(%rsi),%eax
[ 0.556467][ T0] RSP: 0000:ffff888100277f20 EFLAGS: 00010046
[ 0.556467][ T0] RAX: 0000000000000000 RBX: ffffffff83231a00 RCX: 0000000000000000
[ 0.556467][ T0] RDX: 0000000000000000 RSI: ffff888100270000 RDI: ffffffff83231500
[ 0.556467][ T0] RBP: ffffffff83203e88 R08: 0000000000000000 R09: 0000000000000000
[ 0.556467][ T0] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
[ 0.556467][ T0] R13: ffff888100270000 R14: 0000000000000000 R15: 0000000000000000
[ 0.556467][ T0] FS: 0000000000000000(0000) GS:ffffffff8328a000(0000) knlGS:0000000000000000
[ 0.556467][ T0] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 0.556467][ T0] CR2: ffffffff06531208 CR3: 0000000003227000 CR4: 00000000000406b0
[ 0.556467][ T0] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[ 0.556467][ T0] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
[ 0.556467][ T0] Call Trace:
[ 0.556467][ T0] Modules linked in:
[ 0.556467][ T0] CR2: ffffffff06531208
[ 0.556467][ T0] ---[ end trace 0000000000000000 ]---
[ 0.556467][ T0] RIP: 0010:__switch_to_asm (arch/x86/entry/entry_64.S:265)
[ 0.556467][ T0] Code: c7 c4 10 00 00 00 e8 01 00 00 00 cc e8 01 00 00 00 cc 48 83 c4 10 49 ff cc 75 eb 0f ae e8 48 c7 04 25 10 4e ed 83 ff ff ff ff <65> 48 ff 04 25 08 72 2a 83 41 5f 41 5e 41 5d 41 5c 5b 5d e9 45 ad
All code
========
0: c7 c4 10 00 00 00 mov $0x10,%esp
6: e8 01 00 00 00 callq 0xc
b: cc int3
c: e8 01 00 00 00 callq 0x12
11: cc int3
12: 48 83 c4 10 add $0x10,%rsp
16: 49 ff cc dec %r12
19: 75 eb jne 0x6
1b: 0f ae e8 lfence
1e: 48 c7 04 25 10 4e ed movq $0xffffffffffffffff,0xffffffff83ed4e10
25: 83 ff ff ff ff
2a:* 65 48 ff 04 25 08 72 incq %gs:0xffffffff832a7208 <-- trapping instruction
31: 2a 83
33: 41 5f pop %r15
35: 41 5e pop %r14
37: 41 5d pop %r13
39: 41 5c pop %r12
3b: 5b pop %rbx
3c: 5d pop %rbp
3d: e9 .byte 0xe9
3e: 45 ad rex.RB lods %ds:(%rsi),%eax
Code starting with the faulting instruction
===========================================
0: 65 48 ff 04 25 08 72 incq %gs:0xffffffff832a7208
7: 2a 83
9: 41 5f pop %r15
b: 41 5e pop %r14
d: 41 5d pop %r13
f: 41 5c pop %r12
11: 5b pop %rbx
12: 5d pop %rbp
13: e9 .byte 0xe9
14: 45 ad rex.RB lods %ds:(%rsi),%eax
To reproduce:
# build kernel
cd linux
cp config-6.1.0-rc1-00051-gf5c1bb2afe93 .config
make HOSTCC=gcc-11 CC=gcc-11 ARCH=x86_64 olddefconfig prepare modules_prepare bzImage modules
make HOSTCC=gcc-11 CC=gcc-11 ARCH=x86_64 INSTALL_MOD_PATH=<mod-install-dir> modules_install
cd <mod-install-dir>
find lib/ | cpio -o -H newc --quiet | gzip > modules.cgz
git clone https://github.com/intel/lkp-tests.git
cd lkp-tests
bin/lkp qemu -k <bzImage> -m modules.cgz job-script # job-script is attached in this email
# if come across any failure that blocks the test,
# please remove ~/.lkp and /lkp dir to run from a clean state.
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests