From patchwork Fri Jun 20 09:59:09 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 4387811 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 36C77BEEAA for ; Fri, 20 Jun 2014 10:13:29 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 4E8DE203AF for ; Fri, 20 Jun 2014 10:13:28 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id 1C2DA20259 for ; Fri, 20 Jun 2014 10:13:27 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 0646626564C; Fri, 20 Jun 2014 12:13:26 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=no version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id 3A37D2650BD; Fri, 20 Jun 2014 12:05:34 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 0503026523B; Fri, 20 Jun 2014 12:05:31 +0200 (CEST) Received: from mail-pb0-f41.google.com (mail-pb0-f41.google.com [209.85.160.41]) by alsa0.perex.cz (Postfix) with ESMTP id 0B350261B1E for ; Fri, 20 Jun 2014 12:03:03 +0200 (CEST) Received: by mail-pb0-f41.google.com with SMTP id ma3so2946855pbc.14 for ; Fri, 20 Jun 2014 03:03:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=WTpbZyuEVb8rojpIDiAFCH3Xaj9Z4M8Ontyars31f50=; b=NpsGB/ZyXyyvGgk7QRpwS52HPVlD6ilTxJfnNwY8eiUD6wMUWKdzJtqCDYru2l2QaN xQOlPYxIvYSDjTZjqW67ImlfBw2PWOFJR/tkv/H/vFczC23N6Y6kvMyZcpUG5raGx6J4 VLWYAAGrG6GLp/vIg/Qgh8yIp9+Kyc5+sXhREizqiWUYNT82HgER93r6XFsobOE/NI7u gMtSv1IVVKI6zQT78lbcLaO+0zRpzmJz8v9kmKPnUmXtkjHxYm44dRIMLeAcIr9JeWiX xitCRDGxo0XomtUCsn6QWu7zOhv02Rafl5ma8lv6pBai7yL9i8W5PduYzcErvWfqDulU EwWw== X-Received: by 10.66.231.139 with SMTP id tg11mr3204658pac.87.1403258583098; Fri, 20 Jun 2014 03:03:03 -0700 (PDT) Received: from linaro.sisodomain.com ([14.140.216.146]) by mx.google.com with ESMTPSA id ha10sm12718305pbd.1.2014.06.20.03.02.59 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 20 Jun 2014 03:03:02 -0700 (PDT) From: Sachin Kamat To: alsa-devel@alsa-project.org Date: Fri, 20 Jun 2014 15:29:09 +0530 Message-Id: <1403258352-8210-13-git-send-email-sachin.kamat@samsung.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1403258352-8210-1-git-send-email-sachin.kamat@samsung.com> References: <1403258352-8210-1-git-send-email-sachin.kamat@samsung.com> Cc: broonie@kernel.org, spk.linux@gmail.com, lgirdwood@gmail.com Subject: [alsa-devel] [PATCH 13/16] ASoC: wm8958: Remove redundant OOM message X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP Let memory subsystem handle the error logging. Signed-off-by: Sachin Kamat Acked-by: Charles Keepax --- sound/soc/codecs/wm8958-dsp2.c | 24 ++++-------------------- 1 file changed, 4 insertions(+), 20 deletions(-) diff --git a/sound/soc/codecs/wm8958-dsp2.c b/sound/soc/codecs/wm8958-dsp2.c index b2ebb104d879..0dada7f0105e 100644 --- a/sound/soc/codecs/wm8958-dsp2.c +++ b/sound/soc/codecs/wm8958-dsp2.c @@ -934,12 +934,8 @@ void wm8958_dsp2_init(struct snd_soc_codec *codec) /* We need an array of texts for the enum API */ wm8994->mbc_texts = kmalloc(sizeof(char *) * pdata->num_mbc_cfgs, GFP_KERNEL); - if (!wm8994->mbc_texts) { - dev_err(wm8994->hubs.codec->dev, - "Failed to allocate %d MBC config texts\n", - pdata->num_mbc_cfgs); + if (!wm8994->mbc_texts) return; - } for (i = 0; i < pdata->num_mbc_cfgs; i++) wm8994->mbc_texts[i] = pdata->mbc_cfgs[i].name; @@ -963,12 +959,8 @@ void wm8958_dsp2_init(struct snd_soc_codec *codec) /* We need an array of texts for the enum API */ wm8994->vss_texts = kmalloc(sizeof(char *) * pdata->num_vss_cfgs, GFP_KERNEL); - if (!wm8994->vss_texts) { - dev_err(wm8994->hubs.codec->dev, - "Failed to allocate %d VSS config texts\n", - pdata->num_vss_cfgs); + if (!wm8994->vss_texts) return; - } for (i = 0; i < pdata->num_vss_cfgs; i++) wm8994->vss_texts[i] = pdata->vss_cfgs[i].name; @@ -993,12 +985,8 @@ void wm8958_dsp2_init(struct snd_soc_codec *codec) /* We need an array of texts for the enum API */ wm8994->vss_hpf_texts = kmalloc(sizeof(char *) * pdata->num_vss_hpf_cfgs, GFP_KERNEL); - if (!wm8994->vss_hpf_texts) { - dev_err(wm8994->hubs.codec->dev, - "Failed to allocate %d VSS HPF config texts\n", - pdata->num_vss_hpf_cfgs); + if (!wm8994->vss_hpf_texts) return; - } for (i = 0; i < pdata->num_vss_hpf_cfgs; i++) wm8994->vss_hpf_texts[i] = pdata->vss_hpf_cfgs[i].name; @@ -1024,12 +1012,8 @@ void wm8958_dsp2_init(struct snd_soc_codec *codec) /* We need an array of texts for the enum API */ wm8994->enh_eq_texts = kmalloc(sizeof(char *) * pdata->num_enh_eq_cfgs, GFP_KERNEL); - if (!wm8994->enh_eq_texts) { - dev_err(wm8994->hubs.codec->dev, - "Failed to allocate %d enhanced EQ config texts\n", - pdata->num_enh_eq_cfgs); + if (!wm8994->enh_eq_texts) return; - } for (i = 0; i < pdata->num_enh_eq_cfgs; i++) wm8994->enh_eq_texts[i] = pdata->enh_eq_cfgs[i].name;