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 4FD3DC001E0 for ; Tue, 1 Aug 2023 10:50:26 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 624AF90000A; Tue, 1 Aug 2023 06:50:25 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 5D2218E0002; Tue, 1 Aug 2023 06:50:25 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4C18890000A; Tue, 1 Aug 2023 06:50:25 -0400 (EDT) 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 3183B8E0002 for ; Tue, 1 Aug 2023 06:50:25 -0400 (EDT) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id E98311601D5 for ; Tue, 1 Aug 2023 10:50:24 +0000 (UTC) X-FDA: 81075216768.11.299ACF4 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by imf28.hostedemail.com (Postfix) with ESMTP id 01590C001E for ; Tue, 1 Aug 2023 10:50:22 +0000 (UTC) Authentication-Results: imf28.hostedemail.com; dkim=pass header.d=suse.com header.s=susede1 header.b=Qs1NT0fi; dmarc=pass (policy=quarantine) header.from=suse.com; spf=pass (imf28.hostedemail.com: domain of mhocko@suse.com designates 195.135.220.29 as permitted sender) smtp.mailfrom=mhocko@suse.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1690887023; 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=DMNni1uygKpmlOfS0CM4+7LvDfGsunP1wd6m/Cf8nz4=; b=oVXpIPlp86Sci9jIoEuHwJgYtXD9UJgsvJSMYFkKY2G3bXl3tNgclZcPtahe69GqoMd0M8 OY366NPIQ/H7PXMkyrpEj+cfcMYY0z0SbETY8J8xsrt9SUvpCCYyFWLqKiWvn0W2XzrtUN 3PCMZXz8inE83uwZfsLDe6CSKl2hXA4= ARC-Authentication-Results: i=1; imf28.hostedemail.com; dkim=pass header.d=suse.com header.s=susede1 header.b=Qs1NT0fi; dmarc=pass (policy=quarantine) header.from=suse.com; spf=pass (imf28.hostedemail.com: domain of mhocko@suse.com designates 195.135.220.29 as permitted sender) smtp.mailfrom=mhocko@suse.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1690887023; a=rsa-sha256; cv=none; b=Vj8M77q+bAbqDdiMQw41Zf+mbYMgTrRtAHk4Ubyl/iSXQUy5gBA8l3NCJ6KQVJEaT+1+N2 R0pSuFBmqpkPOZMSFBl7L3+sRhTWOlVroRg/CR6UnMabbaudBMpy8twTMnEEuauoOd6tnI P/MRca6V4iqN0szkrDkQIewCyIQb1JA= Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 3BE911F45A; Tue, 1 Aug 2023 10:50:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1690887021; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=DMNni1uygKpmlOfS0CM4+7LvDfGsunP1wd6m/Cf8nz4=; b=Qs1NT0fi40jArkfQBt+JB2rgbpq62PuX5epJCLPYA7+C42AYS9rAMSKdsQZvGYHFwwGCRc BrHflkN6SSbFsROdjnmmisrLG+lE+cyB1tISOibcy2Ibw71SKCUFt9dpP4/z6zOjXpp5nt bsmqmtk6CfVuInnmEHCDhNoMaYx36qM= Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 2C579139BD; Tue, 1 Aug 2023 10:50:21 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id I+tECm3jyGTLbgAAMHmgww (envelope-from ); Tue, 01 Aug 2023 10:50:21 +0000 Date: Tue, 1 Aug 2023 12:50:20 +0200 From: Michal Hocko To: Aneesh Kumar K V Cc: linux-mm@kvack.org, akpm@linux-foundation.org, mpe@ellerman.id.au, linuxppc-dev@lists.ozlabs.org, npiggin@gmail.com, christophe.leroy@csgroup.eu, Oscar Salvador , David Hildenbrand , Vishal Verma Subject: Re: [PATCH v7 7/7] mm/memory_hotplug: Enable runtime update of memmap_on_memory parameter Message-ID: References: <20230801044116.10674-1-aneesh.kumar@linux.ibm.com> <20230801044116.10674-8-aneesh.kumar@linux.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Rspamd-Server: rspam09 X-Rspamd-Queue-Id: 01590C001E X-Stat-Signature: q8579goucsrrmrbw5ghej4zof1tzj8db X-Rspam-User: X-HE-Tag: 1690887022-371574 X-HE-Meta: U2FsdGVkX1+4w2ZMXxBhjSsM48WRVztIucu59C30waF0VaBA9sxli0V6cVI2gAlhkUK0yv2VB53p2zJ8BVVefSOFZVhF3Rph+M/h0L+uf+xMdqBIfzV3y4N9KqHscR42FyGFfeybZ2CXDRpcbb/XprlLIMGJ/N2emwq3MJp3nuBXG+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-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue 01-08-23 14:58:29, Aneesh Kumar K V wrote: > On 8/1/23 2:28 PM, Michal Hocko wrote: > > On Tue 01-08-23 10:11:16, Aneesh Kumar K.V wrote: > >> Allow updating memmap_on_memory mode after the kernel boot. Memory > >> hotplug done after the mode update will use the new mmemap_on_memory > >> value. > > > > Well, this is a user space kABI extension and as such you should spend > > more words about the usecase. Why we could live with this static and now > > need dynamic? > > > > This enables easy testing of memmap_on_memory feature without a kernel reboot. Testing alone is rather weak argument to be honest. > I also expect people wanting to use that when they find dax kmem memory online > failing because of struct page allocation failures[1]. User could reboot back with > memmap_on_memory=y kernel parameter. But being able to enable it via sysfs makes > the feature much more useful. Sure it can be useful but that holds for any feature, right. The main question is whether this is worth maintaing. The current implementation seems rather trivial which is an argument to have it but are there any risks long term? Have you evaluated a potential long term maintenance cost? There is no easy way to go back and disable it later on without breaking some userspace. All that should be in the changelog! -- Michal Hocko SUSE Labs