Hold the lock while we save/restore register for suspend/resume.
MFC after: 3 days
This commit is contained in:
parent
0808d0b1a6
commit
e2c228d3d4
@ -52,7 +52,10 @@ static int i915_suspend(device_t kdev)
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
DRM_LOCK();
|
||||
DRM_DEBUG("starting suspend\n");
|
||||
i915_save_state(dev);
|
||||
DRM_UNLOCK();
|
||||
|
||||
return (bus_generic_suspend(kdev));
|
||||
}
|
||||
@ -61,7 +64,10 @@ static int i915_resume(device_t kdev)
|
||||
{
|
||||
struct drm_device *dev = device_get_softc(kdev);
|
||||
|
||||
DRM_LOCK();
|
||||
i915_restore_state(dev);
|
||||
DRM_DEBUG("finished resume\n");
|
||||
DRM_UNLOCK();
|
||||
|
||||
return (bus_generic_resume(kdev));
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user