public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] hid-elo: kill not flush the work
@ 2016-05-31 12:48 Oliver Neukum
  2016-05-31 15:39 ` Benjamin Tissoires
  2016-06-01 12:10 ` Jiri Kosina
  0 siblings, 2 replies; 3+ messages in thread
From: Oliver Neukum @ 2016-05-31 12:48 UTC (permalink / raw)
  To: jslaby, jikos, linux-input; +Cc: Oliver Neukum, Oliver Neukum, stable

Flushing a work that reschedules itself is not a sensible
operation. It needs to be killed. Failure to do so leads
to a kernel panic in the timer code.

Signed-off-by: Oliver Neukum <ONeukum@suse.com>
CC: stable@vger.kernel.org
---
 drivers/hid/hid-elo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/hid/hid-elo.c b/drivers/hid/hid-elo.c
index aad8c16..0cd4f72 100644
--- a/drivers/hid/hid-elo.c
+++ b/drivers/hid/hid-elo.c
@@ -261,7 +261,7 @@ static void elo_remove(struct hid_device *hdev)
 	struct elo_priv *priv = hid_get_drvdata(hdev);
 
 	hid_hw_stop(hdev);
-	flush_workqueue(wq);
+	cancel_delayed_work_sync(&priv->work);
 	kfree(priv);
 }
 
-- 
2.1.4


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-06-01 12:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-05-31 12:48 [PATCH] hid-elo: kill not flush the work Oliver Neukum
2016-05-31 15:39 ` Benjamin Tissoires
2016-06-01 12:10 ` Jiri Kosina

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox