Re: [PATCH v2] vmalloc: use rcu list iterator to reduce vmap_area_lock contention

From: Eric Dumazet
Date: Wed Jun 11 2014 - 01:43:47 EST


On Tue, 2014-06-10 at 23:32 -0400, Peter Hurley wrote:

> While rcu list traversal over the vmap_area_list is safe, this may
> arrive at different results than the spinlocked version. The rcu list
> traversal version will not be a 'snapshot' of a single, valid instant
> of the entire vmap_area_list, but rather a potential amalgam of
> different list states.
>
> This is because the vmap_area_list can continue to change during
> list traversal.


As soon as we exit from get_vmalloc_info(), information can be obsolete
anyway, especially if we held a spinlock for the whole list traversal.

So using the spinlock is certainly not protecting anything in this
regard.



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