From patchwork Wed Aug 21 18:58:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 11108043 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3FA36912 for ; Wed, 21 Aug 2019 18:59:39 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 62DFD2339F for ; Wed, 21 Aug 2019 18:59:38 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="pbUfsfDV" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 62DFD2339F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 2F6CA857; Wed, 21 Aug 2019 20:58:46 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 2F6CA857 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1566413976; bh=gRdn5wSAR9KtDZOw0S3Vbo3hhvqjgv4A45RdbY9YwAU=; h=From:To:Date:Cc:Subject:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From; b=pbUfsfDVTKEMXXL7E0yX2RVSqxtTxnZFx2mj16z8n+GyVvwVRaC66/aQsPpgi6BRf +dvsvXrcW9jxkvefS7Voca4JriAKDwyX0zqg2osP5q3pDfI45X4LOAy/R5jybQEadH jFxWGUvMUUpaMLlJlNW12QMsdfChf7Iqng/iHid4= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id B9A56F80322; Wed, 21 Aug 2019 20:58:44 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id E81D3F80322; Wed, 21 Aug 2019 20:58:41 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on alsa1.perex.cz X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=SPF_HELO_NONE,SPF_NONE autolearn=disabled version=3.4.0 Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 89EFBF802E0 for ; Wed, 21 Aug 2019 20:58:36 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 89EFBF802E0 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Aug 2019 11:58:34 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,412,1559545200"; d="scan'208";a="262586595" Received: from dbarua-mobl.amr.corp.intel.com (HELO pbossart-mobl3.intel.com) ([10.252.198.189]) by orsmga001.jf.intel.com with ESMTP; 21 Aug 2019 11:58:33 -0700 From: Pierre-Louis Bossart To: alsa-devel@alsa-project.org Date: Wed, 21 Aug 2019 13:58:17 -0500 Message-Id: <20190821185821.12690-1-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Cc: Pierre-Louis Bossart , tiwai@suse.de, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, Ranjani Sridharan , vkoul@kernel.org, broonie@kernel.org, srinivas.kandagatla@linaro.org, jank@cadence.com, slawomir.blauciak@intel.com, Bard liao , Rander Wang Subject: [alsa-devel] [PATCH v3 0/4] soundwire: debugfs support for 5.4 X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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" This patchset enables debugfs support and corrects all the feedback provided on an earlier RFC ('soundwire: updates for 5.4') There is one remaining hard-coded value in intel.c that will need to be fixed in a follow-up patchset not specific to debugfs: we need to remove hard-coded Intel-specific configurations from cadence_master.c (PDI offsets, etc). Changes since v2: No code change, just rebase to soundwire/next Added GKH and Sanyog's tags Also added patch4 submitted earlier in another series which depends on debugfs Changes since v1 (Feedback from GKH) Handle debugfs in a more self-contained way (no dentry as return or parameter) Used CONFIG_DEBUG_FS in structures and code to make it easier to remove if need be. No functional change for register dumps. Changes since RFC (Feedback from GKH, Vinod, Guennadi, Cezary, Sanyog): removed error checks used DEFINE_SHOW_ATTRIBUTE and seq_file fixed copyright dates fixed SPDX license info to use GPL2.0 only fixed Makefile to include debugfs only if CONFIG_DEBUG_FS is selected used static inlines for fallback compilation removed intermediate variables removed hard-coded constants in loops (used registers offsets and hardware capabilities) squashed patch 3 Pierre-Louis Bossart (4): soundwire: add debugfs support soundwire: cadence_master: add debugfs register dump soundwire: intel: add debugfs register dump soundwire: intel: handle disabled links drivers/soundwire/Makefile | 4 + drivers/soundwire/bus.c | 6 ++ drivers/soundwire/bus.h | 16 +++ drivers/soundwire/bus_type.c | 3 + drivers/soundwire/cadence_master.c | 107 ++++++++++++++++++++ drivers/soundwire/cadence_master.h | 4 + drivers/soundwire/debugfs.c | 151 +++++++++++++++++++++++++++++ drivers/soundwire/intel.c | 145 ++++++++++++++++++++++++++- drivers/soundwire/slave.c | 1 + include/linux/soundwire/sdw.h | 10 ++ 10 files changed, 444 insertions(+), 3 deletions(-) create mode 100644 drivers/soundwire/debugfs.c base-commit: 183c7687802e4132eb782808a8bf80689a9219c1