diff options
author | Nicholas Mc Guire <hofrat@osadl.org> | 2015-12-19 15:23:13 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2015-12-20 22:31:02 +0100 |
commit | 46325371b230cc66c743925c930a17e7d0b8211e (patch) | |
tree | 5d35b578f515bae99f1c5860d893d36b1355caf5 /sound/core | |
parent | bcb337d166044cf389d3b9d3e6063c1ec4ca685d (diff) | |
download | linux-46325371b230cc66c743925c930a17e7d0b8211e.tar.gz linux-46325371b230cc66c743925c930a17e7d0b8211e.tar.bz2 linux-46325371b230cc66c743925c930a17e7d0b8211e.zip |
ALSA: oss: consolidate kmalloc/memset 0 call to kzalloc
This is an API consolidation only. The use of kmalloc + memset to 0
is equivalent to kzalloc.
Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/core')
-rw-r--r-- | sound/core/oss/pcm_oss.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sound/core/oss/pcm_oss.c b/sound/core/oss/pcm_oss.c index e557dbe469f4..0e73d03b30e3 100644 --- a/sound/core/oss/pcm_oss.c +++ b/sound/core/oss/pcm_oss.c @@ -851,7 +851,7 @@ static int snd_pcm_oss_change_params(struct snd_pcm_substream *substream) if (mutex_lock_interruptible(&runtime->oss.params_lock)) return -EINTR; - sw_params = kmalloc(sizeof(*sw_params), GFP_KERNEL); + sw_params = kzalloc(sizeof(*sw_params), GFP_KERNEL); params = kmalloc(sizeof(*params), GFP_KERNEL); sparams = kmalloc(sizeof(*sparams), GFP_KERNEL); if (!sw_params || !params || !sparams) { @@ -989,7 +989,6 @@ static int snd_pcm_oss_change_params(struct snd_pcm_substream *substream) goto failure; } - memset(sw_params, 0, sizeof(*sw_params)); if (runtime->oss.trigger) { sw_params->start_threshold = 1; } else { |