mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-23 09:19:51 +00:00
V4L/DVB (5526): Cx88-alsa.c: Use kzalloc
Replacing kmalloc/memset combination with kzalloc. Signed-off-by: vignesh babu <vignesh.babu@wipro.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
This commit is contained in:
parent
3153bd91bf
commit
c42cabefce
1 changed files with 1 additions and 3 deletions
|
@ -414,11 +414,9 @@ static int snd_cx88_hw_params(struct snd_pcm_substream * substream,
|
||||||
|
|
||||||
dprintk(1,"Setting buffer\n");
|
dprintk(1,"Setting buffer\n");
|
||||||
|
|
||||||
buf = kmalloc(sizeof(*buf),GFP_KERNEL);
|
buf = kzalloc(sizeof(*buf),GFP_KERNEL);
|
||||||
if (NULL == buf)
|
if (NULL == buf)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
memset(buf,0,sizeof(*buf));
|
|
||||||
|
|
||||||
|
|
||||||
buf->vb.memory = V4L2_MEMORY_MMAP;
|
buf->vb.memory = V4L2_MEMORY_MMAP;
|
||||||
buf->vb.width = chip->period_size;
|
buf->vb.width = chip->period_size;
|
||||||
|
|
Loading…
Reference in a new issue