Skip to content

Commit

Permalink
be2net: add unlock on error path
Browse files Browse the repository at this point in the history
The unlock accidentally got removed from the error path in dd131e7:
"be2net: Bug fix to avoid disabling bottom half during firmware upgrade."

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Sarveshwar Bandi <sarveshwarb@serverengines.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Dan Carpenter authored and David S. Miller committed May 29, 2010
1 parent 5daf47b commit 2892d9c
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions drivers/net/benet/be_cmds.c
Original file line number Diff line number Diff line change
Expand Up @@ -1429,7 +1429,7 @@ int be_cmd_write_flashrom(struct be_adapter *adapter, struct be_dma_mem *cmd,
wrb = wrb_from_mccq(adapter);
if (!wrb) {
status = -EBUSY;
goto err;
goto err_unlock;
}
req = cmd->va;
sge = nonembedded_sgl(wrb);
Expand Down Expand Up @@ -1457,7 +1457,10 @@ int be_cmd_write_flashrom(struct be_adapter *adapter, struct be_dma_mem *cmd,
else
status = adapter->flash_status;

err:
return status;

err_unlock:
spin_unlock_bh(&adapter->mcc_lock);
return status;
}

Expand Down

0 comments on commit 2892d9c

Please sign in to comment.