Skip to contentSkip to conversation

vxge: add missing flush of reset_task

PATCH In review Tejun Heo 3 participants 3 messages Dec 15, 2010 – Dec 20, 2010

Subsystems (2)
lore
Share & tools
lore

Tejun Heo

author
#0 lore raw

PATCH 1/1 vxge: add missing flush of reset_task

Commit 6e07ebd84 (drivers/net: remove unnecessary flush_scheduled_work() calls) incorrectly removed the flush call without replacing it with the appropriate work specific operation. Fix it by flushing vdev->reset_task explicitly.

Pointed out by Jon Mason.

---
 drivers/net/vxge/vxge-main.c |    2 ++
 1 file changed, 2 insertions(+)
drivers/net/vxge/vxge-main.c +2 -0
index 537ad87..1ac9b56 100644
@@ -3439,6 +3439,8 @@ static void vxge_device_unregister(struct __vxge_hw_device *hldev)
 
 	strncpy(buf, dev->name, IFNAMSIZ);
 
+	flush_work_sync(&vdev->reset_task);
+
 	/* in 2.6 will call stop() if device is up */
 	unregister_netdev(dev);
Acked-by on v1 1/1
#1 lore raw
Quoted 9 lines · Tejun Heo

Commit 6e07ebd84 (drivers/net: remove unnecessary flush_scheduled_work() calls) incorrectly removed the flush call without replacing it with the appropriate work specific operation. Fix it by flushing vdev->reset_task explicitly.

Pointed out by Jon Mason.

Quoted 17 lines
---
 drivers/net/vxge/vxge-main.c |    2 ++
 1 file changed, 2 insertions(+)
drivers/net/vxge/vxge-main.c +2 -0
index 537ad87..1ac9b56 100644
@@ -3439,6 +3439,8 @@ static void vxge_device_unregister(struct __vxge_hw_device *hldev)
 
 	strncpy(buf, dev->name, IFNAMSIZ);
 
+	flush_work_sync(&vdev->reset_task);
+
 	/* in 2.6 will call stop() if device is up */
 	unregister_netdev(dev);
 
maintainer
#2 lore raw

From: Jon Mason <[email protected]>
Date: Wed, 15 Dec 2010 08:29:00 -0600

Quoted 11 lines · Tejun Heo
Quoted 9 lines

Commit 6e07ebd84 (drivers/net: remove unnecessary flush_scheduled_work() calls) incorrectly removed the flush call without replacing it with the appropriate work specific operation. Fix it by flushing vdev->reset_task explicitly.

Pointed out by Jon Mason.

I'll apply this, thanks.