aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/core/memalloc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/core/memalloc.c b/sound/core/memalloc.c
index 59a4adc286ed..eb974235c92b 100644
--- a/sound/core/memalloc.c
+++ b/sound/core/memalloc.c
@@ -182,6 +182,8 @@ int snd_dma_alloc_pages(int type, struct device *device, size_t size,
182 return -ENXIO; 182 return -ENXIO;
183 if (WARN_ON(!dmab)) 183 if (WARN_ON(!dmab))
184 return -ENXIO; 184 return -ENXIO;
185 if (WARN_ON(!device))
186 return -EINVAL;
185 187
186 dmab->dev.type = type; 188 dmab->dev.type = type;
187 dmab->dev.dev = device; 189 dmab->dev.dev = device;