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

Commit be376649 authored by FUJITA Tomonori's avatar FUJITA Tomonori Committed by David S. Miller
Browse files

dbri: check dma_alloc_coherent errors



Needs to check for dma_alloc_coherent() allocation failure.

Signed-off-by: default avatarFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1758ef68
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -2534,6 +2534,8 @@ static int __devinit snd_dbri_create(struct snd_card *card,
	dbri->dma = dma_alloc_coherent(&op->dev,
				       sizeof(struct dbri_dma),
				       &dbri->dma_dvma, GFP_ATOMIC);
	if (!dbri->dma)
		return -ENOMEM;
	memset((void *)dbri->dma, 0, sizeof(struct dbri_dma));

	dprintk(D_GEN, "DMA Cmd Block 0x%p (0x%08x)\n",