e1000e: Cleanup qos request in error handling of e1000_open
authorJia-Ju Bai <baijiaju1990@163.com>
Thu, 4 Jun 2015 13:07:27 +0000 (21:07 +0800)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Thu, 23 Jul 2015 12:03:59 +0000 (05:03 -0700)
The driver lacks pm_qos_remove_request in error handling (err_req_irq) of
e1000_open, and qos request inserted by pm_qos_add_request is not removed.
This patch add pm_qos_remove_request in error handling to fix it.

Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/e1000e/netdev.c

index 89d788d8f263e5c362c10166dc76fa59f517e12c..fea1601f32a3614122a75e03fd98e786cab2ac2a 100644 (file)
@@ -4588,6 +4588,7 @@ static int e1000_open(struct net_device *netdev)
        return 0;
 
 err_req_irq:
+       pm_qos_remove_request(&adapter->pm_qos_req);
        e1000e_release_hw_control(adapter);
        e1000_power_down_phy(adapter);
        e1000e_free_rx_resources(adapter->rx_ring);