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 58FA4C433F5 for ; Sat, 14 May 2022 00:18:18 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C10B86B0073; Fri, 13 May 2022 20:18:17 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id BBFDC6B0075; Fri, 13 May 2022 20:18:17 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A606E6B0078; Fri, 13 May 2022 20:18:17 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id 933F56B0073 for ; Fri, 13 May 2022 20:18:17 -0400 (EDT) Received: from smtpin28.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 608CF3259F for ; Sat, 14 May 2022 00:18:17 +0000 (UTC) X-FDA: 79462436634.28.93FBB12 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by imf16.hostedemail.com (Postfix) with ESMTP id F41A11800D6 for ; Sat, 14 May 2022 00:18:06 +0000 (UTC) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id CEE6EB8324C; Sat, 14 May 2022 00:18:14 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F2731C385AA; Sat, 14 May 2022 00:18:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1652487493; bh=kw3CRHi4r3zW24bJ9aMXizk9Hol6hDRCL5ptaAt/ldM=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=pYJQJ1zMoJadGRgSmqDeHSNHpimlTYl8VVS+moIM1ed2Y2BVr7ddCBr/x6nJPh1WF gnNRVqVi0H63lD3X6rthMOfaygHE2kk37joJ20Ti3ySjfeRQ/c6UcQPnHSPxwlEcjQ VZWoBVPghrfFIfz7lTuaElxlzaLLFzeXMKe5/djQ= Date: Fri, 13 May 2022 17:18:11 -0700 From: Andrew Morton To: Minchan Kim Cc: Mike Kravetz , syzbot , linux-kernel@vger.kernel.org, linux-mm@kvack.org, llvm@lists.linux.dev, nathan@kernel.org, ndesaulniers@google.com, syzkaller-bugs@googlegroups.com, trix@redhat.com, Matthew Wilcox , Stephen Rothwell , John Hubbard , David Hildenbrand Subject: Re: [syzbot] WARNING in follow_hugetlb_page Message-Id: <20220513171811.3604fb2da04615100c5ed160@linux-foundation.org> In-Reply-To: References: <000000000000ef451a05dee0f2b1@google.com> <00000000000077377c05dee75f63@google.com> <20220513102617.c464c4f566052838e911a3ec@linux-foundation.org> <75f09063-d184-7d44-17a1-ed04be5eb953@oracle.com> <20220513161910.d1b73583cdb2e33562aa86e5@linux-foundation.org> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: F41A11800D6 X-Stat-Signature: 9rbnkzdbs6p1jtspyf1h9nyxhptihy49 X-Rspam-User: Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=pYJQJ1zM; spf=pass (imf16.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org; dmarc=none X-HE-Tag: 1652487486-687656 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 Fri, 13 May 2022 16:54:06 -0700 Minchan Kim wrote: > > > >> has been there over a month so I guess it's something else. Does > > > >> someone have the time to bisect? > > > > > > > > I can recreate in my 'easy to debug' environment, so I can bisect in > > > > parallel with other things I need to do today. > > > > > > > > > > I isolated this to Minchan Kim's "mm: fix is_pinnable_page against on cma > > > page". Yes, the fat finger fix is in next-20220513. > > > > > > I don't have time to analyze right now, but can confirm that in the > > > reproducer is_pinnable_page is returning false after this change when it > > > previously returned true. > > > > OK, thanks, I dropped mm-fix-is_pinnable_page-against-on-cma-page.patch > > Seems like bug of the patch v5 due to change of this > > if (mt & (MIGRATE_CMA | MIGRATE_ISOLATE)) > > The migration type is not bit type so it shold be > > if (mt == MIGRATE_CMA || mt == MIGRATE_ISOLATE) > argh, I meant to check that change but the grey cell died. I'll bring it back, with --- a/include/linux/mm.h~mm-fix-is_pinnable_page-against-on-cma-page-fix +++ a/include/linux/mm.h @@ -1635,7 +1635,7 @@ static inline bool is_pinnable_page(stru int __mt = get_pageblock_migratetype(page); int mt = __READ_ONCE(__mt); - if (mt & (MIGRATE_CMA | MIGRATE_ISOLATE)) + if (mt == MIGRATE_CMA || mt == MIGRATE_ISOLATE) return false; #endif _