From patchwork Mon Jan 15 07:52:54 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ladislav Michl X-Patchwork-Id: 10163235 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 30C8260325 for ; Mon, 15 Jan 2018 07:53:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 19FEB21E5A for ; Mon, 15 Jan 2018 07:53:01 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0ED6128635; Mon, 15 Jan 2018 07:53:01 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2A7BF21E5A for ; Mon, 15 Jan 2018 07:52:59 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id C1CCA2673D0; Mon, 15 Jan 2018 08:52:58 +0100 (CET) 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 634CA2673D2; Mon, 15 Jan 2018 08:52:57 +0100 (CET) Received: from cvs.linux-mips.org (eddie.linux-mips.org [148.251.95.138]) by alsa0.perex.cz (Postfix) with ESMTP id AE30426731C for ; Mon, 15 Jan 2018 08:52:55 +0100 (CET) Received: (from localhost user: 'ladis' uid#1021 fake: STDIN (ladis@eddie.linux-mips.org)) by eddie.linux-mips.org id S23990477AbeAOHwz3H3hu (ORCPT ); Mon, 15 Jan 2018 08:52:55 +0100 Date: Mon, 15 Jan 2018 08:52:54 +0100 From: Ladislav Michl To: alsa-devel@alsa-project.org Message-ID: <20180115075254.GB10762@lenoch> References: <20180115075213.GA10762@lenoch> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20180115075213.GA10762@lenoch> User-Agent: Mutt/1.9.2 (2017-12-15) Cc: Liam Girdwood , Nicolas Ferre , Takashi Iwai , Mark Brown , Alexandre Belloni , SF Markus Elfring Subject: [alsa-devel] [PATCH 1/5] ASoC: sam9g20_wm8731: use dev_*() logging functions 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP Use dev_*() logging functions instead of plain printk and as messages are now properly prefixed drop 'ASoC' prefix as well. Signed-off-by: Ladislav Michl --- sound/soc/atmel/sam9g20_wm8731.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c index d7469cdd90dc..98f93e79c654 100644 --- a/sound/soc/atmel/sam9g20_wm8731.c +++ b/sound/soc/atmel/sam9g20_wm8731.c @@ -110,16 +110,15 @@ static const struct snd_soc_dapm_route intercon[] = { static int at91sam9g20ek_wm8731_init(struct snd_soc_pcm_runtime *rtd) { struct snd_soc_dai *codec_dai = rtd->codec_dai; + struct device *dev = rtd->dev; int ret; - printk(KERN_DEBUG - "at91sam9g20ek_wm8731 " - ": at91sam9g20ek_wm8731_init() called\n"); + dev_dbg(dev, "%s called\n", __func__); ret = snd_soc_dai_set_sysclk(codec_dai, WM8731_SYSCLK_MCLK, - MCLK_RATE, SND_SOC_CLOCK_IN); + MCLK_RATE, SND_SOC_CLOCK_IN); if (ret < 0) { - printk(KERN_ERR "Failed to set WM8731 SYSCLK: %d\n", ret); + dev_err(dev, "Failed to set WM8731 SYSCLK: %d\n", ret); return ret; } @@ -179,21 +178,21 @@ static int at91sam9g20ek_audio_probe(struct platform_device *pdev) */ mclk = clk_get(NULL, "pck0"); if (IS_ERR(mclk)) { - printk(KERN_ERR "ASoC: Failed to get MCLK\n"); + dev_err(&pdev->dev, "Failed to get MCLK\n"); ret = PTR_ERR(mclk); goto err; } pllb = clk_get(NULL, "pllb"); if (IS_ERR(pllb)) { - printk(KERN_ERR "ASoC: Failed to get PLLB\n"); + dev_err(&pdev->dev, "Failed to get PLLB\n"); ret = PTR_ERR(pllb); goto err_mclk; } ret = clk_set_parent(mclk, pllb); clk_put(pllb); if (ret != 0) { - printk(KERN_ERR "ASoC: Failed to set MCLK parent\n"); + dev_err(&pdev->dev, "Failed to set MCLK parent\n"); goto err_mclk; } @@ -236,7 +235,7 @@ static int at91sam9g20ek_audio_probe(struct platform_device *pdev) ret = snd_soc_register_card(card); if (ret) { - printk(KERN_ERR "ASoC: snd_soc_register_card() failed\n"); + dev_err(&pdev->dev, "snd_soc_register_card() failed\n"); } return ret;