From: Michal Hocko <mhocko@kernel.org>
To: Davidlohr Bueso <dave@stgolabs.net>
Cc: akpm@linux-foundation.org, manfred@colorfullife.com,
linux-kernel@vger.kernel.org, linux-mm@kvack.org,
Davidlohr Bueso <dbueso@suse.de>
Subject: Re: [PATCH 4/4] mm,hugetlb: compute page_size_log properly
Date: Mon, 20 Feb 2017 17:11:58 +0100 [thread overview]
Message-ID: <20170220161157.GO2431@dhcp22.suse.cz> (raw)
In-Reply-To: <20170210165111.GB2392@linux-80c1.suse>
Sorry for a late reply, I wasn't online last week
On Fri 10-02-17 08:51:11, Davidlohr Bueso wrote:
> On Fri, 10 Feb 2017, Michal Hocko wrote:
>
> > On Thu 09-02-17 12:53:02, Davidlohr Bueso wrote:
> > > The SHM_HUGE_* stuff was introduced in:
> > >
> > > 42d7395feb5 (mm: support more pagesizes for MAP_HUGETLB/SHM_HUGETLB)
> > >
> > > It unnecessarily adds another layer, specific to sysv shm, without
> > > anything special about it: the macros are identical to the MAP_HUGE_*
> > > stuff, which in turn does correctly describe the hugepage subsystem.
> > >
> > > One example of the problems with extra layers what this patch fixes:
> > > mmap_pgoff() should never be using SHM_HUGE_* logic. It is obviously
> > > harmless but it would still be grand to get rid of it -- although
> > > now in the manpages I don't see that happening.
> >
> > Can we just drop SHM_HUGE_MASK altogether? It is not exported in uapi
> > headers AFAICS.
>
> Yeah that was my original idea, however I noticed that shmget.2 mentions
> kernel internals as part of SHM_HUGE_{2MB,1GB}, ie: SHM_HUGE_SHIFT. So
> dropping _MASK doesn't make sense if we are going to keep _SHIFT.
I am not sure I understand.
$ git grep SHM_HUGE_ include/uapi/
$
So there doesn't seem to be any user visible constant. The man page
mentiones is but I do not really see how is the userspace supposed to
use it.
--
Michal Hocko
SUSE Labs
next prev parent reply other threads:[~2017-02-20 16:12 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-09 20:52 [PATCH -tip 0/4] ipc/shm: moar updates for v4.11 Davidlohr Bueso
2017-02-09 20:52 ` [PATCH 1/4] ipc/shm: do not check for MAP_POPULATE Davidlohr Bueso
2017-02-10 2:15 ` Hugh Dickins
2017-02-13 18:14 ` Davidlohr Bueso
2017-02-09 20:53 ` [PATCH 2/4] ipc/shm: some shmat cleanups Davidlohr Bueso
2017-02-09 20:53 ` [PATCH 3/4] sysv,ipc: cacheline align kern_ipc_perm Davidlohr Bueso
2017-02-09 20:53 ` [PATCH 4/4] mm,hugetlb: compute page_size_log properly Davidlohr Bueso
2017-02-10 10:20 ` Michal Hocko
2017-02-10 16:51 ` Davidlohr Bueso
2017-02-20 16:11 ` Michal Hocko [this message]
2017-02-22 16:03 ` Davidlohr Bueso
2017-02-22 16:11 ` Michal Hocko
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=20170220161157.GO2431@dhcp22.suse.cz \
--to=mhocko@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=dave@stgolabs.net \
--cc=dbueso@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=manfred@colorfullife.com \
/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).