syzbot


WARNING in ion_dma_buf_begin_cpu_access

Status: fixed on 2018/07/09 18:05
Subsystems: staging
[Documentation on labels]
Reported-by: syzbot+55b1d9f811650de944c6@syzkaller.appspotmail.com
Fix commit: 0a2bc00341dc staging: android: ion: Return an ERR_PTR in ion_map_kernel
First crash: 2200d, last: 2178d
Discussions (8)
Title Replies (including bot) Last reply
[PATCH 3.16 000/366] 3.16.61-rc1 review 375 (376) 2019/01/02 17:44
[PATCH 4.4 00/47] 4.4.140-stable review 56 (56) 2018/07/28 05:56
[PATCH 4.9 00/52] 4.9.112-stable review 59 (60) 2018/07/11 20:12
[PATCH 3.18 00/23] 3.18.115-stable review 29 (29) 2018/07/11 15:10
[PATCH 4.14 00/61] 4.14.54-stable review 57 (58) 2018/07/09 13:28
[PATCH 4.17 00/46] 4.17.5-stable review 34 (35) 2018/07/07 21:40
[PATCH] staging: android: ion: Return an ERR_PTR in ion_map_kernel 1 (1) 2018/06/11 18:06
WARNING in ion_dma_buf_begin_cpu_access 0 (1) 2018/06/10 06:27

Sample crash report:
1965969 pages RAM
0 pages HighMem/MovableOnly
340001 pages reserved
------------[ cut here ]------------
heap->ops->map_kernel should return ERR_PTR on error
WARNING: CPU: 1 PID: 4564 at drivers/staging/android/ion/ion.c:148 ion_buffer_kmap_get drivers/staging/android/ion/ion.c:147 [inline]
WARNING: CPU: 1 PID: 4564 at drivers/staging/android/ion/ion.c:148 ion_dma_buf_begin_cpu_access+0x48e/0x5a0 drivers/staging/android/ion/ion.c:328
Kernel panic - not syncing: panic_on_warn set ...

CPU: 1 PID: 4564 Comm: syz-executor145 Not tainted 4.17.0+ #93
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x1b9/0x294 lib/dump_stack.c:113
 panic+0x22f/0x4de kernel/panic.c:184
 __warn.cold.8+0x163/0x1b3 kernel/panic.c:536
 report_bug+0x252/0x2d0 lib/bug.c:186
 fixup_bug arch/x86/kernel/traps.c:178 [inline]
 do_error_trap+0x1fc/0x4d0 arch/x86/kernel/traps.c:296
 do_invalid_op+0x1b/0x20 arch/x86/kernel/traps.c:316
 invalid_op+0x14/0x20 arch/x86/entry/entry_64.S:992
RIP: 0010:ion_buffer_kmap_get drivers/staging/android/ion/ion.c:147 [inline]
RIP: 0010:ion_dma_buf_begin_cpu_access+0x48e/0x5a0 drivers/staging/android/ion/ion.c:328
Code: ff 41 bc ea ff ff ff 89 de e8 8e b0 ba fb 84 db 75 a8 e8 b5 af ba fb 48 c7 c7 00 05 68 88 c6 05 39 8d d9 03 01 e8 02 c7 86 fb <0f> 0b eb 8c 48 c7 c7 40 09 ef 88 e8 12 a3 f7 fb e9 15 ff ff ff e8 
RSP: 0018:ffff8801ac87fb08 EFLAGS: 00010286
RAX: 0000000000000034 RBX: 0000000000000000 RCX: ffffffff816191ea
RDX: 0000000000000000 RSI: ffffffff8161f4e1 RDI: ffff8801ac87f7e0
RBP: ffff8801ac87fb60 R08: ffff8801d8856480 R09: 0000000000000006
R10: ffff8801d8856480 R11: 0000000000000000 R12: 00000000ffffffea
R13: ffff8801d977d148 R14: 0000000000000001 R15: ffffffff89724b80
 dma_buf_begin_cpu_access+0x7f/0x160 drivers/dma-buf/dma-buf.c:823
 dma_buf_ioctl+0x1aa/0x240 drivers/dma-buf/dma-buf.c:314
 vfs_ioctl fs/ioctl.c:46 [inline]
 file_ioctl fs/ioctl.c:500 [inline]
 do_vfs_ioctl+0x1cf/0x16f0 fs/ioctl.c:684
 ksys_ioctl+0xa9/0xd0 fs/ioctl.c:701
 __do_sys_ioctl fs/ioctl.c:708 [inline]
 __se_sys_ioctl fs/ioctl.c:706 [inline]
 __x64_sys_ioctl+0x73/0xb0 fs/ioctl.c:706
 do_syscall_64+0x1b1/0x800 arch/x86/entry/common.c:287
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x440479
Code: 18 89 d0 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 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 0f 83 5b 14 fc ff c3 66 2e 0f 1f 84 00 00 00 00 
RSP: 002b:00007fff6df8d2f8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000440479
RDX: 0000000020fd3ff8 RSI: 0000000040086200 RDI: 0000000000000004
RBP: 00000000006cb018 R08: 0000000000000001 R09: 00007fff6df80031
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000005
R13: ffffffffffffffff R14: 0000000000000000 R15: 0000000000000000
Dumping ftrace buffer:
   (ftrace buffer empty)
Kernel Offset: disabled
Rebooting in 86400 seconds..

Crashes (62):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2018/06/10 01:59 upstream a16afaf7928b 866118af .config console log report syz C ci-upstream-kasan-gce
2018/06/10 01:34 upstream a16afaf7928b 866118af .config console log report syz C ci-upstream-kasan-gce-root
2018/06/10 02:50 upstream a16afaf7928b 866118af .config console log report syz ci-upstream-kasan-gce-386
2018/06/10 01:32 upstream a16afaf7928b 866118af .config console log report syz ci-upstream-kasan-gce-386
2018/07/01 12:13 upstream 883c9ab9eb59 dba0b50e .config console log report ci-upstream-kasan-gce
2018/06/30 22:21 upstream 0fbc4aeabc91 dba0b50e .config console log report ci-upstream-kasan-gce-root
2018/06/30 15:47 upstream 1904148a361a dba0b50e .config console log report ci-upstream-kasan-gce-root
2018/06/28 10:00 upstream f57494321cbf dba0b50e .config console log report ci-upstream-kasan-gce
2018/06/27 21:05 upstream debd52a05061 43e60f7e .config console log report ci-upstream-kasan-gce-root
2018/06/27 04:39 upstream 813835028e9a b0294c53 .config console log report ci-upstream-kasan-gce-root
2018/06/25 11:59 upstream 6f0d349d922b 2064fc5c .config console log report ci-upstream-kasan-gce-root
2018/06/25 10:00 upstream 6f0d349d922b 2064fc5c .config console log report ci-upstream-kasan-gce
2018/06/24 07:22 upstream 77072ca59fdd 2064fc5c .config console log report ci-upstream-kasan-gce
2018/06/24 02:37 upstream 5e2204832b20 2064fc5c .config console log report ci-upstream-kasan-gce-root
2018/06/23 22:55 upstream 5e2204832b20 2064fc5c .config console log report ci-upstream-kasan-gce-root
2018/06/21 02:46 upstream 1abd8a8f39cd 095ef806 .config console log report ci-upstream-kasan-gce
2018/06/21 00:23 upstream 1abd8a8f39cd 095ef806 .config console log report ci-upstream-kasan-gce-root
2018/06/20 14:25 upstream 81e97f01371f 095ef806 .config console log report ci-upstream-kasan-gce-root
2018/06/20 10:08 upstream 81e97f01371f 095ef806 .config console log report ci-upstream-kasan-gce-root
2018/06/20 00:03 upstream ba4dbdedd3ed 095ef806 .config console log report ci-upstream-kasan-gce
2018/06/17 15:47 upstream ce397d215ccd 27c5f59f .config console log report ci-upstream-kasan-gce-root
2018/06/16 17:49 upstream 35773c93817c 27c5f59f .config console log report ci-upstream-kasan-gce-root
2018/06/16 11:09 upstream 9215310cf13b 27c5f59f .config console log report ci-upstream-kasan-gce-root
2018/06/15 16:09 upstream 4c5e8fc62d6a 27c5f59f .config console log report ci-upstream-kasan-gce-root
2018/06/15 13:28 upstream b5d903c2d656 27c5f59f .config console log report ci-upstream-kasan-gce-root
2018/06/15 08:44 upstream b5d903c2d656 27c5f59f .config console log report ci-upstream-kasan-gce
2018/06/15 01:32 upstream b5d903c2d656 27c5f59f .config console log report ci-upstream-kasan-gce
2018/06/14 07:40 upstream be779f03d563 27c5f59f .config console log report ci-upstream-kasan-gce
2018/06/11 23:35 upstream f0dc7f9c6dd9 112eec79 .config console log report ci-upstream-kasan-gce-root
2018/06/11 04:52 upstream 1aaccb5fa0ea 866118af .config console log report ci-upstream-kasan-gce
2018/06/11 04:50 upstream 1aaccb5fa0ea 866118af .config console log report ci-upstream-kasan-gce-root
2018/06/11 02:25 upstream 1aaccb5fa0ea 866118af .config console log report ci-upstream-kasan-gce-root
2018/06/11 00:10 upstream 3ca24ce9ff76 866118af .config console log report ci-upstream-kasan-gce-root
2018/06/10 09:55 upstream a16afaf7928b 866118af .config console log report ci-upstream-kasan-gce-root
2018/06/10 09:53 upstream a16afaf7928b 866118af .config console log report ci-upstream-kasan-gce
2018/06/10 01:14 upstream a16afaf7928b 866118af .config console log report ci-upstream-kasan-gce-root
2018/07/01 17:27 upstream 883c9ab9eb59 dba0b50e .config console log report ci-upstream-kasan-gce-386
2018/07/01 04:16 upstream 0fbc4aeabc91 dba0b50e .config console log report ci-upstream-kasan-gce-386
2018/06/29 10:31 upstream 90368a37fbbe dba0b50e .config console log report ci-upstream-kasan-gce-386
2018/06/25 15:26 upstream 6f0d349d922b 2064fc5c .config console log report ci-upstream-kasan-gce-386
2018/06/22 01:48 upstream 27db64f65f1b 095ef806 .config console log report ci-upstream-kasan-gce-386
2018/06/16 01:09 upstream 4c5e8fc62d6a 27c5f59f .config console log report ci-upstream-kasan-gce-386
2018/06/15 08:45 upstream b5d903c2d656 27c5f59f .config console log report ci-upstream-kasan-gce-386
2018/06/13 03:10 upstream 0725d4e1b8b0 6dcbc435 .config console log report ci-upstream-kasan-gce-386
2018/06/11 06:30 upstream 1aaccb5fa0ea 866118af .config console log report ci-upstream-kasan-gce-386
2018/06/10 20:49 upstream 3ca24ce9ff76 866118af .config console log report ci-upstream-kasan-gce-386
* Struck through repros no longer work on HEAD.