Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp16887ybc; Mon, 18 Nov 2019 19:13:01 -0800 (PST) X-Google-Smtp-Source: APXvYqze/fEssyFLdE7y/e83xaUTywawQF4Hs66trA6iKtM6AXgHwiDgtExTSwSkXorjSkcGQtXe X-Received: by 2002:a17:906:fad4:: with SMTP id lu20mr31941070ejb.9.1574133181596; Mon, 18 Nov 2019 19:13:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574133181; cv=none; d=google.com; s=arc-20160816; b=IIhk1t1XeQQudyHCYTik+9ttL3Re/enc/QdaZD/t/Pnsm1oz8kY4OVomUoSAYfK7x7 ZJo95uxiAzLX+HA79L+qj/U1qmv2+6PRUEOSJ3YCZ/2/p8fjoYJInHZ+B+D/BFKJV1EU o+Qxai1H1TIhCR8BlSIyNgnTwwVLJ3z4o82uxSXxj/s2rFOjBfxmG+Hct8Bg6IPtLnxL VdqaQ5UBHyhIy2XU43OxqnTYZD8afOxKX5U+s4ecyJy7I0Qe6NyPzxlIK7a5FK/MdnQ1 3X5K6wjdTtBhyUqLlzE7cRgclwQdJlVIxuaGESg7SNE7352p+SIv4HVhYHfNgQbDHhnA rcgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=zuUYWetEyePAVhOF1Eqom3R0gQ+vlQY/t0jBuVw7/vk=; b=zfopj+wBA11xoIOfWurH/SOEQlUuozk7NqEoHqSQdzvV9zX9GzUP6Tfo354T932OrC zppaRwZ9lSCHOu5vnMvhwhm4hCKwRW8QzWtlZmFkQQ0O2r2WiJG7sPfo8x1LYKONnUnD 3h0Q/atyY8vmAPaV4+8i3RWvx8YQXLOT3sAs9O02udOMTU0brIXZnz5K9T5VmIFz6J9m cInbTa9BvWfO5FDAv9ttK4A66ZMdPxb3+9lcGEnwvojxdkKOkf4Mg2ngLDypKMRH3MpI I0CRSrrw0I9ryhObYqQ7UqSluH9AWKUxrFhOD6Buri8auM6DxRxF7l+SB5eJJvr6/+LL VUxw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=bc79nIT9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id oq2si8192493ejb.402.2019.11.18.19.12.37; Mon, 18 Nov 2019 19:13:01 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=bc79nIT9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727549AbfKSDKY (ORCPT + 99 others); Mon, 18 Nov 2019 22:10:24 -0500 Received: from mail.kernel.org ([198.145.29.99]:44296 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727014AbfKSDKX (ORCPT ); Mon, 18 Nov 2019 22:10:23 -0500 Received: from sol.localdomain (c-24-5-143-220.hsd1.ca.comcast.net [24.5.143.220]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E4CFE2070E; Tue, 19 Nov 2019 03:10:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574133023; bh=OvPo829X0NAds8jIa2J1IO7KdmDGATW9k1H4VdHCgZg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=bc79nIT9S2/aFOSzlDK80fUaTc6Zz43X96zMIi1Er/0IDrt1qAxMI389WCzvYks5X mm/a9p3FFANlWHsCGxvGIL7UwmW6F2Hv9IqBR/OCIv7BKHYMtC72zCXTKEVuli/chM Kt17k27cyDap7yAUdDizjzTL4Mafnwy5Gnqgx9Jk= Date: Mon, 18 Nov 2019 19:10:21 -0800 From: Eric Biggers To: Matthew Bobrowski Cc: Jan Kara , syzbot , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, riteshh@linux.ibm.com, syzkaller-bugs@googlegroups.com, tytso@mit.edu, viro@zeniv.linux.org.uk Subject: Re: WARNING in iov_iter_pipe Message-ID: <20191119031021.GI3147@sol.localdomain> References: <000000000000d60aa50596c63063@google.com> <20191108103148.GE20863@quack2.suse.cz> <20191111081628.GB14058@bobrowski> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191111081628.GB14058@bobrowski> User-Agent: Mutt/1.12.2 (2019-09-21) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Nov 11, 2019 at 07:16:29PM +1100, Matthew Bobrowski wrote: > On Fri, Nov 08, 2019 at 11:31:48AM +0100, Jan Kara wrote: > > On Thu 07-11-19 10:54:10, syzbot wrote: > > > syzbot found the following crash on: > > > > > > HEAD commit: c68c5373 Add linux-next specific files for 20191107 > > > git tree: linux-next > > > console output: https://syzkaller.appspot.com/x/log.txt?x=13d6bcfce00000 > > > kernel config: https://syzkaller.appspot.com/x/.config?x=742545dcdea21726 > > > dashboard link: https://syzkaller.appspot.com/bug?extid=991400e8eba7e00a26e1 > > > compiler: gcc (GCC) 9.0.0 20181231 (experimental) > > > syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1529829ae00000 > > > C reproducer: https://syzkaller.appspot.com/x/repro.c?x=16a55c0ce00000 > > > > > > The bug was bisected to: > > > > > > commit b1b4705d54abedfd69dcdf42779c521aa1e0fbd3 > > > Author: Matthew Bobrowski > > > Date: Tue Nov 5 12:01:37 2019 +0000 > > > > > > ext4: introduce direct I/O read using iomap infrastructure > > > > Hum, interesting and from the first looks the problem looks real. > > Deciphered reproducer is: > > > > int fd0 = open("./file0", O_RDWR | O_CREAT | O_EXCL | O_DIRECT, 0); > > int fd1 = open("./file0, O_RDONLY); > > write(fd0, "some_data...", 512); > > sendfile(fd0, fd1, NULL, 0x7fffffa7); > > -> this is interesting as it will result in reading data from 'file0' at > > offset X with buffered read and writing them with direct write to > > offset X+512. So this way we'll grow the file up to those ~2GB in > > 512-byte chunks. > > - not sure if we ever get there but the remainder of the reproducer is: > > fd2 = open("./file0", O_RDWR | O_CREAT | O_NOATIME | O_SYNC, 0); > > sendfile(fd2, fd0, NULL, 0xffffffff) > > -> doesn't seem too interesting as fd0 is at EOF so this shouldn't do > > anything. > > > > Matthew, can you have a look? > > Sorry Jan, I've been crazy busy lately and I'm out at training this > week. Let me take a look at this and see whether I can determine > what's happening here. > FYI, syzbot is still seeing this on linux-next. Also, a new thread was started to discuss this: https://lkml.kernel.org/linux-ext4/20191113180032.GB12013@quack2.suse.cz/T/#u (Mentioning this in case anyone is following this thread only.) - Eric