video: tegra: dc: use cancel_delayed_work_sync()
Deepak Nibade [Tue, 22 Oct 2013 13:00:27 +0000 (18:00 +0530)]
- nvhdcp driver uses flush_workqueue()
- instead make use of cancel_delayed_work_sync() since
  work scheduled is delayed work

Bug 1308191

Change-Id: I40f841c417cda9b6f40bb9da5c86c0b8944807e9
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/302383
(cherry picked from commit 058f6085fe89ba3eb4f8cececa42af3dc781c084)
Reviewed-on: http://git-master/r/353592
Reviewed-by: Harry Hong <hhong@nvidia.com>
Tested-by: Harry Hong <hhong@nvidia.com>

drivers/video/tegra/dc/nvhdcp.c

index 443b3dd..a4ca44c 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * drivers/video/tegra/dc/nvhdcp.c
  *
- * Copyright (c) 2010-2013, NVIDIA CORPORATION, All rights reserved.
+ * Copyright (c) 2010-2014, NVIDIA CORPORATION, All rights reserved.
  *
  * This software is licensed under the terms of the GNU General Public
  * License version 2, as published by the Free Software Foundation, and
@@ -1078,7 +1078,7 @@ static int tegra_nvhdcp_off(struct tegra_nvhdcp *nvhdcp)
        nvhdcp->state = STATE_OFF;
        mutex_unlock(&nvhdcp->lock);
        wake_up_interruptible(&wq_worker);
-       flush_workqueue(nvhdcp->downstream_wq);
+       cancel_delayed_work_sync(&nvhdcp->work);
        return 0;
 }