Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 31 Jul 2003 00:02:23 +0000
From:      Bosko Milekic <bmilekic@technokratis.com>
To:        Bosko Milekic <bmilekic@FreeBSD.org>
Cc:        cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sys/alpha/alpha pmap.c src/sys/amd64/amd64 pmap.c src/sys/i386/i386 pmap.c src/sys/ia64/ia64 pmap.c src/sys/powerpc/powerpc pmap.c
Message-ID:  <20030731000223.GA5840@technokratis.com>
In-Reply-To: <200307310339.h6V3dpH9006124@repoman.freebsd.org>
References:  <200307310339.h6V3dpH9006124@repoman.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

On Wed, Jul 30, 2003 at 08:39:51PM -0700, Bosko Milekic wrote:
> bmilekic    2003/07/30 20:39:51 PDT
> 
>   FreeBSD src repository
> 
>   Modified files:
>     sys/alpha/alpha      pmap.c 
>     sys/amd64/amd64      pmap.c 
>     sys/i386/i386        pmap.c 
>     sys/ia64/ia64        pmap.c 
>     sys/powerpc/powerpc  pmap.c 
>   Log:
>   Make sure that when the PV ENTRY zone is created in pmap, that it's
>   created not only with UMA_ZONE_VM but also with UMA_ZONE_NOFREE.  In
>   the i386 case in particular, the pmap code would hook a special
>   page allocation routine that allocated from kernel_map and not kmem_map,
>   and so when/if the pageout daemon drained the zones, it could actually
>   push out slabs from the PV ENTRY zone but call UMA's default page_free,
>   which resulted in pages allocated from kernel_map being freed to
>   kmem_map; bad.  kmem_free() ignores the return value of the
>   vm_map_delete and just returns.  I'm not sure what the exact
>   repercussions could be, but it doesn't look good.
>   
>   In the PAE case on i386, we also set-up a zone in pmap, so be
>   conservative for now and make that zone also ZONE_NOFREE and
>   ZONE_VM.  Do this for the pmap zones for the other archs too,
>   although in some cases it may not be entirely necessarily.  We'd
>   rather be safe than sorry at this point.
>   
>   Perhaps all UMA_ZONE_VM zones should by default be also
>   UMA_ZONE_NOFREE?
>   
>   May fix some of silby's crashes on the PV ENTRY zone.

  FWIW, we also need to look and make sure the UMA_ZONE_VM actually
  explicitly ensures that slabs are never allocated from the slabzone so
  as to result in a call to the VM in some cases.  If the slab is stored
  in the allocated page this should not be an issue but if it's
  allocated apart from slabzone then it can be an issue; just like
  allocating a bucket from the bucketzone and going to VM is illegal for
  UMA_ZONE_VM, this should be too.  UMA_ZONE_OFFPAGE could help here but
  I don't think that its functionality is completely implemented (iirc,
  it's mostly ignored).

-- 
Bosko Milekic  *  bmilekic@technokratis.com  *  bmilekic@FreeBSD.org
TECHNOkRATIS Consulting Services  *  http://www.technokratis.com/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030731000223.GA5840>