linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* coresight: ACPI hook for funnel on ThunderX2
@ 2019-08-15 13:58 Tanmay Vilas Kumar Jagdale
  2019-08-19 20:06 ` Mathieu Poirier
  0 siblings, 1 reply; 3+ messages in thread
From: Tanmay Vilas Kumar Jagdale @ 2019-08-15 13:58 UTC (permalink / raw)
  To: mathieu.poirier
  Cc: Ganapatrao Kulkarni, Tomasz Nowicki, suzuki.poulose,
	Jayachandran Chandrasekharan Nair, Tanmay Vilas Kumar Jagdale,
	linux-arm-kernel

Coresight topology on Marvell's ThunderX2 Processor is as follows:

 ETM0 _                                                   _ TPIU
 ...   \    Static      Dynamic                          /
 ...    --> FUNNEL0 --> FUNNEL1 --> ETF --> REPLICATOR --
ETM127_/            |                                    \_ ETR
                    |
            ETM128--|
                    /
           Others--/

To support this topology add ACPI hook for Static Funnel0.

Signed-off-by: Tanmay Jagdale <tanmay@marvell.com>
---
 drivers/hwtracing/coresight/coresight-funnel.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/hwtracing/coresight/coresight-funnel.c b/drivers/hwtracing/coresight/coresight-funnel.c
index fa97cb9ab4f9..315691fd6f4b 100644
--- a/drivers/hwtracing/coresight/coresight-funnel.c
+++ b/drivers/hwtracing/coresight/coresight-funnel.c
@@ -5,6 +5,7 @@
  * Description: CoreSight Funnel driver
  */
 
+#include <linux/acpi.h>
 #include <linux/kernel.h>
 #include <linux/init.h>
 #include <linux/types.h>
@@ -297,6 +298,11 @@ static int static_funnel_probe(struct platform_device *pdev)
 	return ret;
 }
 
+static const struct acpi_device_id static_funnel_acpi_ids[] = {
+	{ "CAV901A" },
+	{},
+};
+
 static const struct of_device_id static_funnel_match[] = {
 	{.compatible = "arm,coresight-static-funnel"},
 	{}
@@ -306,6 +312,7 @@ static struct platform_driver static_funnel_driver = {
 	.probe          = static_funnel_probe,
 	.driver         = {
 		.name   = "coresight-static-funnel",
+		.acpi_match_table = ACPI_PTR(static_funnel_acpi_ids),
 		.of_match_table = static_funnel_match,
 		.pm	= &funnel_dev_pm_ops,
 		.suppress_bind_attrs = true,
-- 
2.17.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: coresight: ACPI hook for funnel on ThunderX2
  2019-08-15 13:58 coresight: ACPI hook for funnel on ThunderX2 Tanmay Vilas Kumar Jagdale
@ 2019-08-19 20:06 ` Mathieu Poirier
  2019-08-20 17:08   ` [EXT] " Tanmay Vilas Kumar Jagdale
  0 siblings, 1 reply; 3+ messages in thread
From: Mathieu Poirier @ 2019-08-19 20:06 UTC (permalink / raw)
  To: Tanmay Vilas Kumar Jagdale
  Cc: Tomasz Nowicki, Jayachandran Chandrasekharan Nair,
	Ganapatrao Kulkarni, linux-arm-kernel, suzuki.poulose

Hi Tanmay,

On Thu, Aug 15, 2019 at 01:58:21PM +0000, Tanmay Vilas Kumar Jagdale wrote:
> Coresight topology on Marvell's ThunderX2 Processor is as follows:
> 
>  ETM0 _                                                   _ TPIU
>  ...   \    Static      Dynamic                          /
>  ...    --> FUNNEL0 --> FUNNEL1 --> ETF --> REPLICATOR --
> ETM127_/            |                                    \_ ETR
>                     |
>             ETM128--|
>                     /
>            Others--/
> 
> To support this topology add ACPI hook for Static Funnel0.
> 
> Signed-off-by: Tanmay Jagdale <tanmay@marvell.com>

There are a few things that aren't working with your patch.  First it doesn't
clear checkpatch.pl - a lot of maintainers will not even look at a patch when
it is the case.  Second it doesn't apply to my coresight next branch[1] and
third there are formatting issue with the subject line.

I suggest you peruse through the Documentation/process directory with a special
interest toward files submitting-patches.rst and submit-checklist.rst.  Your
life (and mine) will be greatly improved in the process. 

More comments below...

> ---
>  drivers/hwtracing/coresight/coresight-funnel.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/drivers/hwtracing/coresight/coresight-funnel.c b/drivers/hwtracing/coresight/coresight-funnel.c
> index fa97cb9ab4f9..315691fd6f4b 100644
> --- a/drivers/hwtracing/coresight/coresight-funnel.c
> +++ b/drivers/hwtracing/coresight/coresight-funnel.c
> @@ -5,6 +5,7 @@
>   * Description: CoreSight Funnel driver
>   */
>  
> +#include <linux/acpi.h>
>  #include <linux/kernel.h>
>  #include <linux/init.h>
>  #include <linux/types.h>
> @@ -297,6 +298,11 @@ static int static_funnel_probe(struct platform_device *pdev)
>  	return ret;
>  }
>  
> +static const struct acpi_device_id static_funnel_acpi_ids[] = {
> +	{ "CAV901A" },
> +	{},
> +};
> +

Is there anything different between this static funnel and ARM's static funnel?
An ACPI device for static funnels has already been added[2] - this is probably
what you should be using.

Thanks,
Mathieu

[1]. https://git.linaro.org/kernel/coresight.git/log/?h=next
[2]. 991de72831b3 coresight: acpi: Static funnel support

>  static const struct of_device_id static_funnel_match[] = {
>  	{.compatible = "arm,coresight-static-funnel"},
>  	{}
> @@ -306,6 +312,7 @@ static struct platform_driver static_funnel_driver = {
>  	.probe          = static_funnel_probe,
>  	.driver         = {
>  		.name   = "coresight-static-funnel",
> +		.acpi_match_table = ACPI_PTR(static_funnel_acpi_ids),
>  		.of_match_table = static_funnel_match,
>  		.pm	= &funnel_dev_pm_ops,
>  		.suppress_bind_attrs = true,
> -- 
> 2.17.1
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: [EXT] Re: coresight: ACPI hook for funnel on ThunderX2
  2019-08-19 20:06 ` Mathieu Poirier
@ 2019-08-20 17:08   ` Tanmay Vilas Kumar Jagdale
  0 siblings, 0 replies; 3+ messages in thread
From: Tanmay Vilas Kumar Jagdale @ 2019-08-20 17:08 UTC (permalink / raw)
  To: Mathieu Poirier
  Cc: Tomasz Nowicki, Jayachandran Chandrasekharan Nair,
	Ganapatrao Kulkarni, linux-arm-kernel, suzuki.poulose

Hi Mathieu,

Thanks for the review and the pointers. I'll keep those in mind.

Our hardware does not implement anything specific so we will use ARM's ACPI device for our static funnel.
We can drop this patch.

With Regards,
Tanmay



-----Original Message-----
From: Mathieu Poirier <mathieu.poirier@linaro.org> 
Sent: Tuesday, August 20, 2019 1:37 AM
To: Tanmay Vilas Kumar Jagdale <tanmay@marvell.com>
Cc: suzuki.poulose@arm.com; linux-arm-kernel@lists.infradead.org; Jayachandran Chandrasekharan Nair <jnair@marvell.com>; Ganapatrao Kulkarni <gkulkarni@marvell.com>; Tomasz Nowicki <tnowicki@marvell.com>
Subject: [EXT] Re: coresight: ACPI hook for funnel on ThunderX2

External Email

----------------------------------------------------------------------
Hi Tanmay,

On Thu, Aug 15, 2019 at 01:58:21PM +0000, Tanmay Vilas Kumar Jagdale wrote:
> Coresight topology on Marvell's ThunderX2 Processor is as follows:
> 
>  ETM0 _                                                   _ TPIU
>  ...   \    Static      Dynamic                          /
>  ...    --> FUNNEL0 --> FUNNEL1 --> ETF --> REPLICATOR --
> ETM127_/            |                                    \_ ETR
>                     |
>             ETM128--|
>                     /
>            Others--/
> 
> To support this topology add ACPI hook for Static Funnel0.
> 
> Signed-off-by: Tanmay Jagdale <tanmay@marvell.com>

There are a few things that aren't working with your patch.  First it doesn't clear checkpatch.pl - a lot of maintainers will not even look at a patch when it is the case.  Second it doesn't apply to my coresight next branch[1] and third there are formatting issue with the subject line.

I suggest you peruse through the Documentation/process directory with a special interest toward files submitting-patches.rst and submit-checklist.rst.  Your life (and mine) will be greatly improved in the process. 

More comments below...

> ---
>  drivers/hwtracing/coresight/coresight-funnel.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/drivers/hwtracing/coresight/coresight-funnel.c 
> b/drivers/hwtracing/coresight/coresight-funnel.c
> index fa97cb9ab4f9..315691fd6f4b 100644
> --- a/drivers/hwtracing/coresight/coresight-funnel.c
> +++ b/drivers/hwtracing/coresight/coresight-funnel.c
> @@ -5,6 +5,7 @@
>   * Description: CoreSight Funnel driver
>   */
>  
> +#include <linux/acpi.h>
>  #include <linux/kernel.h>
>  #include <linux/init.h>
>  #include <linux/types.h>
> @@ -297,6 +298,11 @@ static int static_funnel_probe(struct platform_device *pdev)
>  	return ret;
>  }
>  
> +static const struct acpi_device_id static_funnel_acpi_ids[] = {
> +	{ "CAV901A" },
> +	{},
> +};
> +

Is there anything different between this static funnel and ARM's static funnel?
An ACPI device for static funnels has already been added[2] - this is probably what you should be using.

Thanks,
Mathieu

[1]. https://git.linaro.org/kernel/coresight.git/log/?h=next
[2]. 991de72831b3 coresight: acpi: Static funnel support

>  static const struct of_device_id static_funnel_match[] = {
>  	{.compatible = "arm,coresight-static-funnel"},
>  	{}
> @@ -306,6 +312,7 @@ static struct platform_driver static_funnel_driver = {
>  	.probe          = static_funnel_probe,
>  	.driver         = {
>  		.name   = "coresight-static-funnel",
> +		.acpi_match_table = ACPI_PTR(static_funnel_acpi_ids),
>  		.of_match_table = static_funnel_match,
>  		.pm	= &funnel_dev_pm_ops,
>  		.suppress_bind_attrs = true,
> --
> 2.17.1
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-08-20 17:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-15 13:58 coresight: ACPI hook for funnel on ThunderX2 Tanmay Vilas Kumar Jagdale
2019-08-19 20:06 ` Mathieu Poirier
2019-08-20 17:08   ` [EXT] " Tanmay Vilas Kumar Jagdale

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).