Don't forget to release queue lock when allocation of memory failed.

Submitted by:	Sascha Wildner <saw online de>
Obtained from:	DragonFly
MFC after:	2 weeks
This commit is contained in:
Xin LI 2012-01-03 20:17:35 +00:00
parent 4c995944af
commit 3093cb15fb
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=229416

View File

@ -685,6 +685,7 @@ tws_init_reqs(struct tws_softc *sc, u_int32_t dma_mem_size)
{
if (bus_dmamap_create(sc->data_tag, 0, &sc->reqs[i].dma_map)) {
/* log a ENOMEM failure msg here */
mtx_unlock(&sc->q_lock);
return(FAILURE);
}
sc->reqs[i].cmd_pkt = &cmd_buf[i];