Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

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

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
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -3236,9 +3236,10 @@ bnad_init(struct bnad *bnad,

	sprintf(bnad->wq_name, "%s_wq_%d", BNAD_NAME, bnad->id);
	bnad->work_q = create_singlethread_workqueue(bnad->wq_name);

	if (!bnad->work_q)
	if (!bnad->work_q) {
		iounmap(bnad->bar0);
		return -ENOMEM;
	}

	return 0;
}