[v5.15] WARNING in iov_iter_revert

0 views
Skip to first unread message

syzbot

unread,
Jun 28, 2023, 5:07:06 AM6/28/23
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: f67653019430 Linux 5.15.118
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=16ecf6e0a80000
kernel config: https://syzkaller.appspot.com/x/.config?x=717fa62bb7f0fe9
dashboard link: https://syzkaller.appspot.com/bug?extid=fc9f9c0005eaccca8f3a
compiler: Debian clang version 15.0.7, GNU ld (GNU Binutils for Debian) 2.35.2
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1636df50a80000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=17f091bf280000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/d21188fbe046/disk-f6765301.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/f0c688e23e63/vmlinux-f6765301.xz
kernel image: https://storage.googleapis.com/syzbot-assets/eca85b3bf72c/bzImage-f6765301.xz
mounted in repro: https://storage.googleapis.com/syzbot-assets/7c33bb981a6c/mount_0.gz

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

Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 11 15 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffe390acd58 EFLAGS: 00000246 ORIG_RAX: 0000000000000028
RAX: ffffffffffffffda RBX: 0000000000000002 RCX: 00007fbd24f63a09
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000004
RBP: 00007ffe390acd80 R08: 0000000000000002 R09: 00007ffe390acd90
R10: 0000000100000000 R11: 0000000000000246 R12: 0000000000000005
R13: 00007ffe390acdc0 R14: 00007ffe390acda0 R15: 0000000000000001
</TASK>
------------[ cut here ]------------
WARNING: CPU: 1 PID: 3507 at lib/iov_iter.c:1097 iov_iter_revert+0x36e/0x6d0
Modules linked in:
CPU: 1 PID: 3507 Comm: syz-executor170 Not tainted 5.15.118-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023
RIP: 0010:iov_iter_revert+0x36e/0x6d0 lib/iov_iter.c:1097
Code: 80 3c 30 00 48 8b 5c 24 28 74 08 48 89 df e8 79 a5 c4 fd 4c 89 2b 48 83 c4 50 5b 41 5c 41 5d 41 5e 41 5f 5d c3 e8 e2 48 7b fd <0f> 0b eb e8 4d 8d 75 18 4c 89 f0 48 c1 e8 03 80 3c 28 00 74 08 4c
RSP: 0018:ffffc90002d4f820 EFLAGS: 00010293
RAX: ffffffff8404b16e RBX: ffffffffffff1000 RCX: ffff888024dfbb80
RDX: 0000000000000000 RSI: ffffffffffff1000 RDI: 000000007ffff000
RBP: 1ffff920005a9f3b R08: ffffffff8404ae39 R09: ffff88801ac3100a
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff920005a9f32
R13: ffffc90002d4f980 R14: 0000000000000000 R15: ffffc90002d4f980
FS: 0000555555d3d300(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fbd24ff5138 CR3: 0000000019b1a000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
generic_file_read_iter+0x338/0x460 mm/filemap.c:2769
call_read_iter include/linux/fs.h:2097 [inline]
generic_file_splice_read+0x4ad/0x790 fs/splice.c:311
do_splice_to fs/splice.c:796 [inline]
splice_direct_to_actor+0x448/0xc10 fs/splice.c:870
do_splice_direct+0x285/0x3d0 fs/splice.c:979
do_sendfile+0x625/0xff0 fs/read_write.c:1249
__do_sys_sendfile64 fs/read_write.c:1317 [inline]
__se_sys_sendfile64+0x178/0x1e0 fs/read_write.c:1303
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7fbd24f63a09
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 11 15 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffe390acd58 EFLAGS: 00000246 ORIG_RAX: 0000000000000028
RAX: ffffffffffffffda RBX: 0000000000000002 RCX: 00007fbd24f63a09
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000004
RBP: 00007ffe390acd80 R08: 0000000000000002 R09: 00007ffe390acd90
R10: 0000000100000000 R11: 0000000000000246 R12: 0000000000000005
R13: 00007ffe390acdc0 R14: 00007ffe390acda0 R15: 0000000000000001
</TASK>
----------------
Code disassembly (best guess):
0: 28 00 sub %al,(%rax)
2: 00 00 add %al,(%rax)
4: 75 05 jne 0xb
6: 48 83 c4 28 add $0x28,%rsp
a: c3 retq
b: e8 11 15 00 00 callq 0x1521
10: 90 nop
11: 48 89 f8 mov %rdi,%rax
14: 48 89 f7 mov %rsi,%rdi
17: 48 89 d6 mov %rdx,%rsi
1a: 48 89 ca mov %rcx,%rdx
1d: 4d 89 c2 mov %r8,%r10
20: 4d 89 c8 mov %r9,%r8
23: 4c 8b 4c 24 08 mov 0x8(%rsp),%r9
28: 0f 05 syscall
* 2a: 48 3d 01 f0 ff ff cmp $0xfffffffffffff001,%rax <-- trapping instruction
30: 73 01 jae 0x33
32: c3 retq
33: 48 c7 c1 c0 ff ff ff mov $0xffffffffffffffc0,%rcx
3a: f7 d8 neg %eax
3c: 64 89 01 mov %eax,%fs:(%rcx)
3f: 48 rex.W


---
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.

If the bug is already fixed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.

If you want to change bug's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the bug is a duplicate of another bug, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

syzbot

unread,
Sep 16, 2023, 2:39:30 AM9/16/23
to syzkaller...@googlegroups.com
syzbot suspects this issue could be fixed by backporting the following commit:

commit aa3dbde878961dd333cdd3c326b93e6c84a23ed4
git tree: upstream
Author: David Howells <dhow...@redhat.com>
Date: Mon May 22 13:49:54 2023 +0000

splice: Make splice from an O_DIRECT fd use copy_splice_read()

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=11f95c54680000
Please keep in mind that other backports might be required as well.

For information about bisection process see: https://goo.gl/tpsmEJ#bisection
Reply all
Reply to author
Forward
0 new messages