Page MenuHomeFreeBSD

Xen: Make gnttab_list_lock a recursive lock
ClosedPublic

Authored by pratyush on Jul 30 2018, 10:35 AM.
Tags
None
Referenced Files
F174621270: D16505.id46015.diff
Sun, Oct 4, 6:01 PM
Unknown Object (File)
Thu, Sep 17, 11:03 PM
Unknown Object (File)
Thu, Sep 17, 10:12 PM
Unknown Object (File)
Thu, Sep 17, 9:40 PM
Unknown Object (File)
Sep 3 2026, 10:00 AM
Unknown Object (File)
Sep 2 2026, 7:41 PM
Unknown Object (File)
Aug 27 2026, 10:22 AM
Unknown Object (File)
Aug 11 2026, 5:12 PM
Subscribers

Details

Summary

This fixes the panic caused by lock recursion when the 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. So, the callback function is called with the lock held. So, when the client uses any of the grant reference allocation methods get_free_entries() is called, which tries to acquire gnttab_list_lock, causing a recursion on the non-recursive lock.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Jul 30 2018, 11:36 AM
This revision was automatically updated to reflect the committed changes.