]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - sound/core/pcm_compat.c
iommu/vt-d: Apply per pci device pasid table in SVA
[linux.git] / sound / core / pcm_compat.c
index 39d853bfa5ac0a8b88eb802ea12b947c35557a09..946ab080ac00315f6dc818bd4842970820b71029 100644 (file)
@@ -426,7 +426,7 @@ static int snd_pcm_ioctl_xfern_compat(struct snd_pcm_substream *substream,
            get_user(frames, &data32->frames))
                return -EFAULT;
        bufptr = compat_ptr(buf);
-       bufs = kmalloc(sizeof(void __user *) * ch, GFP_KERNEL);
+       bufs = kmalloc_array(ch, sizeof(void __user *), GFP_KERNEL);
        if (bufs == NULL)
                return -ENOMEM;
        for (i = 0; i < ch; i++) {