general protection fault in rds_ib_get_mr

4 views
Skip to first unread message

syzbot

unread,
Jan 5, 2022, 9:37:28 PM1/5/22
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: bfdef05c8da4 Linux 4.14.261
git tree: linux-4.14.y
console output: https://syzkaller.appspot.com/x/log.txt?x=17f59e07b00000
kernel config: https://syzkaller.appspot.com/x/.config?x=35edfd9cd1fd16dc
dashboard link: https://syzkaller.appspot.com/bug?extid=d50512f5e936db36ad18
compiler: gcc version 10.2.1 20210110 (Debian 10.2.1-6)

Unfortunately, I don't have any reproducer for this issue yet.

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+d50512...@syzkaller.appspotmail.com

kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] PREEMPT SMP KASAN
Modules linked in:
CPU: 0 PID: 25314 Comm: syz-executor.1 Not tainted 4.14.261-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
task: ffff88806e6dc640 task.stack: ffff888066d38000
RIP: 0010:rds_ib_get_mr+0x58/0x200 net/rds/ib_rdma.c:543
RSP: 0018:ffff888066d3fb98 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff888066d3fc68 RCX: ffff8880a36c9c1c
RDX: 000000000000000d RSI: 0000000000000001 RDI: 0000000000000068
RBP: ffff88808f860dc0 R08: 0000000000000001 R09: ffff88809ea92a00
R10: ffff88809ea92a27 R11: 0000000000000000 R12: ffff88809ea92a00
R13: 0000000000000001 R14: ffff8880a36c9c1c R15: 0000000000000000
FS: 00007fc4b443c700(0000) GS:ffff8880ba400000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f0fb50aad38 CR3: 00000000703b8000 CR4: 00000000003406f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
__rds_rdma_map+0x5ab/0xea0 net/rds/rdma.c:271
rds_get_mr_for_dest+0xe3/0x130 net/rds/rdma.c:357
rds_setsockopt+0x337/0x750 net/rds/af_rds.c:347
SYSC_setsockopt net/socket.c:1865 [inline]
SyS_setsockopt+0x110/0x1e0 net/socket.c:1844
do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7fc4b5b08e99
RSP: 002b:00007fc4b443c168 EFLAGS: 00000246 ORIG_RAX: 0000000000000036
RAX: ffffffffffffffda RBX: 00007fc4b5c1c100 RCX: 00007fc4b5b08e99
RDX: 0000000000000007 RSI: 0000000000000114 RDI: 0000000000000003
RBP: 00007fc4b5b62ff1 R08: 00000000000000a0 R09: 0000000000000000
R10: 0000000020000140 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fff95e8174f R14: 00007fc4b443c300 R15: 0000000000022000
Code: fa 48 c1 ea 03 80 3c 02 00 0f 85 9e 01 00 00 4c 8b bd c0 04 00 00 48 b8 00 00 00 00 00 fc ff df 49 8d 7f 68 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 6e 01 00 00 48 b8 00 00 00 00 00 fc ff df 4d
RIP: rds_ib_get_mr+0x58/0x200 net/rds/ib_rdma.c:543 RSP: ffff888066d3fb98
---[ end trace 836aa12f84c0e163 ]---
----------------
Code disassembly (best guess):
0: fa cli
1: 48 c1 ea 03 shr $0x3,%rdx
5: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1)
9: 0f 85 9e 01 00 00 jne 0x1ad
f: 4c 8b bd c0 04 00 00 mov 0x4c0(%rbp),%r15
16: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax
1d: fc ff df
20: 49 8d 7f 68 lea 0x68(%r15),%rdi
24: 48 89 fa mov %rdi,%rdx
27: 48 c1 ea 03 shr $0x3,%rdx
* 2b: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1) <-- trapping instruction
2f: 0f 85 6e 01 00 00 jne 0x1a3
35: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax
3c: fc ff df
3f: 4d rex.WRB


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

syzbot

unread,
Jan 5, 2022, 9:52:21 PM1/5/22
to syzkaller...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: bfdef05c8da4 Linux 4.14.261
git tree: linux-4.14.y
console output: https://syzkaller.appspot.com/x/log.txt?x=17a8401bb00000
kernel config: https://syzkaller.appspot.com/x/.config?x=35edfd9cd1fd16dc
dashboard link: https://syzkaller.appspot.com/bug?extid=d50512f5e936db36ad18
compiler: gcc version 10.2.1 20210110 (Debian 10.2.1-6)
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=17d4c003b00000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=16d7e65db00000

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+d50512...@syzkaller.appspotmail.com

kasan: CONFIG_KASAN_INLINE enabled
kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] PREEMPT SMP KASAN
Modules linked in:
CPU: 0 PID: 7974 Comm: syz-executor184 Not tainted 4.14.261-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
task: ffff8880974442c0 task.stack: ffff8880964a8000
RIP: 0010:rds_ib_get_mr+0x58/0x200 net/rds/ib_rdma.c:543
RSP: 0018:ffff8880964afb98 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff8880964afc68 RCX: ffff88809761351c
RDX: 000000000000000d RSI: 0000000000000001 RDI: 0000000000000068
RBP: ffff888094ab33c0 R08: 0000000000000001 R09: ffff8880b4997c00
R10: ffff8880b4997c27 R11: 0000000000000000 R12: ffff8880b4997c00
R13: 0000000000000001 R14: ffff88809761351c R15: 0000000000000000
FS: 00007fed299a4700(0000) GS:ffff8880ba400000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fed299a4718 CR3: 00000000ab302000 CR4: 00000000003406f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
__rds_rdma_map+0x5ab/0xea0 net/rds/rdma.c:271
rds_get_mr_for_dest+0xe3/0x130 net/rds/rdma.c:357
rds_setsockopt+0x337/0x750 net/rds/af_rds.c:347
SYSC_setsockopt net/socket.c:1865 [inline]
SyS_setsockopt+0x110/0x1e0 net/socket.c:1844
do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7fed29a12d09
RSP: 002b:00007fed299a4318 EFLAGS: 00000246 ORIG_RAX: 0000000000000036
RAX: ffffffffffffffda RBX: 00007fed29a9b3f8 RCX: 00007fed29a12d09
RDX: 0000000000000007 RSI: 0000000000000114 RDI: 0000000000000003
RBP: 00007fed29a9b3f0 R08: 00000000000000a0 R09: 0000000000000000
R10: 0000000020000140 R11: 0000000000000246 R12: 00007fed29a9b3fc
R13: 00007fff1837a58f R14: 00007fed299a4400 R15: 0000000000022000
Code: fa 48 c1 ea 03 80 3c 02 00 0f 85 9e 01 00 00 4c 8b bd c0 04 00 00 48 b8 00 00 00 00 00 fc ff df 49 8d 7f 68 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 6e 01 00 00 48 b8 00 00 00 00 00 fc ff df 4d
RIP: rds_ib_get_mr+0x58/0x200 net/rds/ib_rdma.c:543 RSP: ffff8880964afb98
---[ end trace 1dcc0a50232ae05d ]---
Reply all
Reply to author
Forward
0 new messages