aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/sound
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 /Documentation/sound
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 'Documentation/sound')
-rw-r--r--Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl10
1 files changed, 5 insertions, 5 deletions
diff --git a/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl b/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl
index 0475478c2484..24e85520890b 100644
--- a/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl
+++ b/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl
@@ -447,7 +447,7 @@
447 .... 447 ....
448 448
449 /* allocate a chip-specific data with zero filled */ 449 /* allocate a chip-specific data with zero filled */
450 chip = kcalloc(1, sizeof(*chip), GFP_KERNEL); 450 chip = kzalloc(sizeof(*chip), GFP_KERNEL);
451 if (chip == NULL) 451 if (chip == NULL)
452 return -ENOMEM; 452 return -ENOMEM;
453 453
@@ -949,7 +949,7 @@
949 After allocating a card instance via 949 After allocating a card instance via
950 <function>snd_card_new()</function> (with 950 <function>snd_card_new()</function> (with
951 <constant>NULL</constant> on the 4th arg), call 951 <constant>NULL</constant> on the 4th arg), call
952 <function>kcalloc()</function>. 952 <function>kzalloc()</function>.
953 953
954 <informalexample> 954 <informalexample>
955 <programlisting> 955 <programlisting>
@@ -958,7 +958,7 @@
958 mychip_t *chip; 958 mychip_t *chip;
959 card = snd_card_new(index[dev], id[dev], THIS_MODULE, NULL); 959 card = snd_card_new(index[dev], id[dev], THIS_MODULE, NULL);
960 ..... 960 .....
961 chip = kcalloc(1, sizeof(*chip), GFP_KERNEL); 961 chip = kzalloc(sizeof(*chip), GFP_KERNEL);
962]]> 962]]>
963 </programlisting> 963 </programlisting>
964 </informalexample> 964 </informalexample>
@@ -1136,7 +1136,7 @@
1136 return -ENXIO; 1136 return -ENXIO;
1137 } 1137 }
1138 1138
1139 chip = kcalloc(1, sizeof(*chip), GFP_KERNEL); 1139 chip = kzalloc(sizeof(*chip), GFP_KERNEL);
1140 if (chip == NULL) { 1140 if (chip == NULL) {
1141 pci_disable_device(pci); 1141 pci_disable_device(pci);
1142 return -ENOMEM; 1142 return -ENOMEM;
@@ -1292,7 +1292,7 @@
1292 need to initialize this number as -1 before actual allocation, 1292 need to initialize this number as -1 before actual allocation,
1293 since irq 0 is valid. The port address and its resource pointer 1293 since irq 0 is valid. The port address and its resource pointer
1294 can be initialized as null by 1294 can be initialized as null by
1295 <function>kcalloc()</function> automatically, so you 1295 <function>kzalloc()</function> automatically, so you
1296 don't have to take care of resetting them. 1296 don't have to take care of resetting them.
1297 </para> 1297 </para>
1298 1298