[Devel] [PATCH rh7 v4] tcache: fix use-after-free in tcache_invalidate_node_pages()

Vladimir Davydov vdavydov at virtuozzo.com
Wed Dec 9 03:16:55 PST 2015


On Wed, Dec 09, 2015 at 01:51:21PM +0300, Andrey Ryabinin wrote:
> tcache_invalidate_node_pages() temporarly drops/takes back node->tree_lock.
> Once lock was dropped, we can't continue iterating to the next slot, because
> another thread might remove and free it. If lock was dropped tree iteration
> has to be restarted.
> Wit this patch we also drop the lock iff we need to resched the task.
> 
> https://jira.sw.ru/browse/PSBM-42104
> 
> Signed-off-by: Andrey Ryabinin <aryabinin at virtuozzo.com>

Acked-by: Vladimir Davydov <vdavydov at virtuozzo.com>


More information about the Devel mailing list