| 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.  

Sukadev

_______________________________________________
Containers mailing list
[email protected]
https://lists.linux-foundation.org/mailman/listinfo/containers

_______________________________________________
Devel mailing list
[email protected]
https://openvz.org/mailman/listinfo/devel

Reply via email to