From: Michal Hocko <mhocko@suse.com>
To: David Hildenbrand <david@redhat.com>
Cc: "Dave Hansen" <dave.hansen@intel.com>,
"Gerald Schaefer" <gerald.schaefer@linux.ibm.com>,
"akpm@linux-foundation.org" <akpm@linux-foundation.org>,
"Greg KH" <gregkh@linuxfoundation.org>,
"Jan Höppner" <hoeppner@linux.ibm.com>,
"Heiko Carstens" <hca@linux.ibm.com>,
"linux-mm@kvack.org" <linux-mm@kvack.org>,
linux-api@vger.kernel.org,
"Dave Hansen" <dave.hansen@linux.intel.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: Ways to deprecate /sys/devices/system/memory/memoryX/phys_device ?
Date: Fri, 11 Sep 2020 09:20:35 +0200 [thread overview]
Message-ID: <20200911072035.GC7986@dhcp22.suse.cz> (raw)
In-Reply-To: <3E00A442-7107-48DA-8172-EED95F6E1663@redhat.com>
On Thu 10-09-20 22:31:09, David Hildenbrand wrote:
>
>
> > Am 10.09.2020 um 22:01 schrieb Dave Hansen <dave.hansen@intel.com>:
> >
> > On 9/10/20 3:20 AM, David Hildenbrand wrote:
> >> I was just exploring how /sys/devices/system/memory/memoryX/phys_device
> >> is/was used. It's one of these interfaces that most probably never
> >> should have been added but now we are stuck with it.
> >
> > While I'm all for cleanups, what specific problems is phys_device causing?
> >
>
> Mostly stumbling over it, understanding that it is basically unused
> with new userspace for good reason, questioning its existence.
>
> E.g., I am working on virtio-mem support for s390x. Displaying
> misleading/wrong phys_device indications isn‘t particularly helpful
> - especially once there are different ways to hotplug memory for an
> architecture.
>
> > Are you hoping that we can just remove users of memoryX/* until there
> > are no more left, and this is the easiest place to start?
>
> At least reducing it to a minimum with clear semantics. Even with
> automatic onlining there are still reasons why we need to keep the
> interface for now (e.g., reloading kexec to update the kdump headers
> on memory hot(un)plug). But also standby memory handling on s399x
> requires it (->manual onlining).
While I agree that the existing interface is far from ideal, I am not
sure it makes much sense to invest energy into cleaning it up. We can
have a pig with a lipstick but but this will not solve the underlying
problem that we have I believe. The interface doesn't scale with the
block count (especially on some platforms like ppc), it is too
inflexible (single size of the block) and many others. I believe we need
a completely new interface which would effectively deprecate the
existing one. One could still chose to use the old interface but new
usecases would use the new one ideally.
I have brought that up earlier already without much follow up
(http://lkml.kernel.org/r/20200619120704.GD12177@dhcp22.suse.cz)
--
Michal Hocko
SUSE Labs
next prev parent reply other threads:[~2020-09-11 7:20 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-10 10:20 Ways to deprecate /sys/devices/system/memory/memoryX/phys_device ? David Hildenbrand
2020-09-10 20:00 ` Dave Hansen
2020-09-10 20:31 ` David Hildenbrand
2020-09-11 7:20 ` Michal Hocko [this message]
2020-09-11 8:09 ` David Hildenbrand
2020-09-11 9:12 ` Michal Hocko
2020-09-11 10:09 ` David Hildenbrand
2020-09-11 19:24 ` Dave Hansen
2020-09-11 19:35 ` Luck, Tony
2020-09-11 19:56 ` David Hildenbrand
2020-09-11 20:09 ` Luck, Tony
2020-09-11 20:49 ` David Hildenbrand
2020-09-14 11:24 ` Michal Hocko
2020-09-14 12:14 ` David Hildenbrand
2020-09-10 20:57 ` Dave Hansen
2020-09-22 13:56 ` Gerald Schaefer
2020-09-25 14:49 ` David Hildenbrand
2020-09-25 15:00 ` Greg KH
2020-09-25 15:05 ` David Hildenbrand
2020-09-25 15:39 ` Michal Hocko
2020-09-25 15:47 ` David Hildenbrand
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200911072035.GC7986@dhcp22.suse.cz \
--to=mhocko@suse.com \
--cc=akpm@linux-foundation.org \
--cc=dave.hansen@intel.com \
--cc=dave.hansen@linux.intel.com \
--cc=david@redhat.com \
--cc=gerald.schaefer@linux.ibm.com \
--cc=gregkh@linuxfoundation.org \
--cc=hca@linux.ibm.com \
--cc=hoeppner@linux.ibm.com \
--cc=linux-api@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).