syzbot


WARNING in iov_iter_revert (2)

Status: fixed on 2021/04/09 19:46
Subsystems: serial
[Documentation on labels]
Reported-by: syzbot+3d2c27c2b7dc2a94814d@syzkaller.appspotmail.com
Fix commit: 3342ff2698e9 tty: protect tty_write from odd low-level tty disciplines
First crash: 1162d, last: 1157d
Cause bisection: introduced by (bisect log) :
commit 9bb48c82aced07698a2d08ee0f1475a6c4f6b266
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date: Tue Jan 19 19:41:16 2021 +0000

  tty: implement write_iter

Crash: WARNING in iov_iter_revert (log)
Repro: C syz .config
  
Discussions (5)
Title Replies (including bot) Last reply
[PATCH 5.10 00/29] 5.10.18-rc1 review 43 (43) 2021/02/24 18:42
[PATCH 5.11 00/12] 5.11.1-rc1 review 20 (20) 2021/02/24 07:49
Re: WARNING in iov_iter_revert (2) 9 (9) 2021/02/21 18:39
WARNING in iov_iter_revert (2) 0 (2) 2021/02/20 14:25
[PATCH] tty: fix when iov_iter_count() returns 0 in tty_write() 5 (5) 2021/02/19 09:17
Similar bugs (5)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream WARNING in iov_iter_revert net C 74 2101d 2168d 8/26 fixed on 2018/08/07 13:43
linux-6.1 WARNING in iov_iter_revert origin:lts-only C done 1 195d 250d 0/3 upstream: reported C repro on 2023/08/13 18:12
upstream WARNING in iov_iter_revert (4) ntfs3 C done error 4 264d 316d 0/26 auto-obsoleted due to no activity on 2023/11/08 23:39
upstream WARNING in iov_iter_revert (3) ntfs3 C error error 26 452d 511d 0/26 auto-obsoleted due to no activity on 2023/05/23 03:07
linux-5.15 WARNING in iov_iter_revert origin:lts-only C done 1 280d 296d 0/3 upstream: reported C repro on 2023/06/28 09:07
Last patch testing requests (1)
Created Duration User Patch Repo Result
2021/02/17 14:04 16m snovitoll@gmail.com https://linux.googlesource.com/linux/kernel/git/torvalds/linux refs/changes/76/8476/1 OK
Cause bisection attempts (2)
Created Duration User Patch Repo Result
2021/02/20 10:38 3h46m bisect upstream job log (1) log
2021/02/12 16:25 0m bisect upstream error job log (0)

Sample crash report:
[U] 
------------[ cut here ]------------
WARNING: CPU: 1 PID: 8461 at lib/iov_iter.c:1090 iov_iter_revert+0x2e3/0x8e0 lib/iov_iter.c:1090
Modules linked in:
CPU: 1 PID: 8461 Comm: syz-executor778 Not tainted 5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:iov_iter_revert+0x2e3/0x8e0 lib/iov_iter.c:1090
Code: 05 00 00 45 8b 74 24 08 48 89 de 4c 89 6d 20 49 83 c5 01 4c 89 f7 e8 bc eb b4 fd 49 39 de 72 ba e9 2c ff ff ff e8 9d e5 b4 fd <0f> 0b e9 30 ff ff ff e8 91 e5 b4 fd 48 8d 7d 18 48 b8 00 00 00 00
RSP: 0018:ffffc9000168fc30 EFLAGS: 00010293
RAX: 0000000000000000 RBX: ffffffffffffffff RCX: 0000000000000000
RDX: ffff88801b6c1bc0 RSI: ffffffff83bdef03 RDI: 0000000000000003
RBP: ffffc9000168fd68 R08: 000000007ffff000 R09: ffffffff8f86683f
R10: ffffffff83bdec5e R11: 0000000000000000 R12: 0000000000000001
R13: 0000000000000000 R14: ffffc9000168fd68 R15: ffff88801b6c1bc0
FS:  00000000016f5300(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f5d4c03d0d8 CR3: 0000000013adc000 CR4: 0000000000350ef0
Call Trace:
 do_tty_write drivers/tty/tty_io.c:967 [inline]
 file_tty_write.constprop.0+0x55f/0x8f0 drivers/tty/tty_io.c:1048
 call_write_iter include/linux/fs.h:1901 [inline]
 new_sync_write+0x426/0x650 fs/read_write.c:518
 vfs_write+0x791/0xa30 fs/read_write.c:605
 ksys_write+0x12d/0x250 fs/read_write.c:658
 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9
RIP: 0033:0x43ee99
Code: 28 c3 e8 2a 14 00 00 66 2e 0f 1f 84 00 00 00 00 00 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:00007fffc3cb0628 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000000000400488 RCX: 000000000043ee99
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000003
RBP: 0000000000402e80 R08: 0000000000400488 R09: 0000000000400488
R10: 0000000000400488 R11: 0000000000000246 R12: 0000000000402f10
R13: 0000000000000000 R14: 00000000004ac018 R15: 0000000000400488

Crashes (9):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2021/02/12 16:37 upstream dcc0b49040c7 a5f86b15 .config console log report syz C ci-upstream-kasan-gce-root WARNING in iov_iter_revert
2021/02/12 16:37 upstream dcc0b49040c7 a5f86b15 .config console log report syz C ci-upstream-kasan-gce WARNING in iov_iter_revert
2021/02/12 16:25 upstream dcc0b49040c7 a5f86b15 .config console log report syz C ci-upstream-kasan-gce-smack-root WARNING in iov_iter_revert
2021/02/17 18:24 upstream f40ddce88593 052f8d9f .config console log report info ci-upstream-kasan-gce-selinux-root WARNING in iov_iter_revert
2021/02/12 16:21 upstream dcc0b49040c7 a5f86b15 .config console log report info ci-upstream-kasan-gce-root WARNING in iov_iter_revert
2021/02/12 16:18 upstream dcc0b49040c7 a5f86b15 .config console log report info ci-upstream-kasan-gce WARNING in iov_iter_revert
2021/02/12 16:10 upstream dcc0b49040c7 a5f86b15 .config console log report info ci-upstream-kasan-gce-smack-root WARNING in iov_iter_revert
2021/02/17 18:14 upstream f40ddce88593 052f8d9f .config console log report info ci-upstream-kasan-gce-386 WARNING in iov_iter_revert
2021/02/12 16:28 upstream dcc0b49040c7 a5f86b15 .config console log report info ci-upstream-kasan-gce-386 WARNING in iov_iter_revert
* Struck through repros no longer work on HEAD.