diff options
author | Jia-Ju Bai <baijiaju1990@163.com> | 2015-08-03 05:36:26 +0200 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2015-08-18 23:06:05 +0200 |
commit | 3eb14ea8d9584e96680729c2c7a9129bafa13a39 (patch) | |
tree | a13da4fc1004d5503b3e9c71b736f259deb0ee75 /drivers/net/ethernet | |
parent | e100: Release skb when DMA mapping is failed in e100_xmit_prepare (diff) | |
download | linux-3eb14ea8d9584e96680729c2c7a9129bafa13a39.tar.xz linux-3eb14ea8d9584e96680729c2c7a9129bafa13a39.zip |
igb: Fix a deadlock in igb_sriov_reinit
When igb_init_interrupt_scheme in igb_sriov_reinit is failed, the lock
acquired by rtnl_lock() is not released, which causes a deadlock.
This patch adds rtnl_unlock() 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>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r-- | drivers/net/ethernet/intel/igb/igb_main.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c index 8d22298236ad..17c1c842c33d 100644 --- a/drivers/net/ethernet/intel/igb/igb_main.c +++ b/drivers/net/ethernet/intel/igb/igb_main.c @@ -7413,6 +7413,7 @@ static int igb_resume(struct device *dev) if (igb_init_interrupt_scheme(adapter, true)) { dev_err(&pdev->dev, "Unable to allocate memory for queues\n"); + rtnl_unlock(); return -ENOMEM; } |