Home
last modified time | relevance | path

Searched hist:"5477025 a1036bc369839c769ab9fb4dd3362cfd3" (Results 1 – 1 of 1) sorted by relevance

/freebsd/sys/dev/xen/grant_table/
H A Dgrant_table.cdiff 5477025a1036bc369839c769ab9fb4dd3362cfd3 Mon Jul 30 13:41:51 CEST 2018 Roger Pau Monné <royger@FreeBSD.org> xen/grants: fix deadlocks in the free callbacks

This fixes the panic caused by deadlocking when grant-table free
callbacks are used.

The cause of the recursion is: check_free_callbacks() is always called
with the lock gnttab_list_lock held. In turn the callback function is
also called with the lock held. Then when the client uses any of the grant
reference methods which also attempt the lock the gnttab_list_lock
mutex from within the free callback a deadlock happens.

Fix this by making the gnttab_list_lock recursive.

Submitted by: Pratyush Yadav <pratyush@freebsd.org>
Differential Revision: https://reviews.freebsd.org/D16505