From patchwork Wed Apr 8 17:21:24 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabio Estevam X-Patchwork-Id: 6181831 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 5A6FD9F349 for ; Wed, 8 Apr 2015 17:22:25 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7DCE32037A for ; Wed, 8 Apr 2015 17:22:24 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id 38A6B20373 for ; Wed, 8 Apr 2015 17:22:22 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 811C5265755; Wed, 8 Apr 2015 19:22:20 +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_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, 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 D1D5C2654C6; Wed, 8 Apr 2015 19:22:12 +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 3655C2654EF; Wed, 8 Apr 2015 19:22:11 +0200 (CEST) Received: from mail-vn0-f44.google.com (mail-vn0-f44.google.com [209.85.216.44]) by alsa0.perex.cz (Postfix) with ESMTP id 141AD265375 for ; Wed, 8 Apr 2015 19:22:04 +0200 (CEST) Received: by vnbg129 with SMTP id g129so16195903vnb.4 for ; Wed, 08 Apr 2015 10:22:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=mvTAOm7u+eAS2RX4vxpQbFFIxb2B6mNq581LI4+mewQ=; b=CZsh0QH+WYJkfw7oZjdvTMO2UxmWU8qig3zm48RwMxhT89fkWNY4AaE9O41BLj6Xh0 Q99YSy2ewZRC5AW865bHyL99wqah7afczVu4YUrxd7cStwHVC5cIxmaTRLiM4Lew1bs6 OsN22JHvf1NcwKMncuubaqpOcnWhFqsfLkx6msmuxk1n+GL/sY6x0mqO/hCO5JkRDOPI 6teFjUSeV6/1zWJRLEbS7No5UMsS5gJO1frz9TRnpAfjaT34UXUdHezJ7j2pVus1HC/F +/2Re4KdcRWO5ZPPc9oeKiJizmtwlNoJLFEPC6FL6GQAm61G9G8fIRt+P2ut7WUIgqmg 2SfQ== X-Received: by 10.236.25.68 with SMTP id y44mr23832056yhy.4.1428513723085; Wed, 08 Apr 2015 10:22:03 -0700 (PDT) Received: from localhost.localdomain ([177.194.99.89]) by mx.google.com with ESMTPSA id v39sm9501251yhp.13.2015.04.08.10.21.55 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 08 Apr 2015 10:21:57 -0700 (PDT) From: Fabio Estevam To: broonie@kernel.org Date: Wed, 8 Apr 2015 14:21:24 -0300 Message-Id: <1428513684-26577-1-git-send-email-festevam@gmail.com> X-Mailer: git-send-email 1.9.1 Cc: nicoleotsuka@gmail.com, Fabio Estevam , alsa-devel@alsa-project.org, lars@metafoo.de, timur@tabi.org Subject: [alsa-devel] [PATCH v2] ASoC: fsl_ssi: Do not create debugfs directory 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 From: Fabio Estevam Since commit 81c7cfd1b22a0 ("ASoC: Move debugfs registration to the component level") ASoC core code deals with registering debugfs, so we should not be creating the debugfs directory locally in order to avoid the following warning: fsl-ssi-dai 2028000.ssi: ASoC: Failed to create component debugfs directory Signed-off-by: Fabio Estevam --- Changes since v1: - Only remove dir creation/remove as suggested by Mark Brown sound/soc/fsl/fsl_ssi.h | 1 - sound/soc/fsl/fsl_ssi_dbg.c | 13 +++---------- 2 files changed, 3 insertions(+), 11 deletions(-) diff --git a/sound/soc/fsl/fsl_ssi.h b/sound/soc/fsl/fsl_ssi.h index 5065105..68aef90 100644 --- a/sound/soc/fsl/fsl_ssi.h +++ b/sound/soc/fsl/fsl_ssi.h @@ -211,7 +211,6 @@ struct device; #if IS_ENABLED(CONFIG_DEBUG_FS) struct fsl_ssi_dbg { - struct dentry *dbg_dir; struct dentry *dbg_stats; struct { diff --git a/sound/soc/fsl/fsl_ssi_dbg.c b/sound/soc/fsl/fsl_ssi_dbg.c index 5469ffb..46cea84 100644 --- a/sound/soc/fsl/fsl_ssi_dbg.c +++ b/sound/soc/fsl/fsl_ssi_dbg.c @@ -142,22 +142,15 @@ static const struct file_operations fsl_ssi_stats_ops = { int fsl_ssi_debugfs_create(struct fsl_ssi_dbg *ssi_dbg, struct device *dev) { - ssi_dbg->dbg_dir = debugfs_create_dir(dev_name(dev), NULL); - if (!ssi_dbg->dbg_dir) + ssi_dbg->dbg_stats = debugfs_create_file("stats", S_IRUGO, NULL, + ssi_dbg, &fsl_ssi_stats_ops); + if (!ssi_dbg->dbg_stats) return -ENOMEM; - ssi_dbg->dbg_stats = debugfs_create_file("stats", S_IRUGO, - ssi_dbg->dbg_dir, ssi_dbg, &fsl_ssi_stats_ops); - if (!ssi_dbg->dbg_stats) { - debugfs_remove(ssi_dbg->dbg_dir); - return -ENOMEM; - } - return 0; } void fsl_ssi_debugfs_remove(struct fsl_ssi_dbg *ssi_dbg) { debugfs_remove(ssi_dbg->dbg_stats); - debugfs_remove(ssi_dbg->dbg_dir); }