From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 64D2FC433B4 for ; Thu, 1 Apr 2021 12:19:37 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id D65E261130 for ; Thu, 1 Apr 2021 12:19:36 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D65E261130 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ziepe.ca Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 63CA56B0081; Thu, 1 Apr 2021 08:19:36 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 5EC456B0082; Thu, 1 Apr 2021 08:19:36 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4663F6B0083; Thu, 1 Apr 2021 08:19:36 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0225.hostedemail.com [216.40.44.225]) by kanga.kvack.org (Postfix) with ESMTP id 289646B0081 for ; Thu, 1 Apr 2021 08:19:36 -0400 (EDT) Received: from smtpin03.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id E13C61805D7A3 for ; Thu, 1 Apr 2021 12:19:35 +0000 (UTC) X-FDA: 77983703910.03.239DBFF Received: from mail-qt1-f180.google.com (mail-qt1-f180.google.com [209.85.160.180]) by imf16.hostedemail.com (Postfix) with ESMTP id F34A780192EA for ; Thu, 1 Apr 2021 12:19:34 +0000 (UTC) Received: by mail-qt1-f180.google.com with SMTP id c6so1293940qtc.1 for ; Thu, 01 Apr 2021 05:19:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=Vgr/Zl3BDXRnrq2J6EE+e/3R7mQgt/D2Dsj5nuE2w0M=; b=JpAs1vzPTjz4W8rdx9Lqz6nBqd13qCgN3+erq91mh4WGoo/LZS5fEquo+DACiJnKkX QrRXi051hfgjTbJbWkb4DYzvsW7dd5nBrV1B7iZhANXyvf9JPdE2B/K8FL9e62txVK7G 0X/gpOxbofNzmLf0GAqzpX8sBfJtZmAM5AgY6NsA+fMjUnX+sBbt/uAKoHA8hXKR3thw I4MqU09EK54ap9j94WYb6DERRr6dM1RBsJqJQLblOPlbmso1274vL9Xp0KegLKnMSTTI OwoDTz18mnTz8i5OKZzE0CwVDjue/qX8moZSc4OPC55MzH1GtPpdWvMfTcPBykbbhtQ4 E5jg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=Vgr/Zl3BDXRnrq2J6EE+e/3R7mQgt/D2Dsj5nuE2w0M=; b=cdAbLR3TDzxAvvZurn9tEwjF8SsmPYTDpgKYpuLWsYcvcW5qAusCtliCiC43Wd7ffY li2XOv26UKFgmmUftnNZSap0xLEESSugpBt0nDLzU8bXHMvVrYvxF0IP3OIko+dpii3C kwgw+/6d9zyrKkusH/CjA7egT5bwbneuJPJp3PaWV/nrLvni/T1h+ycX5KXjQb3vqZel VjPcTKe4XrxT0qwFg/5mAW0VJS4+HmAnFXzphUOeecfRx9OCvIoYJC/vbwzjbCZtZWPw oLbk6Ni4CTE0YeTWF9TINqCsBoHgpl07TLLNMVg6dew2bLvdCsEQTDrEBNWd8T/+dNW/ 8CAA== X-Gm-Message-State: AOAM532QHY23eovRZAfhWfWpCzSoWPK7CX24nnxwBSXfGAR+acUZASgy GkkNsBah6jpZ5zGrmJhSyvmUFA== X-Google-Smtp-Source: ABdhPJz6ns0s4EMUeoQopcXj71hOMnL0XWBbKVYAuaGM2OabeF39OGOUzeq0Rc+BHh/xNK4055cz0A== X-Received: by 2002:ac8:7f52:: with SMTP id g18mr6906607qtk.250.1617279574765; Thu, 01 Apr 2021 05:19:34 -0700 (PDT) Received: from ziepe.ca (hlfxns017vw-142-162-115-133.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.115.133]) by smtp.gmail.com with ESMTPSA id s28sm3807098qkj.73.2021.04.01.05.19.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Apr 2021 05:19:34 -0700 (PDT) Received: from jgg by mlx with local (Exim 4.94) (envelope-from ) id 1lRwIP-006jdH-LT; Thu, 01 Apr 2021 09:19:33 -0300 Date: Thu, 1 Apr 2021 09:19:33 -0300 From: Jason Gunthorpe To: Dan Carpenter Cc: Paolo Bonzini , syzbot , akpm@linux-foundation.org, bp@alien8.de, daniel.vetter@ffwll.ch, daniel.vetter@intel.com, hpa@zytor.com, jmattson@google.com, jmorris@namei.org, joro@8bytes.org, kvm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, linux-mm@kvack.org, linux-security-module@vger.kernel.org, m.szyprowski@samsung.com, mchehab@kernel.org, mingo@redhat.com, seanjc@google.com, serge@hallyn.com, syzkaller-bugs@googlegroups.com, tfiga@chromium.org, tglx@linutronix.de, vkuznets@redhat.com, wanpengli@tencent.com, x86@kernel.org Subject: Re: [syzbot] WARNING in unsafe_follow_pfn Message-ID: <20210401121933.GA2710221@ziepe.ca> References: <000000000000ca9a6005bec29ebe@google.com> <2db3c803-6a94-9345-261a-a2bb74370c02@redhat.com> <20210331042922.GE2065@kadam> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210331042922.GE2065@kadam> X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: F34A780192EA X-Stat-Signature: p8159aqjqd4tpotr4fpfs5r9n1xj4fmm Received-SPF: none (ziepe.ca>: No applicable sender policy available) receiver=imf16; identity=mailfrom; envelope-from=""; helo=mail-qt1-f180.google.com; client-ip=209.85.160.180 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1617279574-755730 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Wed, Mar 31, 2021 at 07:29:22AM +0300, Dan Carpenter wrote: > On Tue, Mar 30, 2021 at 07:04:30PM +0200, Paolo Bonzini wrote: > > On 30/03/21 17:26, syzbot wrote: > > > Hello, > > > > > > syzbot found the following issue on: > > > > > > HEAD commit: 93129492 Add linux-next specific files for 20210326 > > > git tree: linux-next > > > console output: https://syzkaller.appspot.com/x/log.txt?x=169ab21ad00000 > > > kernel config: https://syzkaller.appspot.com/x/.config?x=6f2f73285ea94c45 > > > dashboard link: https://syzkaller.appspot.com/bug?extid=015dd7cdbbbc2c180c65 > > > syz repro: https://syzkaller.appspot.com/x/repro.syz?x=119b8d06d00000 > > > C reproducer: https://syzkaller.appspot.com/x/repro.c?x=112e978ad00000 > > > > > > The issue was bisected to: > > > > > > commit d40b9fdee6dc819d8fc35f70c345cbe0394cde4c > > > Author: Daniel Vetter > > > Date: Tue Mar 16 15:33:01 2021 +0000 > > > > > > mm: Add unsafe_follow_pfn > > > > > > bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=122d2016d00000 > > > final oops: https://syzkaller.appspot.com/x/report.txt?x=112d2016d00000 > > > console output: https://syzkaller.appspot.com/x/log.txt?x=162d2016d00000 > > > > > > IMPORTANT: if you fix the issue, please add the following tag to the commit: > > > Reported-by: syzbot+015dd7cdbbbc2c180c65@syzkaller.appspotmail.com > > > Fixes: d40b9fdee6dc ("mm: Add unsafe_follow_pfn") > > > > This is basically intentional because get_vaddr_frames is broken, isn't it? > > I think it needs to be ignored in syzkaller. > > What? > > The bisect is wrong (because it's blaming the commit which added the > warning instead of the commit which added the buggy caller) but the > warning is correct. > > Plus users are going to be seeing this as well. According to the commit > message for 69bacee7f9ad ("mm: Add unsafe_follow_pfn") "Unfortunately > there's some users where this is not fixable (like v4l userptr of iomem > mappings)". It sort of seems crazy to dump this giant splat and then > tell users to ignore it forever because it can't be fixed... 0_0 I think the discussion conclusion was that this interface should not be used by userspace anymore, it is obsolete by some new interface? It should be protected by some kconfig and the kconfig should be turned off for syzkaller runs. Jason