1
0
Fork 0

ALSA: gus: Delete an error message for a failed memory allocation in snd_gf1_dma_transfer_block()

Omit an extra message for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
hifive-unleashed-5.1
Markus Elfring 2017-11-22 17:43:25 +01:00 committed by Takashi Iwai
parent cdc4398b39
commit 4d0272ca40
1 changed files with 2 additions and 3 deletions

View File

@ -201,10 +201,9 @@ int snd_gf1_dma_transfer_block(struct snd_gus_card * gus,
struct snd_gf1_dma_block *block;
block = kmalloc(sizeof(*block), atomic ? GFP_ATOMIC : GFP_KERNEL);
if (block == NULL) {
snd_printk(KERN_ERR "gf1: DMA transfer failure; not enough memory\n");
if (!block)
return -ENOMEM;
}
*block = *__block;
block->next = NULL;