summaryrefslogtreecommitdiffstats
path: root/sound/core
diff options
context:
space:
mode:
Diffstat (limited to 'sound/core')
-rw-r--r--sound/core/memalloc.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/sound/core/memalloc.c b/sound/core/memalloc.c
index 9d93f02c6285..5e1c7bc73b29 100644
--- a/sound/core/memalloc.c
+++ b/sound/core/memalloc.c
@@ -184,11 +184,7 @@ static void snd_malloc_dev_iram(struct snd_dma_buffer *dmab, size_t size)
/* Assign the pool into private_data field */
dmab->private_data = pool;
- dmab->area = (void *)gen_pool_alloc(pool, size);
- if (!dmab->area)
- return;
-
- dmab->addr = gen_pool_virt_to_phys(pool, (unsigned long)dmab->area);
+ dmab->area = gen_pool_dma_alloc(pool, size, &dmab->addr);
}
/**
OpenPOWER on IntegriCloud