[v6.1] WARNING in iov_iter_revert

0 views
Skip to first unread message

syzbot

unread,
Aug 13, 2023, 2:13:00 PM8/13/23
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 1321ab403b38 Linux 6.1.45
git tree: linux-6.1.y
console output: https://syzkaller.appspot.com/x/log.txt?x=10a31127a80000
kernel config: https://syzkaller.appspot.com/x/.config?x=5afeea223ff7d6fa
dashboard link: https://syzkaller.appspot.com/bug?extid=abcce97fe7b7c391e348
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=11270c6ba80000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=13034bc3a80000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/df0f614deffc/disk-1321ab40.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/df0f1be30831/vmlinux-1321ab40.xz
kernel image: https://storage.googleapis.com/syzbot-assets/9e190f335ac9/bzImage-1321ab40.xz
mounted in repro: https://storage.googleapis.com/syzbot-assets/db53e2825938/mount_0.gz

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

Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 21 18 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 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffdb17a94c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000028
RAX: ffffffffffffffda RBX: 00007ffdb17a94f0 RCX: 00007fdba92b91e9
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000004
RBP: 0000000000000002 R08: 00007ffdb17a9266 R09: 00007ffdb17a9510
R10: 0000000100000000 R11: 0000000000000246 R12: 00007ffdb17a94ec
R13: 0000000000000001 R14: 431bde82d7b634db R15: 00007ffdb17a9530
</TASK>
------------[ cut here ]------------
WARNING: CPU: 0 PID: 3510 at lib/iov_iter.c:918 iov_iter_revert+0x382/0x830
Modules linked in:
CPU: 0 PID: 3510 Comm: syz-executor164 Not tainted 6.1.45-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:iov_iter_revert+0x382/0x830 lib/iov_iter.c:918
Code: 80 3c 01 00 48 8b 5c 24 18 74 08 48 89 df e8 55 4f ad fd 4c 89 2b 48 83 c4 60 5b 41 5c 41 5d 41 5e 41 5f 5d c3 e8 1e bc 56 fd <0f> 0b eb e8 48 8d 6b 18 48 89 e8 48 c1 e8 03 42 80 3c 28 00 74 08
RSP: 0018:ffffc90003aaf7f0 EFLAGS: 00010293
RAX: ffffffff843341e2 RBX: ffffc90003aaf980 RCX: ffff888027cebb80
RDX: 0000000000000000 RSI: ffffffffffff1000 RDI: 000000007ffff000
RBP: ffffffffffff1000 R08: ffffffff84333e9c R09: fffffbfff1a407a3
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffffffffff1000
R13: ffffc90003aaf980 R14: ffffc90003aaf990 R15: 0000000000000000
FS: 000055555669a380(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fdba93500f8 CR3: 0000000013724000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
generic_file_read_iter+0x3d7/0x540 mm/filemap.c:2805
call_read_iter include/linux/fs.h:2199 [inline]
generic_file_splice_read+0x23c/0x630 fs/splice.c:309
do_splice_to fs/splice.c:793 [inline]
splice_direct_to_actor+0x408/0xbd0 fs/splice.c:865
do_splice_direct+0x27f/0x3c0 fs/splice.c:974
do_sendfile+0x61c/0xff0 fs/read_write.c:1255
__do_sys_sendfile64 fs/read_write.c:1323 [inline]
__se_sys_sendfile64+0x178/0x1e0 fs/read_write.c:1309
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+0x63/0xcd
RIP: 0033:0x7fdba92b91e9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 21 18 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 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffdb17a94c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000028
RAX: ffffffffffffffda RBX: 00007ffdb17a94f0 RCX: 00007fdba92b91e9
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000004
RBP: 0000000000000002 R08: 00007ffdb17a9266 R09: 00007ffdb17a9510
R10: 0000000100000000 R11: 0000000000000246 R12: 00007ffdb17a94ec
R13: 0000000000000001 R14: 431bde82d7b634db R15: 00007ffdb17a9530
</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 ret
b: e8 21 18 00 00 call 0x1831
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 ret
33: 48 c7 c1 b8 ff ff ff mov $0xffffffffffffffb8,%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,
Oct 9, 2023, 9:05:29 AM10/9/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=126efaaa680000
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