Re: [PATCH 3/9] parisc: Fix asm/mman.h regarding MAP_HUGETLB and MADV_XX flags

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, 2015-11-21 at 23:22 +0100, Helge Deller wrote:
> Hi Ben,
> 
> On 21.11.2015 21:57, Ben Hutchings wrote:
> > On Fri, 2015-11-20 at 22:38 +0100, Helge Deller wrote:
> > > On parisc we have up to now never supported Huge Pages, even glibc did
> > > not defined MAP_HUGETLB for parisc. Since the Huge Page support is being
> > > added now, clean up existing definitions for MAP_HUGETLB and friends.
> > > 
> > > Drop lots of MADV_xxK_PAGES flags, which were never used and were
> > > designed for a patch which was never integrated into the Linux
> > > kernel. Instead move other MADV_ flags to make them more compatible to
> > > other linux architectures.
> > 
> > Changing the unimplemented values seems fine, but how can it be OK to
> > renumber MAP_GROWSUP, MADV_DONTDUMP and MADV_DODUMP?
> 
> MAP_GROWSUP is new.
> MAP_STACK changed, but doesn't seeem to be used inside the kernel anyway.

It may not be implemented in the kernel, but it is certainly used by
userland:
https://sources.debian.net/src/glibc/2.19-20/nptl/allocatestack.c/#L513

So you can't assign any new semantics to that bit, and you might as
well keep MAP_STACK as the same value.

> MAP_HUGETLB is new.
> 
> MADV_DONTDUMP and MADV_DODUMP changed, but I tend to think that they are
> not widely used (if at all on parisc), and even in glibc they are only
> accessible if applications included .
> So, having the same value for both as all other architectures gives long-term
> probably more benefits than keeping the current values.
[...]

This does not trump the fact that existing applications may break and
that is something we generally try very hard to avoid.

Ben.

-- 
Ben Hutchings
If you seem to know what you are doing, you'll be given more to do.

Attachment: signature.asc
Description: This is a digitally signed message part


[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]