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 B5C10C47077 for ; Thu, 11 Jan 2024 22:46:29 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 1E33A6B0080; Thu, 11 Jan 2024 17:46:29 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 1940F6B008A; Thu, 11 Jan 2024 17:46:29 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 033CC6B0092; Thu, 11 Jan 2024 17:46:28 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id E5CD96B0080 for ; Thu, 11 Jan 2024 17:46:28 -0500 (EST) Received: from smtpin24.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay03.hostedemail.com (Postfix) with ESMTP id C1A3EA083F for ; Thu, 11 Jan 2024 22:46:28 +0000 (UTC) X-FDA: 81668515656.24.1D8E530 Received: from casper.infradead.org (casper.infradead.org [90.155.50.34]) by imf22.hostedemail.com (Postfix) with ESMTP id 78566C000C for ; Thu, 11 Jan 2024 22:46:26 +0000 (UTC) Authentication-Results: imf22.hostedemail.com; dkim=pass header.d=infradead.org header.s=casper.20170209 header.b=EomzbTzJ; dmarc=none; spf=none (imf22.hostedemail.com: domain of willy@infradead.org has no SPF policy when checking 90.155.50.34) smtp.mailfrom=willy@infradead.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1705013187; 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: in-reply-to:in-reply-to:references:references:dkim-signature; bh=0rn15vikwOjPu92WIZ1pOLLnXWU6x//npevyjHw8yaU=; b=D+XQJdx5kqf2+XaEKw3vU6JO72BXwsd5N5abLAajZ0PRd+5pqyEKHbZPIqfkKytxstD/u9 uJxizuYviBKYJ7d7IR9kKeXICSozIBy1gnuPXXMZCWjq4DSaBQQPjEMZ6v4vVXRd/hfwyG q3eHn+/F/w23Xio/BgCtwuSNg96QF60= ARC-Authentication-Results: i=1; imf22.hostedemail.com; dkim=pass header.d=infradead.org header.s=casper.20170209 header.b=EomzbTzJ; dmarc=none; spf=none (imf22.hostedemail.com: domain of willy@infradead.org has no SPF policy when checking 90.155.50.34) smtp.mailfrom=willy@infradead.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1705013187; a=rsa-sha256; cv=none; b=cx5rxj29Qn9Lr939V9AGV1WBFeZLQeVEfRLArnMKenuodGKQs6nO9hHsDslpdXKFU98S1A GYRbY13Idb7aQVwA9OqoGym/12GBqyoao7iKOPv4AKyb5qoA3A7t3PRf7QhznHo94BnzAz BsOqeJR3SX61U0IQJurY4RSFBGLboLk= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=0rn15vikwOjPu92WIZ1pOLLnXWU6x//npevyjHw8yaU=; b=EomzbTzJzQx9U5EbbMaV2qfdKn m+8Aks0QGEeOKbhHlYUfGI0ESzbPCwu4+T1iJwpAMaa+P+8S7WdUdv0uh9VymFzvAlHqWZdS+1v42 VYO+5aZ+YLqzQ9VrPT3bL2J2+Jh26pmRT3GsCtQ+FuTAp5ogzJOhfRTDdZd5nGFmbyHf4Nic43+/j wDbX0twq5Rj7iSd2OySjSEWRPCXpPbuXe/3Q1RVKFIc6G732IcUWMPMXjEy7Po9B7TOpSfuH09+Si ksPBNd2g30LsyFYsilKTNDIkvoFAxmh97MurNp5o/ueUNwULbN3H1vFGwAFhHlhdxkhCRy3J2stsU Y5bchWlg==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1rO3o9-00FAPE-3J; Thu, 11 Jan 2024 22:45:53 +0000 Date: Thu, 11 Jan 2024 22:45:53 +0000 From: Matthew Wilcox To: Andrew Morton Cc: "Darrick J. Wong" , Christoph Hellwig , Hugh Dickins , Chandan Babu R , David Howells , Jarkko Sakkinen , Dave Hansen , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Christian Koenig , Huang Rui , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Tvrtko Ursulin , intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, x86@kernel.org, linux-sgx@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, keyrings@vger.kernel.org Subject: Re: [PATCH 2/2] xfs: disable large folio support in xfile_create Message-ID: References: <20240110092109.1950011-1-hch@lst.de> <20240110092109.1950011-3-hch@lst.de> <20240110175515.GA722950@frogsfrogsfrogs> <20240110200451.GB722950@frogsfrogsfrogs> <20240111140053.51948fb3ed10e06d8e389d2e@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240111140053.51948fb3ed10e06d8e389d2e@linux-foundation.org> X-Rspamd-Queue-Id: 78566C000C X-Rspam-User: X-Rspamd-Server: rspam04 X-Stat-Signature: n4ybkij576gtr7gmnntd4555fybntf1j X-HE-Tag: 1705013186-372444 X-HE-Meta: U2FsdGVkX1+D/gHk9bAKrxHOkKTeWgmXKWICtr6LLKipLgtMO62s9huqmQSPqdKtNCs70Mbl4uXoDrmioXMTXS2RC5OZsK1ZjLAkFSciVBcIB3NT0z3mXIe9CtU5EfVG0U2etmSBbOS7kdKKoLm+goMO8n0wz2ITYYMaMPLkP316Saoyhv/you+iuF+j7EzWMnOrIkE1/VarxLGJS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 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: On Thu, Jan 11, 2024 at 02:00:53PM -0800, Andrew Morton wrote: > On Wed, 10 Jan 2024 12:04:51 -0800 "Darrick J. Wong" wrote: > > > > > Fixing this will require a bit of an API change, and prefeably sorting out > > > > the hwpoison story for pages vs folio and where it is placed in the shmem > > > > API. For now use this one liner to disable large folios. > > > > > > > > Reported-by: Darrick J. Wong > > > > Signed-off-by: Christoph Hellwig > > > > > > Can someone who knows more about shmem.c than I do please review > > > https://lore.kernel.org/linux-xfs/20240103084126.513354-4-hch@lst.de/ > > > so that I can feel slightly more confident as hch and I sort through the > > > xfile.c issues? > > > > > > For this patch, > > > Reviewed-by: Darrick J. Wong > > > > ...except that I'm still getting 2M THPs even with this enabled, so I > > guess either we get to fix it now, or create our own private tmpfs mount > > so that we can pass in huge=never, similar to what i915 does. :( > > What is "this"? Are you saying that $Subject doesn't work, or that the > above-linked please-review patch doesn't work? shmem pays no attention to the mapping_large_folio_support() flag, so the proposed fix doesn't work. It ought to, but it has its own way of doing it that predates mapping_large_folio_support existing.