public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: taozha@codeaurora.org
To: Suzuki K Poulose <suzuki.poulose@arm.com>
Cc: Mathieu Poirier <mathieu.poirier@linaro.org>,
	Alexander Shishkin <alexander.shishkin@linux.intel.com>,
	Mike Leach <mike.leach@linaro.org>, Leo Yan <leo.yan@linaro.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org,
	Tingwei Zhang <tingwei@codeaurora.org>,
	Mao Jinlong <jinlmao@codeaurora.org>,
	Yuanfang Zhang <zhangyuanfang@codeaurora.org>
Subject: Re: [PATCH v1 0/3] coresight: Support for building more coresight paths
Date: Thu, 13 May 2021 14:03:10 +0800	[thread overview]
Message-ID: <1cd71b1323e3d635b76c4785f60413a9@codeaurora.org> (raw)
In-Reply-To: <070d1c13-2b3e-2dfb-f51b-9d40f1b45a03@arm.com>

On 2021-05-10 21:10, Suzuki K Poulose wrote:
> Hi Tao
> 
> On 10/05/2021 12:05, Tao Zhang wrote:
>> We are trying to achieve more types of Coresight source devices.
>> For example, we have a type of coresight source devic named TPDM.
>> In the process of using, sometimes mulitiple TPDMs need to be
>> connected to the different input ports on the same funnel.
>> Meanwhile, these TPDMs also need to output from different
>> ports on the funnel.
>> But, at present the Coresight driver assumes
>> a) Only support Coresight source type ETM, ETR and ETF
> 
> Did you mean ETM and STM here ? ETR & ETF are not source types, rather
> they are SINK.
> 
> 
Yes, I mean ETM and STM here.
>> b) Funnels only support mulitiple inputs and one output
>> Which doesn't help to add the above feature for our new Coresight
>> source device TPDM. So, in order to accommodate the new device,
>> we develop the following patches.
> 
> Where is the TPDM driver ? Could you give us a rough idea of the
> behavior in terms of the input / output ?
> 
> 
We have plans to upload the TPDM driver in the feature. TPDM is a type 
of
hardware component for debugging and monitoring on Qualcomm targets.
The primary use case of the TPDM is to collect data from different data
source and send it to a TPDA for packetization, timestamping and 
funneling.
And the output of TPDA is a regular AMBA ATB stream and can be thought 
of as
any other trace source in the system.
You can get a general understanding of the TPDM and TPDA driver through 
the
following patch.
https://source.codeaurora.org/quic/la/kernel/msm-5.4/commit/?h=LV.AU.0.2.0.r1&id=a47c3313965c1101f2224e55da2c54d9e5c388dd
>> a) Add support more types of Coresight source devices.
> 
> Which ones ? where is the code ?
> 
In the patch 
"0001-coresight-add-support-to-enable-more-coresight-paths.patch",
we replaced the original path save method with the funcation 
"coresight_store_path".
In the original method, "coresight_enable" only can store the tracer 
path for ETM
and STM. In the function "coresight_store_path", it can store the tracer 
path for
more types of Coresight sources.
>> b) Add support for multiple output ports on funnel and the output
>> ports could be selected by Corsight source.
> 
> Does the "TPDM" require programming to switch these output or are
> these "static" ?
> 
> Is this something that can be avoided by having a "fake"
> static-replicator in the path ?
> 
> e.g,              TPDM
> 	 ________________________________________________
>  In0	|						|  -> Out0
>  In1	|   Static-Funnel   -> Static-Replicator	|  -> Out1
>  In2	|						|  -> Out2
> 	 ________________________________________________
> 
> 
> Is this something that can be solved ? Again, please give a brief
> description of the TPDM device and the driver code in the series to
> give us a complete picture of what you are trying to do.
> 
> Reviewing some changes without having the full picture is not going to
> be helpful.
> 
> Suzuki
Now the link can support multiple out ports, but there are no entries 
from
the link's device tree can figure out from which input port to which 
output
port.
This patch provide the entry "source" in device tree, which can 
associate
the input port of the link with the output port.
e.g, if we want to achieve the following link connection.
-------------------------------------------------------------------------
Source0 -> In0 |		| Out0 ->
Source1 -> In1 |Funnel 0| Out1 ->
Source2 -> In2 |		| Out2 ->
-------------------------------------------------------------------------
We can configure the "source" entries as the following device tree.
Funnel 0 {
	out-ports {
		port@0 {
			reg = <0>
			Out0: endpoint {
				remote-endpoint = <... ...>;
				source = <Source0>
			}

		}
		port@1 {
			reg = <1>
			Out1: endpoint {
				remote-endpoint = <... ...>;
				source = <Source1>
			}

		}
		port@2 {
			reg = <0>
			Out2: endpoint {
				remote-endpoint = <... ...>;
				source = <Source2>
			}

		}
	}

	in-ports {
		port@0 {
			reg = <0>
			In0: endpoint {
				remote-endpoint = <... ...>;
			}

		}
		port@1 {
			reg = <1>
			Out1: endpoint {
				remote-endpoint = <... ...>;
			}

		}
		port@2 {
			reg = <0>
			Out2: endpoint {
				remote-endpoint = <... ...>;
			}

		}
	}
}

Best,
Tao

      reply	other threads:[~2021-05-13  6:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-10 11:05 [PATCH v1 0/3] coresight: Support for building more coresight paths Tao Zhang
2021-05-10 11:05 ` [PATCH v1 1/3] coresight: add support to enable " Tao Zhang
2021-05-10 11:05 ` [PATCH v1 2/3] coresight: funnel: add support for multiple output ports Tao Zhang
2021-05-10 11:05 ` [PATCH v1 3/3] dt-bindings: arm: add property for selecting funnel output port Tao Zhang
2021-05-10 13:10 ` [PATCH v1 0/3] coresight: Support for building more coresight paths Suzuki K Poulose
2021-05-13  6:03   ` taozha [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1cd71b1323e3d635b76c4785f60413a9@codeaurora.org \
    --to=taozha@codeaurora.org \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=coresight@lists.linaro.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=jinlmao@codeaurora.org \
    --cc=leo.yan@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.poirier@linaro.org \
    --cc=mike.leach@linaro.org \
    --cc=suzuki.poulose@arm.com \
    --cc=tingwei@codeaurora.org \
    --cc=zhangyuanfang@codeaurora.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox