Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 8 Sep 2015 19:41:20 +0000 (UTC)
From:      =?UTF-8?Q?Jean-S=c3=a9bastien_P=c3=a9dron?= <dumbbell@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r287573 - head/sys/dev/drm2/ttm
Message-ID:  <201509081941.t88JfKHp061685@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
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);
 }



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201509081941.t88JfKHp061685>