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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 55DA6C4332F for ; Mon, 14 Nov 2022 01:27:01 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 4D3216B0072; Sun, 13 Nov 2022 20:27:00 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 482746B0073; Sun, 13 Nov 2022 20:27:00 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 34A506B0074; Sun, 13 Nov 2022 20:27:00 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id 224B96B0072 for ; Sun, 13 Nov 2022 20:27:00 -0500 (EST) Received: from smtpin30.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id DB06C120934 for ; Mon, 14 Nov 2022 01:26:59 +0000 (UTC) X-FDA: 80130308958.30.BEED9B2 Received: from r3-20.sinamail.sina.com.cn (r3-20.sinamail.sina.com.cn [202.108.3.20]) by imf08.hostedemail.com (Postfix) with ESMTP id CF17416000A for ; Mon, 14 Nov 2022 01:26:57 +0000 (UTC) Received: from unknown (HELO localhost.localdomain)([114.249.57.238]) by sina.com (172.16.97.35) with ESMTP id 637198D0000216B8; Mon, 14 Nov 2022 09:24:34 +0800 (CST) X-Sender: hdanton@sina.com X-Auth-ID: hdanton@sina.com X-SMAIL-MID: 66561015073555 From: Hillf Danton To: Mike Kravetz Cc: Dmitry Vyukov , syzbot , linux-kernel@vger.kernel.org, linux-mm@kvack.org, syzkaller-bugs@googlegroups.com Subject: Re: [syzbot] WARNING: locking bug in hugetlb_no_page Date: Mon, 14 Nov 2022 09:26:44 +0800 Message-Id: <20221114012644.1930-1-hdanton@sina.com> In-Reply-To: References: <0000000000009586e205ed4679f4@google.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1668389219; a=rsa-sha256; cv=none; b=YwRdo/Spe0AE8HcbwczUtJcgli0RgCyOWpjjYGS+z4V3ZwANHUL0uK1aSbCkeGTpNUV8i6 sh4bVqgrq5puN7P/utIju3YfVTZXquvdVtG/D2YbW6RwoLfgK2qI0y08MW4tu9AynZvSKD o1xxDp2eEvSQiQpMxvbo2Uh6MBY+orw= ARC-Authentication-Results: i=1; imf08.hostedemail.com; dkim=none; spf=pass (imf08.hostedemail.com: domain of hdanton@sina.com designates 202.108.3.20 as permitted sender) smtp.mailfrom=hdanton@sina.com; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1668389219; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=y/hNozyLZoZaLbsP3ZMWjTYp7ED0JmO2YEeiN1Spkuc=; b=byGURNCBi9u6HI1RgGfK6eh3qmjCzLPXfzq81F0Mnxf4BR1UdhtjetRuUNSsvZghtr9RNQ xk4KxAHnOEM8Q4ngzXwXJrdGp45IQ44fMG22UN/AWn85fH+j2bEYdt2aYvBIMgGY2XfzYE b+4x1zVlom2q8CTmIVxejMAiMal9D98= X-Stat-Signature: jwgkitdwsnbyj7uor616gst3ui1it4n8 Authentication-Results: imf08.hostedemail.com; dkim=none; spf=pass (imf08.hostedemail.com: domain of hdanton@sina.com designates 202.108.3.20 as permitted sender) smtp.mailfrom=hdanton@sina.com; dmarc=none X-Rspamd-Server: rspam10 X-Rspam-User: X-Rspamd-Queue-Id: CF17416000A X-HE-Tag: 1668389217-363107 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 13 Nov 2022 10:50:37 -0800 Mike Kravetz > On 11/13/22 16:36, Dmitry Vyukov wrote: > > On Sat, 12 Nov 2022 at 15:03, syzbot > > wrote: > > > > > > Hello, > > > > > > syzbot found the following issue on: > > > > > > HEAD commit: 1621b6eaebf7 Merge branch 'for-next/fixes' into for-kernelci > > > git tree: git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci > > > console output: https://syzkaller.appspot.com/x/log.txt?x=13bd511e880000 > > > kernel config: https://syzkaller.appspot.com/x/.config?x=606e57fd25c5c6cc > > > dashboard link: https://syzkaller.appspot.com/bug?extid=d07c65298d2c15eafcb0 > > > compiler: Debian clang version 13.0.1-++20220126092033+75e33f71c2da-1~exp1~20220126212112.63, GNU ld (GNU Binutils for Debian) 2.35.2 > > > userspace arch: arm64 > > > syz repro: https://syzkaller.appspot.com/x/repro.syz?x=13315856880000 > > > C reproducer: https://syzkaller.appspot.com/x/repro.c?x=173614d1880000 > > > > > > Downloadable assets: > > > disk image: https://storage.googleapis.com/syzbot-assets/82aa7741098d/disk-1621b6ea.raw.xz > > > vmlinux: https://storage.googleapis.com/syzbot-assets/f6be08c4e4c2/vmlinux-1621b6ea.xz > > > kernel image: https://storage.googleapis.com/syzbot-assets/296b6946258a/Image-1621b6ea.gz.xz > > > > > > IMPORTANT: if you fix the issue, please add the following tag to the commit: > > > Reported-by: syzbot+d07c65298d2c15eafcb0@syzkaller.appspotmail.com > > > > This may have the same root cause as: > > > > possible deadlock in hugetlb_fault > > https://lore.kernel.org/all/CACT4Y+ZWNV6ApzEv0UrsF2T8JWmXez_-H-EGMii-S_2JbXv07Q@mail.gmail.com/ > > > > and there is a potential explanation as to what may be the problem. > > Thanks Dmitry! > > An issue with this new hugetlb locking was previously reported and I have been > working on a solution. When I look at the reproducer, I see that it is calling > madvise(MADV_DONTNEED). This triggers the other issue and could certainly > cause the issue reported here. > > Proposed patches are here and in next-20221111: > https://lore.kernel.org/linux-mm/20221111232628.290160-1-mike.kravetz@oracle.com/ Thanks for your fix. > > I am currently trying to run the reproducer, but it is not reproducing quickly. > Since this is a timing issue that as expected. Interesting that this > report is run on arm64 and I am trying to reproduce on x86. Although, the > issue is not architecture specific in any way. Syzbot is good at testing patches and take a look at [1,2] for submitting patch to the bot. Have fun. [1] https://lore.kernel.org/lkml/YtlbkmVGJyhO4kR6@rowland.harvard.edu/ [2] https://lore.kernel.org/lkml/fa23ffc2-755e-7e04-362d-68fad7d69c85@kernel.dk/ BTW I prefer Alan's way with patch directly attached in response to the report. Hillf > > I'll keep looking, but am fairly confident this is the root cause. > -- > Mike Kravetz