Re: [RFC] mlock/stack guard interaction fixup

From: Ian Campbell
Date: Sun Aug 22 2010 - 03:33:22 EST


On Sun, 2010-08-22 at 07:57 +0100, Ian Campbell wrote:
> On Sat, 2010-08-21 at 08:48 -0700, Linus Torvalds wrote:
> > On Sat, Aug 21, 2010 at 4:56 AM, Ian Campbell <ijc@xxxxxxxxxxxxxx> wrote:
> > >
> > > I don't know that they are particularly good tests for this change but I
> > > also ran allmodconfig kernel build and ltp on 2.6.35.3+fixes without
> > > issue. Are there any good mlock heavy workloads?
> >
> > mlock itself isn't very interesting, I think more interesting is
> > testing that the doubly linked list handles all the cases correctly.
> > Something that splits mappings, unmaps partial ones etc etc. Running
> > something like Electric Fence is probably a good idea.
>
> EF_DISABLE_BANNER=1 EF_ALLOW_MALLOC_0=1 LD_PRELOAD=libefence.so.0.0 make
>
> craps out pretty quickly with:
>
> CC init/main.o
>
> ElectricFence Exiting: mprotect() failed: Cannot allocate memory
> make[1]: *** [init/main.o] Error 255
> make: *** [init] Error 2
>
> but it does that with 2.6.35.3, 2.6.35.2, 2.6.35.1 and 2.6.35 too so it
> doesn't seem to be breakage relating to any of the stack guard stuff

I increased the vm.max_map_count sysctl and now things are rolling
along. Will let you know how I get on.

--
Ian Campbell

Arithmetic:
An obscure art no longer practiced in the world's developed countries.

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