Commit ba21fc69 authored by Wei Yongjun's avatar Wei Yongjun Committed by David S. Miller

bna: add missing iounmap() on error in bnad_init()

Add the missing iounmap() before return from bnad_init()
in the error handling case.
Introduced by commit 01b54b14
(bna: tx rx cleanup fix).
Signed-off-by: default avatarWei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent ef380794
...@@ -3236,9 +3236,10 @@ bnad_init(struct bnad *bnad, ...@@ -3236,9 +3236,10 @@ bnad_init(struct bnad *bnad,
sprintf(bnad->wq_name, "%s_wq_%d", BNAD_NAME, bnad->id); sprintf(bnad->wq_name, "%s_wq_%d", BNAD_NAME, bnad->id);
bnad->work_q = create_singlethread_workqueue(bnad->wq_name); bnad->work_q = create_singlethread_workqueue(bnad->wq_name);
if (!bnad->work_q) {
if (!bnad->work_q) iounmap(bnad->bar0);
return -ENOMEM; return -ENOMEM;
}
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment