Author: dumbbell
Date: Tue Sep  8 19:41:19 2015
New Revision: 287573
URL: https://svnweb.freebsd.org/changeset/base/287573

Log:
  drm/ttm: Drain taskqueue if taskqueue_cancel_timeout() returned an error
  
  Before, this was done if `pending` was true. This is not what the
  manpage suggests and not what was done elsewhere in the same file.

Modified:
  head/sys/dev/drm2/ttm/ttm_bo.c

Modified: head/sys/dev/drm2/ttm/ttm_bo.c
==============================================================================
--- head/sys/dev/drm2/ttm/ttm_bo.c      Tue Sep  8 19:25:15 2015        
(r287572)
+++ head/sys/dev/drm2/ttm/ttm_bo.c      Tue Sep  8 19:41:19 2015        
(r287573)
@@ -789,8 +789,7 @@ int ttm_bo_lock_delayed_workqueue(struct
 {
        int pending;
 
-       taskqueue_cancel_timeout(taskqueue_thread, &bdev->wq, &pending);
-       if (pending)
+       if (taskqueue_cancel_timeout(taskqueue_thread, &bdev->wq, &pending))
                taskqueue_drain_timeout(taskqueue_thread, &bdev->wq);
        return (pending);
 }
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to