diff options
author | Markus Elfring <elfring@users.sourceforge.net> | 2017-08-12 13:09:23 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2017-08-12 17:33:54 -0400 |
commit | f197acd27e9782a317f070e4ec465f5da460afd1 (patch) | |
tree | 1599d60cbc6a6e8ea430c68da0d71344e617f346 | |
parent | a357f3d1ee95953c9f04617f3045838260f3401f (diff) |
ALSA: ca0106: Delete an error message for a failed memory allocation in snd_ca0106_pcm_open_capture_channel()
Omit an extra message for a memory allocation failure in this function.
This issue was detected by using the Coccinelle software.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r-- | sound/pci/ca0106/ca0106_main.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sound/pci/ca0106/ca0106_main.c b/sound/pci/ca0106/ca0106_main.c index 2be30b8b6bc9..cd27b5536654 100644 --- a/sound/pci/ca0106/ca0106_main.c +++ b/sound/pci/ca0106/ca0106_main.c | |||
@@ -660,11 +660,9 @@ static int snd_ca0106_pcm_open_capture_channel(struct snd_pcm_substream *substre | |||
660 | int err; | 660 | int err; |
661 | 661 | ||
662 | epcm = kzalloc(sizeof(*epcm), GFP_KERNEL); | 662 | epcm = kzalloc(sizeof(*epcm), GFP_KERNEL); |
663 | if (epcm == NULL) { | 663 | if (!epcm) |
664 | dev_err(chip->card->dev, | ||
665 | "open_capture_channel: failed epcm alloc\n"); | ||
666 | return -ENOMEM; | 664 | return -ENOMEM; |
667 | } | 665 | |
668 | epcm->emu = chip; | 666 | epcm->emu = chip; |
669 | epcm->substream = substream; | 667 | epcm->substream = substream; |
670 | epcm->channel_id=channel_id; | 668 | epcm->channel_id=channel_id; |