[Devel] Re: [RFC][PATCH 1/7] Factor out code to allocate pidmap page

Sukadev Bhattiprolu sukadev at linux.vnet.ibm.com
Mon May 4 11:27:43 PDT 2009

| OK, I'm having trouble not with your patch but the original code. This
| test of map->page outside the spinlock looks like an incorrect fix to a
| race. If map->page can be NULL right after we release the lock then it
| can become NULL after this test just as easily.

The map->page is not freed once allocated (free_pidmap() does not free
the page). I guess the point is if you exceeded 32K pids (one page worth
of pids) once, you would exceed it again; so no point freeing the page
and reallocating the next time.  


Containers mailing list
Containers at lists.linux-foundation.org

More information about the Devel mailing list