Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp202378pxb; Tue, 31 Aug 2021 19:08:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzD8WwmaqEO2KwE8Hg+E5zhDiyl7NmbXtCT9AJJoUtkF2LesA/Eutybze3/dOykvrj+4q2R X-Received: by 2002:a17:906:2bcf:: with SMTP id n15mr34504596ejg.414.1630462121775; Tue, 31 Aug 2021 19:08:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630462121; cv=none; d=google.com; s=arc-20160816; b=dZfVXiFSDzXxdDjMWdeWiLW3o8wFrJYR936d+2l3beVB8+RcngwukY5Pz3VE2HfPyQ dyBrqj0FulW4fVS5xEM1Cdj/jpuzX4ypZh8ge4OwUxB/ERCI+sYAo4OJiuStieL5fb55 pCW8PBQle0VsWAxDK1ZBmupixZbaKtnlwbx6FdJlmfhT3+P/ErVry8vTN13JZ55OEXkV hjj0cibH29ClJgmAkUToIz758MeP8SNq7uekTTShhsffEhqVGaPjShZlKGZZFL6Ye5HE fsFvl8fVz+i4GykbEehBD5LcIA2DHauq3mlk4ZhQRAFI1Rta3XCYsXuOVNaRb9TDNxOU vtNQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:from:subject:message-id:in-reply-to:date :mime-version; bh=M6ewVAPbO/i5ZRnfbguGk+MVnZhkA3eB63sbFYEWhO0=; b=w5mwAk7PgsoJHlBgZA19HMryNV5BSin7OBVpZ4y4COe81fbCgzstAw7u63yqeO2IhP 91YW1Z6gRPrNwwvPaOZKTAAWCYv+MX9CPg5tcZFtCvPrDYYQdSf6D9tOggmxudljsiWc mmFmvZhKhnRcqiM5tfALrB8z7SrY5vdbK5VWvKHVh0CWE8sQpQk+D//llIy9WFPKBAod Yvo1RoCA9p5hNlaV5kj7vFawO1bBUW0vXXPWE861tXufBGZ7MKnN617V9+2XTwUIDjL7 WlyhiPJuU4rSW89gvsLmjvrpOA/+lwCUZYDnfT6fx11MfV/SbqUUh0ICW4dcg2NDHDYm EcYA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bi8si3030318edb.24.2021.08.31.19.08.18; Tue, 31 Aug 2021 19:08:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241692AbhIACBW (ORCPT + 99 others); Tue, 31 Aug 2021 22:01:22 -0400 Received: from mail-io1-f72.google.com ([209.85.166.72]:36587 "EHLO mail-io1-f72.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241677AbhIACBU (ORCPT ); Tue, 31 Aug 2021 22:01:20 -0400 Received: by mail-io1-f72.google.com with SMTP id e187-20020a6bb5c4000000b005b5fe391cf9so708741iof.3 for ; Tue, 31 Aug 2021 19:00:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:date:in-reply-to:message-id:subject :from:to; bh=M6ewVAPbO/i5ZRnfbguGk+MVnZhkA3eB63sbFYEWhO0=; b=KJDeOGO/z9+g7C0J2TrpvSb+Qm4JZAyX47tglF3wVctnZ8L63d5Wh9UbZbv5VKhpsO rAPGXCUuOhpsARECd0PTeqL9WqcsGzuDjIowOzJGLxEAVIQSc2PVkG8ba/iocEKkrZIF 2/M5Kzti7P5y6Gzg+pIwEnQjeniUFkmSr1Gbzp+fG9ehUCxTFsFG+yqMjeu5+3IMTo2R E5mOFUdXU5Q3WcONmOIZaLdYkYoIBtAAyQLF1RAkRfjDTvyTRz5peAcbsRqp1dkFpOv+ 8+WIiewkxUI+DOcOX32K9GOHDwMo+UvdmlsnqYwNEx9QlI93EZQcOOzHVA0sZttp/RwO fZ7w== X-Gm-Message-State: AOAM530APBuEM7cWAPT7WVN0PxTNKmRXAlaO7ozomHKnoYoxp+tsk2GD jLAwHbNxI5oE0P3Lhucb+/cfw5pokLsuApTLzoxvR9iXbmsb MIME-Version: 1.0 X-Received: by 2002:a5d:8d06:: with SMTP id p6mr25833176ioj.7.1630461624447; Tue, 31 Aug 2021 19:00:24 -0700 (PDT) Date: Tue, 31 Aug 2021 19:00:24 -0700 In-Reply-To: <0000000000006d354305cae2253f@google.com> X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <000000000000f1f81105cae56d48@google.com> Subject: Re: [syzbot] general protection fault in __io_file_supports_nowait From: syzbot To: asml.silence@gmail.com, axboe@kernel.dk, io-uring@vger.kernel.org, linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org syzbot has found a reproducer for the following issue on: HEAD commit: b91db6a0b52e Merge tag 'for-5.15/io_uring-vfs-2021-08-30' .. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=12718683300000 kernel config: https://syzkaller.appspot.com/x/.config?x=210537ff2ddcc232 dashboard link: https://syzkaller.appspot.com/bug?extid=e51249708aaa9b0e4d2c compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.1 syz repro: https://syzkaller.appspot.com/x/repro.syz?x=12615c35300000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=16c57845300000 IMPORTANT: if you fix the issue, please add the following tag to the commit: Reported-by: syzbot+e51249708aaa9b0e4d2c@syzkaller.appspotmail.com general protection fault, probably for non-canonical address 0xdffffc0000000004: 0000 [#1] PREEMPT SMP KASAN KASAN: null-ptr-deref in range [0x0000000000000020-0x0000000000000027] CPU: 0 PID: 13214 Comm: iou-sqp-13213 Not tainted 5.14.0-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 RIP: 0010:file_inode include/linux/fs.h:1344 [inline] RIP: 0010:__io_file_supports_nowait+0x26/0x500 fs/io_uring.c:2785 Code: 00 00 00 00 41 55 41 54 41 89 f4 55 48 89 fd 53 e8 6f 61 96 ff 48 8d 7d 20 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 2d 04 00 00 48 b8 00 00 00 00 00 fc ff df 4c 8b RSP: 0018:ffffc9000305f800 EFLAGS: 00010212 RAX: dffffc0000000000 RBX: 0000000000000000 RCX: 0000000000000000 RDX: 0000000000000004 RSI: ffffffff81dfb791 RDI: 0000000000000020 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: ffffffff81e28292 R11: 0000000000000001 R12: 0000000000000000 R13: ffffc9000305f8d8 R14: 0000000000000000 R15: 0000000000000001 FS: 00007fa1a4652700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000020000084 CR3: 0000000027153000 CR4: 0000000000350ef0 Call Trace: io_file_supports_nowait fs/io_uring.c:2823 [inline] io_file_supports_nowait fs/io_uring.c:2816 [inline] io_read+0x4a9/0x1140 fs/io_uring.c:3440 io_issue_sqe+0x209/0x6ba0 fs/io_uring.c:6558 __io_queue_sqe+0x90/0xb50 fs/io_uring.c:6864 io_req_task_submit+0xbf/0x1b0 fs/io_uring.c:2218 tctx_task_work+0x166/0x610 fs/io_uring.c:2143 task_work_run+0xdd/0x1a0 kernel/task_work.c:164 tracehook_notify_signal include/linux/tracehook.h:212 [inline] io_run_task_work fs/io_uring.c:2403 [inline] io_run_task_work fs/io_uring.c:2399 [inline] io_sq_thread+0x867/0x1370 fs/io_uring.c:7337 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 Modules linked in: ---[ end trace f12dea0e85a314d8 ]--- RIP: 0010:file_inode include/linux/fs.h:1344 [inline] RIP: 0010:__io_file_supports_nowait+0x26/0x500 fs/io_uring.c:2785 Code: 00 00 00 00 41 55 41 54 41 89 f4 55 48 89 fd 53 e8 6f 61 96 ff 48 8d 7d 20 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 2d 04 00 00 48 b8 00 00 00 00 00 fc ff df 4c 8b RSP: 0018:ffffc9000305f800 EFLAGS: 00010212 RAX: dffffc0000000000 RBX: 0000000000000000 RCX: 0000000000000000 RDX: 0000000000000004 RSI: ffffffff81dfb791 RDI: 0000000000000020 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: ffffffff81e28292 R11: 0000000000000001 R12: 0000000000000000 R13: ffffc9000305f8d8 R14: 0000000000000000 R15: 0000000000000001 FS: 00007fa1a4652700(0000) GS:ffff8880b9d00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f7e4803c008 CR3: 0000000027153000 CR4: 0000000000350ee0 ---------------- Code disassembly (best guess): 0: 00 00 add %al,(%rax) 2: 00 00 add %al,(%rax) 4: 41 55 push %r13 6: 41 54 push %r12 8: 41 89 f4 mov %esi,%r12d b: 55 push %rbp c: 48 89 fd mov %rdi,%rbp f: 53 push %rbx 10: e8 6f 61 96 ff callq 0xff966184 15: 48 8d 7d 20 lea 0x20(%rbp),%rdi 19: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 20: fc ff df 23: 48 89 fa mov %rdi,%rdx 26: 48 c1 ea 03 shr $0x3,%rdx * 2a: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1) <-- trapping instruction 2e: 0f 85 2d 04 00 00 jne 0x461 34: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 3b: fc ff df 3e: 4c rex.WR 3f: 8b .byte 0x8b