aboutsummaryrefslogtreecommitdiffstats
path: root/sound/drivers
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2005-09-09 08:22:34 -0400
committerJaroslav Kysela <perex@suse.cz>2005-09-12 04:48:22 -0400
commit561b220a4dece18d67177413e6fa21b49aa4acce (patch)
tree57318610d0b3f97c6193860d7f76dfdb7f743d12 /sound/drivers
parente560d8d8368ad8b6161839984b253de622863265 (diff)
[ALSA] Replace with kzalloc() - others
Documentation,SA11xx UDA1341 driver,Generic drivers,MPU401 UART,OPL3 OPL4,Digigram VX core,I2C cs8427,I2C lib core,I2C tea6330t,L3 drivers AK4114 receiver,AK4117 receiver,PDAudioCF driver,PPC PMAC driver SPARC AMD7930 driver,SPARC cs4231 driver,Synth,Common EMU synth USB generic driver,USB USX2Y Replace kcalloc(1,..) with kzalloc(). Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/drivers')
-rw-r--r--sound/drivers/dummy.c4
-rw-r--r--sound/drivers/mpu401/mpu401_uart.c2
-rw-r--r--sound/drivers/mtpav.c2
-rw-r--r--sound/drivers/opl3/opl3_lib.c2
-rw-r--r--sound/drivers/opl3/opl3_oss.c2
-rw-r--r--sound/drivers/opl4/opl4_lib.c2
-rw-r--r--sound/drivers/serial-u16550.c2
-rw-r--r--sound/drivers/vx/vx_core.c2
-rw-r--r--sound/drivers/vx/vx_pcm.c2
9 files changed, 10 insertions, 10 deletions
diff --git a/sound/drivers/dummy.c b/sound/drivers/dummy.c
index 977d98d26a81..64ef7f62851d 100644
--- a/sound/drivers/dummy.c
+++ b/sound/drivers/dummy.c
@@ -337,7 +337,7 @@ static int snd_card_dummy_playback_open(snd_pcm_substream_t * substream)
337 snd_card_dummy_pcm_t *dpcm; 337 snd_card_dummy_pcm_t *dpcm;
338 int err; 338 int err;
339 339
340 dpcm = kcalloc(1, sizeof(*dpcm), GFP_KERNEL); 340 dpcm = kzalloc(sizeof(*dpcm), GFP_KERNEL);
341 if (dpcm == NULL) 341 if (dpcm == NULL)
342 return -ENOMEM; 342 return -ENOMEM;
343 init_timer(&dpcm->timer); 343 init_timer(&dpcm->timer);
@@ -368,7 +368,7 @@ static int snd_card_dummy_capture_open(snd_pcm_substream_t * substream)
368 snd_card_dummy_pcm_t *dpcm; 368 snd_card_dummy_pcm_t *dpcm;
369 int err; 369 int err;
370 370
371 dpcm = kcalloc(1, sizeof(*dpcm), GFP_KERNEL); 371 dpcm = kzalloc(sizeof(*dpcm), GFP_KERNEL);
372 if (dpcm == NULL) 372 if (dpcm == NULL)
373 return -ENOMEM; 373 return -ENOMEM;
374 init_timer(&dpcm->timer); 374 init_timer(&dpcm->timer);
diff --git a/sound/drivers/mpu401/mpu401_uart.c b/sound/drivers/mpu401/mpu401_uart.c
index 0f83c5241b6b..fe3f921ffbe3 100644
--- a/sound/drivers/mpu401/mpu401_uart.c
+++ b/sound/drivers/mpu401/mpu401_uart.c
@@ -463,7 +463,7 @@ int snd_mpu401_uart_new(snd_card_t * card, int device,
463 *rrawmidi = NULL; 463 *rrawmidi = NULL;
464 if ((err = snd_rawmidi_new(card, "MPU-401U", device, 1, 1, &rmidi)) < 0) 464 if ((err = snd_rawmidi_new(card, "MPU-401U", device, 1, 1, &rmidi)) < 0)
465 return err; 465 return err;
466 mpu = kcalloc(1, sizeof(*mpu), GFP_KERNEL); 466 mpu = kzalloc(sizeof(*mpu), GFP_KERNEL);
467 if (mpu == NULL) { 467 if (mpu == NULL) {
468 snd_device_free(card, rmidi); 468 snd_device_free(card, rmidi);
469 return -ENOMEM; 469 return -ENOMEM;
diff --git a/sound/drivers/mtpav.c b/sound/drivers/mtpav.c
index b8199d20be82..3a25c89d2983 100644
--- a/sound/drivers/mtpav.c
+++ b/sound/drivers/mtpav.c
@@ -688,7 +688,7 @@ static int snd_mtpav_get_RAWMIDI(mtpav_t * mcard)
688 688
689static mtpav_t *new_mtpav(void) 689static mtpav_t *new_mtpav(void)
690{ 690{
691 mtpav_t *ncrd = kcalloc(1, sizeof(*ncrd), GFP_KERNEL); 691 mtpav_t *ncrd = kzalloc(sizeof(*ncrd), GFP_KERNEL);
692 if (ncrd != NULL) { 692 if (ncrd != NULL) {
693 spin_lock_init(&ncrd->spinlock); 693 spin_lock_init(&ncrd->spinlock);
694 694
diff --git a/sound/drivers/opl3/opl3_lib.c b/sound/drivers/opl3/opl3_lib.c
index c313e5205cb8..1f84d78260de 100644
--- a/sound/drivers/opl3/opl3_lib.c
+++ b/sound/drivers/opl3/opl3_lib.c
@@ -354,7 +354,7 @@ int snd_opl3_new(snd_card_t *card,
354 int err; 354 int err;
355 355
356 *ropl3 = NULL; 356 *ropl3 = NULL;
357 opl3 = kcalloc(1, sizeof(*opl3), GFP_KERNEL); 357 opl3 = kzalloc(sizeof(*opl3), GFP_KERNEL);
358 if (opl3 == NULL) 358 if (opl3 == NULL)
359 return -ENOMEM; 359 return -ENOMEM;
360 360
diff --git a/sound/drivers/opl3/opl3_oss.c b/sound/drivers/opl3/opl3_oss.c
index 33da334ae981..21a2b409d6d3 100644
--- a/sound/drivers/opl3/opl3_oss.c
+++ b/sound/drivers/opl3/opl3_oss.c
@@ -241,7 +241,7 @@ static int snd_opl3_load_patch_seq_oss(snd_seq_oss_arg_t *arg, int format,
241 } 241 }
242 242
243 size = sizeof(*put) + sizeof(fm_xinstrument_t); 243 size = sizeof(*put) + sizeof(fm_xinstrument_t);
244 put = kcalloc(1, size, GFP_KERNEL); 244 put = kzalloc(size, GFP_KERNEL);
245 if (put == NULL) 245 if (put == NULL)
246 return -ENOMEM; 246 return -ENOMEM;
247 /* build header */ 247 /* build header */
diff --git a/sound/drivers/opl4/opl4_lib.c b/sound/drivers/opl4/opl4_lib.c
index 8261464dade8..380c2c704c54 100644
--- a/sound/drivers/opl4/opl4_lib.c
+++ b/sound/drivers/opl4/opl4_lib.c
@@ -204,7 +204,7 @@ int snd_opl4_create(snd_card_t *card,
204 if (ropl4) 204 if (ropl4)
205 *ropl4 = NULL; 205 *ropl4 = NULL;
206 206
207 opl4 = kcalloc(1, sizeof(*opl4), GFP_KERNEL); 207 opl4 = kzalloc(sizeof(*opl4), GFP_KERNEL);
208 if (!opl4) 208 if (!opl4)
209 return -ENOMEM; 209 return -ENOMEM;
210 210
diff --git a/sound/drivers/serial-u16550.c b/sound/drivers/serial-u16550.c
index fd3bb9dd1d24..416172ea1f47 100644
--- a/sound/drivers/serial-u16550.c
+++ b/sound/drivers/serial-u16550.c
@@ -779,7 +779,7 @@ static int __init snd_uart16550_create(snd_card_t * card,
779 int err; 779 int err;
780 780
781 781
782 if ((uart = kcalloc(1, sizeof(*uart), GFP_KERNEL)) == NULL) 782 if ((uart = kzalloc(sizeof(*uart), GFP_KERNEL)) == NULL)
783 return -ENOMEM; 783 return -ENOMEM;
784 uart->adaptor = adaptor; 784 uart->adaptor = adaptor;
785 uart->card = card; 785 uart->card = card;
diff --git a/sound/drivers/vx/vx_core.c b/sound/drivers/vx/vx_core.c
index c6fa5afa3e9a..4697b1d75cbb 100644
--- a/sound/drivers/vx/vx_core.c
+++ b/sound/drivers/vx/vx_core.c
@@ -782,7 +782,7 @@ vx_core_t *snd_vx_create(snd_card_t *card, struct snd_vx_hardware *hw,
782 782
783 snd_assert(card && hw && ops, return NULL); 783 snd_assert(card && hw && ops, return NULL);
784 784
785 chip = kcalloc(1, sizeof(*chip) + extra_size, GFP_KERNEL); 785 chip = kzalloc(sizeof(*chip) + extra_size, GFP_KERNEL);
786 if (! chip) { 786 if (! chip) {
787 snd_printk(KERN_ERR "vx_core: no memory\n"); 787 snd_printk(KERN_ERR "vx_core: no memory\n");
788 return NULL; 788 return NULL;
diff --git a/sound/drivers/vx/vx_pcm.c b/sound/drivers/vx/vx_pcm.c
index d4becf44e247..c2312d912fc7 100644
--- a/sound/drivers/vx/vx_pcm.c
+++ b/sound/drivers/vx/vx_pcm.c
@@ -473,7 +473,7 @@ static int vx_alloc_pipe(vx_core_t *chip, int capture,
473 return err; 473 return err;
474 474
475 /* initialize the pipe record */ 475 /* initialize the pipe record */
476 pipe = kcalloc(1, sizeof(*pipe), GFP_KERNEL); 476 pipe = kzalloc(sizeof(*pipe), GFP_KERNEL);
477 if (! pipe) { 477 if (! pipe) {
478 /* release the pipe */ 478 /* release the pipe */
479 vx_init_rmh(&rmh, CMD_FREE_PIPE); 479 vx_init_rmh(&rmh, CMD_FREE_PIPE);