summaryrefslogtreecommitdiffstats
path: root/sound/core/control.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/core/control.c')
-rw-r--r--sound/core/control.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/sound/core/control.c b/sound/core/control.c
index e1d8e0c816f0..833b223a363a 100644
--- a/sound/core/control.c
+++ b/sound/core/control.c
@@ -217,10 +217,8 @@ static int snd_ctl_new(struct snd_kcontrol **kctl, unsigned int count,
size += sizeof(struct snd_kcontrol_volatile) * count;
*kctl = kzalloc(size, GFP_KERNEL);
- if (*kctl == NULL) {
- pr_err("ALSA: Cannot allocate control instance\n");
+ if (!*kctl)
return -ENOMEM;
- }
for (idx = 0; idx < count; idx++) {
(*kctl)->vd[idx].access = access;