diff options
author | Carolyn Wyborny <carolyn.wyborny@intel.com> | 2013-01-23 03:37:58 +0000 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2013-02-15 01:11:44 -0800 |
commit | d3f8ef1169afb08976b4b1dafe7bc740f655d886 (patch) | |
tree | 530f77d0b9e5f87683c6ed9b5ef29086411a47c3 /drivers | |
parent | 74e238eada573540f82530f8ae4f3343c023d774 (diff) | |
download | linux-d3f8ef1169afb08976b4b1dafe7bc740f655d886.tar.bz2 |
igb: Fix for improper exit in igb_get_i2c_client
This patch fixes an issue where we check for irq's disabled then exit after
explicitly disabling them with spin_lock_irqsave.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com>
Tested-by: Aaron Brown <arron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/intel/igb/igb_main.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c index b070a97376c8..d84f28c683c5 100644 --- a/drivers/net/ethernet/intel/igb/igb_main.c +++ b/drivers/net/ethernet/intel/igb/igb_main.c @@ -7750,12 +7750,7 @@ igb_get_i2c_client(struct igb_adapter *adapter, u8 dev_addr) } } - /* no client_list found, create a new one as long as - * irqs are not disabled - */ - if (unlikely(irqs_disabled())) - goto exit; - + /* no client_list found, create a new one */ client_list = kzalloc(sizeof(*client_list), GFP_KERNEL); if (client_list == NULL) goto exit; |