From: Suzuki K Poulose <suzuki.poulose@arm.com>
To: James Clark <james.clark@arm.com>,
coresight@lists.linaro.org, quic_jinlmao@quicinc.com,
mike.leach@linaro.org
Cc: Mathieu Poirier <mathieu.poirier@linaro.org>,
Leo Yan <leo.yan@linaro.org>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 01/13] coresight: Fix loss of connection info when a module is unloaded
Date: Tue, 4 Apr 2023 15:02:19 +0100 [thread overview]
Message-ID: <8cb0be8c-8ff2-d643-2dba-135974c8bc3b@arm.com> (raw)
In-Reply-To: <20230404135401.1728919-2-james.clark@arm.com>
On 04/04/2023 14:53, James Clark wrote:
> child_fwnode should be a read only property based on the DT. If it's
minor nit: Not restricted to DT. This also covers the ACPI.
> cleared on the parent device when a child is unloaded, then when the
> child is loaded again the connection won't be remade.
>
> child_dev should be cleared instead which signifies that the connection
> should be remade when the child_fwnode registers a new coresight_device.
>
> Similarly the reference count shouldn't be decremented as long as the
> parent device exists. The correct place to drop the reference is in
> coresight_release_platform_data() which is already done.
>
> Reproducible on Juno with the following steps:
>
> # load all coresight modules.
> $ cd /sys/bus/coresight/devices/
> $ echo 1 > tmc_etr0/enable_sink
> $ echo 1 > etm0/enable_source
> # Works fine ^
>
> $ echo 0 > etm0/enable_source
> $ rmmod coresight-funnel
> $ modprobe coresight-funnel
> $ echo 1 > etm0/enable_source
> -bash: echo: write error: Invalid argument
>
> Fixes: 37ea1ffddffa ("coresight: Use fwnode handle instead of device names")
> Fixes: 2af89ebacf29 ("coresight: Clear the connection field properly")
> Signed-off-by: James Clark <james.clark@arm.com>
Looks good to me.
Tested-by: Suzuki K Poulose <suzuki.poulose@arm.com>
next prev parent reply other threads:[~2023-04-04 14:11 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-04 13:53 [PATCH v4 00/13] coresight: Fix CTI module refcount leak by making it a helper device James Clark
2023-04-04 13:53 ` [PATCH v4 01/13] coresight: Fix loss of connection info when a module is unloaded James Clark
2023-04-04 14:02 ` Suzuki K Poulose [this message]
2023-04-04 13:53 ` [PATCH v4 02/13] coresight: Use enum type for cs_mode wherever possible James Clark
2023-04-04 13:53 ` [PATCH v4 03/13] coresight: Change name of pdata->conns James Clark
2023-04-04 13:53 ` [PATCH v4 04/13] coresight: Rename nr_outports to nr_outconns James Clark
2023-04-04 13:53 ` [PATCH v4 05/13] coresight: Rename connection members to make the direction explicit James Clark
2023-04-04 13:53 ` [PATCH v4 06/13] coresight: Dynamically add connections James Clark
2023-04-04 13:53 ` [PATCH v4 07/13] coresight: Store pointers to connections rather than an array of them James Clark
2023-04-04 14:18 ` Suzuki K Poulose
2023-04-04 13:53 ` [PATCH v4 08/13] coresight: Simplify connection fixup mechanism James Clark
2023-04-04 13:53 ` [PATCH v4 09/13] coresight: Store in-connections as well as out-connections James Clark
2023-04-04 13:53 ` [PATCH v4 10/13] coresight: Make refcount a property of the connection James Clark
2023-04-04 13:53 ` [PATCH v4 11/13] coresight: Refactor out buffer allocation function for ETR James Clark
2023-04-04 13:53 ` [PATCH v4 12/13] coresight: Enable and disable helper devices adjacent to the path James Clark
2023-04-04 13:53 ` [PATCH v4 13/13] coresight: Fix CTI module refcount leak by making it a helper device James Clark
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=8cb0be8c-8ff2-d643-2dba-135974c8bc3b@arm.com \
--to=suzuki.poulose@arm.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=coresight@lists.linaro.org \
--cc=gregkh@linuxfoundation.org \
--cc=james.clark@arm.com \
--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=quic_jinlmao@quicinc.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®