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 2C122C43334 for ; Fri, 24 Jun 2022 20:46:27 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7CD878E0275; Fri, 24 Jun 2022 16:46:26 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 77D338E0244; Fri, 24 Jun 2022 16:46:26 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 644D88E0275; Fri, 24 Jun 2022 16:46:26 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 527B38E0244 for ; Fri, 24 Jun 2022 16:46:26 -0400 (EDT) Received: from smtpin10.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay13.hostedemail.com (Postfix) with ESMTP id 289F560B7A for ; Fri, 24 Jun 2022 20:46:26 +0000 (UTC) X-FDA: 79614312372.10.2FA5763 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf26.hostedemail.com (Postfix) with ESMTP id B65D8140020 for ; Fri, 24 Jun 2022 20:46:23 +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 dfw.source.kernel.org (Postfix) with ESMTPS id CD004622FF; Fri, 24 Jun 2022 20:46:22 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 00D7FC34114; Fri, 24 Jun 2022 20:46:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1656103582; bh=Mv0DwG40qakcxkkt6qyPkfCClSoLRh0fG7vXkt6+2nA=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=CHIzGw+qeT2LvNdHhLnCnf8RjvXrtczfsGYYpk4+UJ8rKQDnVnu+PzSjfMbwNsCzV 01nkn+oyhbogTmx9XW5BptT/mhXXysSjOiUoxxzE22g294qi2ly2+F8yJXYA9OXYWc oOxosfVtOgu2kZbQ7QromA7KRDbq4nseOIbevjn4= Date: Fri, 24 Jun 2022 13:46:21 -0700 From: Andrew Morton To: "Gowans, James" Cc: "linux-mm@kvack.org" , "christian.koenig@amd.com" , "linux-kernel@vger.kernel.org" , =?ISO-8859-1?Q?Sch=F6nherr@kvack.org, ?= Jan H. , "thomas.hellstrom@linux.intel.com" Subject: Re: [PATCH] mm: Split huge PUD on wp_huge_pud fallback Message-Id: <20220624134621.ddab5146060f71ed93019d00@linux-foundation.org> In-Reply-To: <6f48d622eb8bce1ae5dd75327b0b73894a2ec407.camel@amazon.com> References: <6f48d622eb8bce1ae5dd75327b0b73894a2ec407.camel@amazon.com> 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-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1656103583; a=rsa-sha256; cv=none; b=SapK5kx4Vzz3tcSdcLFrGt4in3ur7vQw2E1k97qrRamIex2uc/++vILjdYsVmi2b8t1zAZ cpdCkDSi8RvGR+tgeRGb/bV7s0G/fH5MdMUqGJwZRXBX24si+79llk0mg4oVHFTRnmgWRc rXGq2zMksD5GWyXFkjAgj/oCyAukEns= ARC-Authentication-Results: i=1; imf26.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=CHIzGw+q; dmarc=none; spf=pass (imf26.hostedemail.com: domain of akpm@linux-foundation.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1656103583; 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=DhSYHS7FakKdLVYyMZprUYE1oMWBdeB/Es1Du7izMew=; b=qqkFmHFrMF9psR8lxEkreatk1c8qX8skAYK++7ffhBDDxaTRuXOkY3CS0625WyoqYf8xNq eAjAc0UF8NHCx4dswHDxJWeSAgHQmvK+kdvZx586n5KesgdZVyV4N6JbvXxb9oS3Wakyo5 AnI+FYQ7aivb+3FKXf9rrNSNcEdjdls= X-Stat-Signature: n45hgbsp58gaanq74dj7o8oznpxco6yd X-Rspamd-Queue-Id: B65D8140020 Authentication-Results: imf26.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=CHIzGw+q; dmarc=none; spf=pass (imf26.hostedemail.com: domain of akpm@linux-foundation.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org X-Rspamd-Server: rspam10 X-Rspam-User: X-HE-Tag: 1656103583-178588 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, 23 Jun 2022 05:24:03 +0000 "Gowans, James" wrote: > Currently the implementation will split the PUD when a fallback is taken > inside the create_huge_pud function. This isn't where it should be done: > the splitting should be done in wp_huge_pud, just like it's done for > PMDs. Reason being that if a callback is taken during create, there is > no PUD yet so nothing to split, whereas if a fallback is taken when > encountering a write protection fault there is something to split. > > It looks like this was the original intention with the commit where the > splitting was introduced, but somehow it got moved to the wrong place > between v1 and v2 of the patch series. Rebase mistake perhaps. Thanks. What are the user-visible runtime effects of this change?