expand_stack: small race

Manfred Spraul (manfred@colorfullife.com)
Fri, 04 May 2001 16:20:20 +0200


expand_stack is only protected with down_read(&mmap_sem), and thus 2
thread could grow a vma at the same time.

I think the spin_lock(&page_table_lock) should be moved up before the
calculation of grow.

And map_user_kiobuf() doesn't honor VM_LOCKED for VM_GROWSDOWN segments.
Probably it should be switched to find_extend_vma instead of the
do-it-yourself implementation.

--
	Manfred
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/