mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Leo Yan <leo.yan@linaro.org>
To: Suzuki K Poulose <suzuki.poulose@arm.com>
Cc: Bhupesh Sharma <bhupesh.sharma@linaro.org>,
	coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org,
	mathieu.poirier@linaro.org, mike.leach@linaro.org,
	alexander.shishkin@linux.intel.com, linux-kernel@vger.kernel.org,
	bhupesh.linux@gmail.com,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: Re: [PATCH v2] coresight: etm4x: Fix crash observed on Qcom ETM parts with 'Low power override'
Date: Wed, 14 Sep 2022 23:00:39 +0800	[thread overview]
Message-ID: <YyHsXodPYtyX3i0+@leoy-yangtze.lan> (raw)
In-Reply-To: <b6c2b3eb-a900-f94e-c472-39719faf65af@arm.com>

On Wed, Sep 14, 2022 at 03:43:53PM +0100, Suzuki Kuruppassery Poulose wrote:

[...]

> > > +	/*
> > > +	 * Some Qualcomm implementations require skipping powering up the trace unit,
> > > +	 * as the ETMs are in the same power domain as their CPU cores.
> > > +	 *
> > > +	 * Since the 'skip_power_up' flag is used inside 'etm4_init_arch_data' function,
> > > +	 * initialize it before the function is called.
> > > +	 */
> > > +	if (fwnode_property_present(dev_fwnode(dev), "qcom,skip-power-up"))
> > > +		drvdata->skip_power_up = true;
> > > +
> > 
> > I personally think this sentence should be placed in the function
> > etm4_probe(), you need to move it just before smp call
> > etm4_init_arch_data(), this can allow DT property "qcom,skip-power-up"
> > to be respected.
> 
> Or we could move this to init_iomem_access() and explicitly set the flag
> to true in init_sysreg_access().

Agreed, this is more clear.

[...]

> > A side topic, in the mainline kernel I found the value
> > "desc.access.io_mem" is always zero (see the initialized value in
> > etm4_probe() and etm4_init_sysreg_access()).  Should we initialize
> > desc.access.io_mem to true in etm4_probe()?
> 
> Thats not true. It is initialised at :
> 
> etm4_init_iomem_access():
> 
> 	*csa = CSDEV_ACCESS_IOMEM(drvdata->base);
> 
> Where
> 
> #define CSDEV_ACCESS_IOMEM(_addr)               \
>         ((struct csdev_access)  {               \
>                 .io_mem         = true,         \
>                 .base           = (_addr),      \
>         })

Thanks a lot for explaination, sorry for noise.

Leo

  reply	other threads:[~2022-09-14 15:00 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-25  5:22 Bhupesh Sharma
2022-09-12 17:12 ` Bhupesh Sharma
2022-09-13 10:52 ` Leo Yan
2022-09-14 14:43   ` Suzuki K Poulose
2022-09-14 15:00     ` Leo Yan [this message]
2022-11-07 16:44     ` Suzuki K Poulose

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=YyHsXodPYtyX3i0+@leoy-yangtze.lan \
    --to=leo.yan@linaro.org \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=bhupesh.linux@gmail.com \
    --cc=bhupesh.sharma@linaro.org \
    --cc=coresight@lists.linaro.org \
    --cc=gregkh@linuxfoundation.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 \
    /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

all inboxes | Powered by JetHome®