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 A04F3ECAAA3 for ; Fri, 26 Aug 2022 02:53:18 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 10A65940007; Thu, 25 Aug 2022 22:53:18 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 0B9856B0075; Thu, 25 Aug 2022 22:53:18 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EEA22940007; Thu, 25 Aug 2022 22:53:17 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id E0A7C6B0074 for ; Thu, 25 Aug 2022 22:53:17 -0400 (EDT) Received: from smtpin30.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id B6A6E406CC for ; Fri, 26 Aug 2022 02:53:17 +0000 (UTC) X-FDA: 79840222434.30.D8FD60F Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by imf02.hostedemail.com (Postfix) with ESMTP id 5F14780002 for ; Fri, 26 Aug 2022 02:53:17 +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 6B615B82EFD; Fri, 26 Aug 2022 02:53:15 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9D998C433C1; Fri, 26 Aug 2022 02:53:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1661482394; bh=5hL+Qohca2z4LHdl33S7reOO2QkPfuDoatK2OM7n0As=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=d50KXlpEz6oFuZgcXJQCIN9nTaOW3jW5BZL/mPuVC8asneQndzzdBiBd9DGOupESS yLZdBpQiLn7nddRZ9MyPfNsUt/mMMZ6YO8V5mcU3ETE14MorNMCIP2sRhfEEkHesTc 7gyRp/hg3vBWJjmJRRzLTZGC9WbuAAGPDHGegx3I= Date: Thu, 25 Aug 2022 19:53:12 -0700 From: Andrew Morton To: Gerald Schaefer Cc: Haiyue Wang , linux-mm@kvack.org, linux-kernel@vger.kernel.org, david@redhat.com, apopple@nvidia.com, linmiaohe@huawei.com, ying.huang@intel.com, songmuchun@bytedance.com, naoya.horiguchi@linux.dev, alex.sierra@amd.com, mike.kravetz@oracle.com, Baolin Wang , Heiko Carstens , Vasily Gorbik , Alexander Gordeev Subject: Re: [PATCH v7 1/2] mm: migration: fix the FOLL_GET failure on following huge page Message-Id: <20220825195312.8490c2c9c0a1c54f43851cfc@linux-foundation.org> In-Reply-To: <20220825143917.32175f7d@thinkpad> References: <20220823135841.934465-1-haiyue.wang@intel.com> <20220823135841.934465-2-haiyue.wang@intel.com> <20220824113858.9f0a2200c4d4875a5f4da31c@linux-foundation.org> <20220825143917.32175f7d@thinkpad> 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 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1661482397; 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-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=PIlY5tgEZUko8l1gMjW90NA+I+y+c0gXxPuqkeSPsvU=; b=rsYW/KhcvyFdk2JENSrtlymExwu9sGlx6W/9Yqg4sk/0Dj8u7IqxSMQswBH0rZZ4Whm8Nk G8sL9vIeY8nrtoA8pHsE5aOhneyi+BtWvRzilyzwxPzgwIKNbnBzAUBDw9KRO7dPPkLH6q SQA6/59eMOuyehM7ZWy5U+JyFxTp5uQ= ARC-Authentication-Results: i=1; imf02.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=d50KXlpE; dmarc=none; spf=pass (imf02.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1661482397; a=rsa-sha256; cv=none; b=6SNGOrtVFdd5YKM0PdnorUGLS/hdkPQ/QJrkrijH7E+MFl+RaMQQ0dtUpe7bXx5o6Ke8eM sIv3AtB+hxyZid7F+5Zy6r40bO8wmvc9LnxBqOh81sjBlj34N9R2vwIkoWMU3EFyjWCK+S WwJtH70fb3WnaiG/qRPPcemllyLV5UY= Authentication-Results: imf02.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=d50KXlpE; dmarc=none; spf=pass (imf02.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org X-Rspam-User: X-Rspamd-Queue-Id: 5F14780002 X-Rspamd-Server: rspam10 X-Stat-Signature: 4bjh17c1cqrm14hmoxc1os61j9qbaoio X-HE-Tag: 1661482397-354144 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 Thu, 25 Aug 2022 14:39:17 +0200 Gerald Schaefer wrote: > On Wed, 24 Aug 2022 11:38:58 -0700 > Andrew Morton wrote: > > > On Tue, 23 Aug 2022 21:58:40 +0800 Haiyue Wang wrote: > > > > > Not all huge page APIs support FOLL_GET option, so move_pages() syscall > > > will fail to get the page node information for some huge pages. > > > > > > Like x86 on linux 5.19 with 1GB huge page API follow_huge_pud(), it will > > > return NULL page for FOLL_GET when calling move_pages() syscall with the > > > NULL 'nodes' parameter, the 'status' parameter has '-2' error in array. > > > > > > Note: follow_huge_pud() now supports FOLL_GET in linux 6.0. > > > Link: https://lore.kernel.org/all/20220714042420.1847125-3-naoya.horiguchi@linux.dev > > > > > > But these huge page APIs don't support FOLL_GET: > > > 1. follow_huge_pud() in arch/s390/mm/hugetlbpage.c > > > 2. follow_huge_addr() in arch/ia64/mm/hugetlbpage.c > > > It will cause WARN_ON_ONCE for FOLL_GET. > > > 3. follow_huge_pgd() in mm/hugetlb.c > > > > What happened to the proposal to fix these three sites so this patch is > > not needed? > > For s390, you can add my patch from > https://lore.kernel.org/linux-mm/20220818135717.609eef8a@thinkpad/ > to this series. > Thanks, I added that.