git: drm - Fix lock order reversal
dillon at crater.dragonflybsd.org
Fri Nov 18 22:00:10 PST 2016
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date: Fri Nov 18 21:55:50 2016 -0800
drm - Fix lock order reversal
* Lock order reversal caused by holding dev_pager_mtx() across
the object->un_pager.devp.ops->cdev_pg_dtor() call. devpgr -> drmslk.
* Move the lock from before to after the call. Holding the mutex shouldn't
be necessary across the call. This also fixes the reversal as devpgr is
no longer held across the call.
* Fixes a lock order reversal against drm_ioctl() which obtains drmslk first
and recurses into a device pager operation which gets devpgr.
* Fix a few other incidental bugs that would normally not be triggered by
the DRM code due to outer locks held by the DRM code. Plus some formatting
Summary of changes:
sys/vm/device_pager.c | 33 ++++++++++++++++++++++-----------
1 file changed, 22 insertions(+), 11 deletions(-)
DragonFly BSD source repository
More information about the Commits