Re: [PATCH] coresight: etm4x: work around clang-12+ build failure

2021-02-25 Thread Mathieu Poirier
Good morning, On Thu, Feb 25, 2021 at 10:42:58AM +0100, Arnd Bergmann wrote: > From: Arnd Bergmann > > clang-12 fails to build the etm4x driver with -fsanitize=array-bounds: > > :1:7: error: expected constant expression in '.inst' directive > .inst (0xd520|2) << 19) | ((1) << 16) |

Re: [PATCH RESEND] remoteproc: core: Remove casting to rproc_handle_resource_t

2021-02-24 Thread Mathieu Poirier
void * and > use a local variable with the correct type so that everything works > properly. With this, we can remove casting to rproc_handle_resource_t > for these functions. > > Signed-off-by: Jindong Yue > Reviewed-by: Peng Fan > Reviewed-by: Sami Tolvanen Revie

Re: [PATCH] remoteproc: pru: Replace DEFINE_SIMPLE_ATTRIBUTE with DEFINE_DEBUGFS_ATTRIBUTE

2021-02-24 Thread Mathieu Poirier
pru_rproc_debug_ss_set, "%llu\n"); Reviewed-by: Mathieu Poirier > > /* > -- > 1.8.3.1 >

Re: [PATCH v4 04/10] coresight: etm-perf: update to handle configuration selection

2021-02-24 Thread Mathieu Poirier
On Thu, Jan 28, 2021 at 05:09:30PM +, Mike Leach wrote: > Loaded coresight configurations are registered in the cs_etm\cs_config sub > directory. This extends the etm-perf code to handle these registrations, > and the cs_syscfg driver to perform the registration on load. > > Signed-off-by:

[PATCH 6/6] perf cs-etm: Detect pid in VMID for kernel running at EL2

2021-02-24 Thread Mathieu Poirier
From: Suzuki K Poulose The PID of the task could be traced as VMID when the kernel is running at EL2. Teach the decoder to look for VMID when the CONTEXTIDR (Arm32) or CONTEXTIDR_EL1 (Arm64) is invalid but we have a valid VMID. Cc: Mike Leach Cc: Mathieu Poirier Cc: Al Grant Signed-off

[PATCH 4/6] perf cs-etm: Support PID tracing in config

2021-02-24 Thread Mathieu Poirier
ot;contextid2"; otherwise, it dynamically sets config based on PMU format "contextid". Cc: Mike Leach Cc: Mathieu Poirier Cc: Al Grant Signed-off-by: Suzuki K Poulose Co-developed-by: Leo Yan Signed-off-by: Leo Yan Reviewed-by: Mike Leach Reviewed-by: Mathieu Poirier Link: https://lore.

[PATCH 2/6] tools headers UAPI: Update tools' copy of linux/coresight-pmu.h

2021-02-24 Thread Mathieu Poirier
From: Leo Yan To get the changes in the commit: "coresight: etm-perf: Clarify comment on perf options". Signed-off-by: Leo Yan Reviewed-by: Suzuki K Poulose Reviewed-by: Mathieu Poirier Link: https://lore.kernel.org/r/20210213113220.292229-2-leo@linaro.org --- tools/inc

[PATCH 3/6] perf cs-etm: Fix bitmap for option

2021-02-24 Thread Mathieu Poirier
gned-off-by: Leo Yan Reviewed-by: Mike Leach Reviewed-by: Mathieu Poirier Link: https://lore.kernel.org/r/20210213113220.292229-3-leo@linaro.org --- tools/perf/arch/arm/util/cs-etm.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/perf/arch/arm/util/cs-etm.

[PATCH 1/6] perf: cs-etm: update ETM metadata format

2021-02-24 Thread Mathieu Poirier
From: Mike Leach The current fixed metadata version format (version 0), means that adding metadata parameter items renders files from a previous version of perf unreadable. Per CPU parameters appear in a fixed order, but there is no field to indicate the number of ETM parameters per CPU. This

[PATCH 5/6] perf cs-etm: Add helper cs_etm__get_pid_fmt()

2021-02-24 Thread Mathieu Poirier
From: Leo Yan This patch adds helper function cs_etm__get_pid_fmt(), by passing parameter "traceID", it returns the PID format. Signed-off-by: Leo Yan Reviewed-by: Mathieu Poirier Reviewed-by: Suzuki K Poulose Link: https://lore.kernel.org/r/20210213113220.292229-5-leo@

[PATCH 0/6] coresight: Patches for v5.12 (perf tools)

2021-02-24 Thread Mathieu Poirier
Good day Arnaldo, I noticed there is a couple of patchsets [1][2] that haven't made it to your tree for the coming v5.12 cycle. Do you think that can still be done? I tallied the patches here to make it easier for you to pick up. Applies cleanly on perf/core (84b7725536d8) Thanks, Mathieu

Re: [PATCH 0/7] Split Coresight decode by aux records

2021-02-24 Thread Mathieu Poirier
Good day James, I have received your patchset and added it to my queue. On the flip side it will be 3 to 4 weeks (from today) before I get a chance to look at it. As such I suggest you don't wait on me before addressing the issues found by Leo. Thanks, Mathieu On Fri, Feb 12, 2021 at

[PATCH v6 11/16] remoteproc: Properly deal with the resource table when attached

2021-02-23 Thread Mathieu Poirier
-by: Mathieu Poirier --- New for V6: - Double free of the cached table has been fixed. - rproc_reset_loaded_rsc_table() has seen a complete re-write. - rproc_stop() now calls rproc_reset_loaded_rsc_table() rather than dealing with the cached. This allows to properly shutdown a remote processor

[PATCH v6 12/16] remoteproc: Properly deal with a kernel panic when attached

2021-02-23 Thread Mathieu Poirier
The panic handler operation of registered remote processors should also be called when remote processors have been attached to. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 6 +- 1 file changed, 5 insertions

[PATCH v6 13/16] remoteproc: Properly deal with a start request when attached

2021-02-23 Thread Mathieu Poirier
This patch takes into account scenarios where a remote processor has been attached to when receiving a "start" command from sysfs. As with the case with the running state, the command can't be carried out if the remote processor is already in operation. Signed-off-by: Mathieu Poirier

[PATCH v6 14/16] remoteproc: Properly deal with a stop request when attached

2021-02-23 Thread Mathieu Poirier
Allow a remote processor that was started by another entity to be switched off by the remoteproc core. For that to happen a rproc::ops::stop() operation needs to be available. Signed-off-by: Mathieu Poirier --- New for V6: - Removed state check in rproc_shutdown() as it is already done

[PATCH v6 16/16] remoteproc: Refactor rproc delete and cdev release path

2021-02-23 Thread Mathieu Poirier
Refactor function rproc_del() and rproc_cdev_release() to take into account the current state of the remote processor when choosing the state to transition to. Signed-off-by: Mathieu Poirier --- New for V6: - The RPROC_RUNNING -> RPROC_DETACHED transition is no longer permitted. to av

[PATCH v6 07/16] remoteproc: stm32: Move memory parsing to rproc_ops

2021-02-23 Thread Mathieu Poirier
From: Arnaud POULIQUEN Some actions such as memory resources reallocation are needed when trying to reattach a co-processor. Use the prepare() operation for these actions. Co-developed-by: Mathieu Poirier Signed-off-by: Mathieu Poirier Signed-off-by: Arnaud POULIQUEN --- drivers/remoteproc

[PATCH v6 09/16] remoteproc: Introduce function __rproc_detach()

2021-02-23 Thread Mathieu Poirier
te processor while the latter is kept operating. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan --- drivers/remoteproc/remoteproc_core.c | 30 1 file changed, 30 insertions(+) diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_

[PATCH v6 10/16] remoteproc: Introduce function rproc_detach()

2021-02-23 Thread Mathieu Poirier
Introduce function rproc_detach() to enable the remoteproc core to release the resources associated with a remote processor without stopping its operation. Signed-off-by: Mathieu Poirier --- New for V6: - Checking for rproc->state has been removed. They have been moved to calling functi

[PATCH v6 15/16] remoteproc: Properly deal with a detach request when attached

2021-02-23 Thread Mathieu Poirier
This patch introduces the capability to detach a remote processor that has been attached by the remoteproc core. For that to happen a rproc::ops::detach() operation needs to be available. Signed-off-by: Mathieu Poirier --- New for V6: - The RPROC_RUNNING -> RPROC_DETACHED transit

[PATCH v6 08/16] remoteproc: Add new detach() remoteproc operation

2021-02-23 Thread Mathieu Poirier
Add an new detach() operation in order to support scenarios where the remoteproc core is going away but the remote processor is kept operating. This could be the case when the system is rebooted or when the platform driver is removed. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan

[PATCH v6 04/16] remoteproc: Properly represent the attached state

2021-02-23 Thread Mathieu Poirier
-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 20 +--- drivers/remoteproc/remoteproc_sysfs.c | 5 + include/linux/remoteproc.h| 2 -- 3 files changed, 2 insertions(+), 25 deletions(-) diff --git

[PATCH v6 06/16] remoteproc: stm32: Move resource table setup to rproc_ops

2021-02-23 Thread Mathieu Poirier
needs to be available at a later time than the platform driver's probe() function. Signed-off-by: Mathieu Poirier --- drivers/remoteproc/stm32_rproc.c | 141 +++ 1 file changed, 68 insertions(+), 73 deletions(-) diff --git a/drivers/remoteproc/stm32_rproc.c b/drivers

[PATCH v6 05/16] remoteproc: Add new get_loaded_rsc_table() to rproc_ops

2021-02-23 Thread Mathieu Poirier
Add a new get_loaded_rsc_table() operation in order to support scenarios where the remoteproc core has booted a remote processor and detaches from it. When re-attaching to the remote processor, the core needs to know where the resource table has been placed in memory. Signed-off-by: Mathieu

[PATCH v6 02/16] remoteproc: Rename function rproc_actuate()

2021-02-23 Thread Mathieu Poirier
Rename function rproc_actuate() to rproc_attach(). That way it is easy to understand that it does the opposite of rproc_detach(). Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 8 1 file changed, 4

[PATCH v6 03/16] remoteproc: Add new RPROC_ATTACHED state

2021-02-23 Thread Mathieu Poirier
Add a new RPROC_ATTACHED state to take into account scenarios where the remoteproc core needs to attach to a remote processor that is booted by another entity. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_sysfs.c | 1

[PATCH v6 00/16] remoteproc: Add support for detaching a remote processor

2021-02-23 Thread Mathieu Poirier
.12-rc1 when it comes out next week. Thanks, Mathieu Arnaud POULIQUEN (1): remoteproc: stm32: Move memory parsing to rproc_ops Mathieu Poirier (15): remoteproc: Remove useless check in rproc_del() remoteproc: Rename function rproc_actuate() remoteproc: Add new RPROC_ATTACHED state remotep

[PATCH v6 01/16] remoteproc: Remove useless check in rproc_del()

2021-02-23 Thread Mathieu Poirier
when in fact it no longer exist. Invariably calling rproc_shutdown() is fine since it will return immediately if the remote processor has already been switched off. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 4

Re: [PATCH] remoteproc: core: Remove casting to rproc_handle_resource_t

2021-02-23 Thread Mathieu Poirier
On Tue, 23 Feb 2021 at 09:49, Sami Tolvanen wrote: > > On Tue, Feb 23, 2021 at 8:41 AM Mathieu Poirier > wrote: > > > > On Mon, 22 Feb 2021 at 15:48, Sami Tolvanen wrote: > > > > > > Hi, > > > > > > On Sun, Feb 21, 2021 at 11:18 PM Jin

Re: [PATCH] remoteproc: core: Remove casting to rproc_handle_resource_t

2021-02-23 Thread Mathieu Poirier
On Mon, 22 Feb 2021 at 15:48, Sami Tolvanen wrote: > > Hi, > > On Sun, Feb 21, 2021 at 11:18 PM Jindong Yue wrote: > > > > There are four different callback functions that are used for the > > rproc_handle_resource_t callback that all have different second > > parameter types. > > > >

Re: [PATCH v26 0/5] Add initial zynqmp R5 remoteproc driver

2021-02-23 Thread Mathieu Poirier
Good morning, I have received your patchset but currently don't see having the time to look at it before the middle of March. Thanks, Mathieu On Tue, 23 Feb 2021 at 08:44, Ben Levinsky wrote: > > R5 is included in Xilinx Zynq UltraScale MPSoC so by adding this > remotproc driver, we can boot

Re: [PATCH v4 03/10] coresight: config: Add configuration and feature generic functions

2021-02-22 Thread Mathieu Poirier
On Thu, Jan 28, 2021 at 05:09:29PM +, Mike Leach wrote: > Adds a set of generic support functions that allow devices to set and save > features values on the device, and enable and disable configurations. > > Additional functions for other common operations including feature > reset. > >

Re: [PATCH v4 02/10] coresight: syscfg: Add registration and feature loading for cs devices

2021-02-22 Thread Mathieu Poirier
On Thu, Jan 28, 2021 at 05:09:28PM +, Mike Leach wrote: > API for individual devices to register with the syscfg management > system is added. > > Devices register with matching information, and any features or > configurations that match will be loaded into the device. > > The feature and

Re: [PATCH v4 01/10] coresight: syscfg: Initial coresight system configuration

2021-02-22 Thread Mathieu Poirier
On Thu, Jan 28, 2021 at 05:09:27PM +, Mike Leach wrote: > Creates an system management API to allow complex configurations and > features to be programmed into a CoreSight infrastructure. > > A feature is defined as a programming set for a device or class of > devices. > > A configuration is

Re: [PATCH v4 02/10] coresight: syscfg: Add registration and feature loading for cs devices

2021-02-22 Thread Mathieu Poirier
Hi Mike, On Thu, Jan 28, 2021 at 05:09:28PM +, Mike Leach wrote: > API for individual devices to register with the syscfg management > system is added. > > Devices register with matching information, and any features or > configurations that match will be loaded into the device. > > The

Re: [PATCH v4 02/10] coresight: syscfg: Add registration and feature loading for cs devices

2021-02-19 Thread Mathieu Poirier
[...] > +/** > + * List entry for Coresight devices that are registered as supporting complex > + * config operations. > + * > + * @csdev: The registered device. > + * @match_info: The matching type information. > + * @ops: Operations supported by the registered device. > + * @item:list

Re: [PATCH v4 01/10] coresight: syscfg: Initial coresight system configuration

2021-02-18 Thread Mathieu Poirier
On Thu, Jan 28, 2021 at 05:09:27PM +, Mike Leach wrote: > Creates an system management API to allow complex configurations and > features to be programmed into a CoreSight infrastructure. > > A feature is defined as a programming set for a device or class of > devices. > > A configuration is

Re: [PATCH v4 10/10] coresight: docs: Add documentation for CoreSight config

2021-02-18 Thread Mathieu Poirier
aid out in configfs look good to me. Things can still change at some point in the future but for now: Reviewed-by: Mathieu Poirier > > diff --git a/Documentation/trace/coresight/coresight-config.rst > b/Documentation/trace/coresight/coresight-config.rst > new file mode 10064

Re: [PATCH v5] perf: cs-etm: update ETM metadata format

2021-02-18 Thread Mathieu Poirier
mbers of parameters than in use at the > time perf was built. > > Signed-off-by: Mike Leach > Reviewed-by: Leo Yan > Tested-by: Leo Yan > Reviewed-by: Mathieu Poirier Please rebase this patch on 5.12-rc1 when it comes out and resend to Arnaldo. Thanks, Mathieu >

Re: [PATCH v25 5/5] remoteproc: Add initial zynqmp R5 remoteproc driver

2021-02-17 Thread Mathieu Poirier
On Wed, Feb 17, 2021 at 09:34:13PM +, Ben Levinsky wrote: > 1 more for the pnode_id comment > [...] > > > > > +static int parse_tcm_banks(struct rproc *rproc) > > > > > +{ > > > > > + int i, num_banks; > > > > > + struct zynqmp_r5_rproc *z_rproc = rproc->priv; > > > > > + struct

Re: [PATCH v25 5/5] remoteproc: Add initial zynqmp R5 remoteproc driver

2021-02-17 Thread Mathieu Poirier
On Wed, Feb 17, 2021 at 07:11:37PM +, Ben Levinsky wrote: > Hi Mathieu, > > I worked on this further and had 1 more comment on the prepare/unprepare for > TCM banks below > [...] > > > > + */ > > > > +static int tcm_mem_release(struct rproc *rproc, struct rproc_mem_entry > > > *mem) > > >

Re: [PATCH v5 07/19] remoteproc: Add new get_loaded_rsc_table() to rproc_ops

2021-02-17 Thread Mathieu Poirier
On Mon, Feb 15, 2021 at 02:10:10PM +0100, Arnaud POULIQUEN wrote: > Hi Mathieu, > > On 2/12/21 12:46 AM, Mathieu Poirier wrote: > > Add a new get_loaded_rsc_table() operation in order to support > > scenarios where the remoteproc core has booted a remote processor > >

Re: [PATCH V3 08/14] coresight: core: Add support for dedicated percpu sinks

2021-02-16 Thread Mathieu Poirier
On Tue, Feb 16, 2021 at 04:10:18PM +0530, Anshuman Khandual wrote: > > > On 2/5/21 12:04 AM, Mathieu Poirier wrote: > > On Thu, Jan 28, 2021 at 09:16:34AM +, Suzuki K Poulose wrote: > >> On 1/27/21 8:55 AM, Anshuman Khandual wrote: > >>> Add suppor

Re: [PATCH V3 08/14] coresight: core: Add support for dedicated percpu sinks

2021-02-16 Thread Mathieu Poirier
On Mon, Feb 15, 2021 at 05:58:37PM +, Mike Leach wrote: > Hi Mathieu, > > On Mon, 15 Feb 2021 at 16:56, Mathieu Poirier > wrote: > > > > On Mon, Feb 15, 2021 at 04:27:26PM +, Mike Leach wrote: > > > HI Anshuman > > > > > > On Wed, 2

Re: [PATCH v25 5/5] remoteproc: Add initial zynqmp R5 remoteproc driver

2021-02-16 Thread Mathieu Poirier
On Sun, Jan 10, 2021 at 06:02:50PM -0800, Ben Levinsky wrote: > R5 is included in Xilinx Zynq UltraScale MPSoC so by adding this > remotproc driver, we can boot the R5 sub-system in two different > configurations - > * Split > * Lockstep > > The Xilinx R5 Remoteproc Driver boots the

Re: [PATCH v25 5/5] remoteproc: Add initial zynqmp R5 remoteproc driver

2021-02-15 Thread Mathieu Poirier
Good day, I have started to review this set - as with previous revisions comments will come over several days. On Sun, Jan 10, 2021 at 06:02:50PM -0800, Ben Levinsky wrote: > R5 is included in Xilinx Zynq UltraScale MPSoC so by adding this > remotproc driver, we can boot the R5 sub-system in two

Re: [PATCH V3 08/14] coresight: core: Add support for dedicated percpu sinks

2021-02-15 Thread Mathieu Poirier
t; > percpu source and sink devices which are exclusively linked and dependent. > > Build the path directly and skip connection scanning for such devices. > > > > Cc: Mathieu Poirier > > Cc: Mike Leach > > Cc: Suzuki K Poulose > > Signed-off-

Re: [PATCHv2] coresight: etm4x: Add ETM PID for Cortex-A78

2021-02-15 Thread Mathieu Poirier
On Mon, Feb 15, 2021 at 10:26:38AM +, Mike Leach wrote: > Reviewed-by: Mike Leach I will pick this up when 5.12-rc1 comes out. Thanks, Mathieu > > On Sat, 13 Feb 2021 at 11:28, Sai Prakash Ranjan > wrote: > > > > Add ETM PID for Cortex-A78 to the list of supported ETMs. > > > >

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-12 Thread Mathieu Poirier
.P. The TRBE can also generate a CPU > private interrupt (PPI) on address translation errors and when the buffer > is full. Overall implementation here is inspired from the Arm SPE driver. > > Cc: Mathieu Poirier > Cc: Mike Leach > Cc: Suzuki K Poulose > Signed-off-by: Anshuman Kha

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-12 Thread Mathieu Poirier
On Fri, Feb 12, 2021 at 11:13:01AM +0530, Anshuman Khandual wrote: > > > On 2/11/21 12:30 AM, Mathieu Poirier wrote: > > On Wed, Jan 27, 2021 at 02:25:35PM +0530, Anshuman Khandual wrote: > >> Trace Buffer Extension (TRBE) implements a trace buffer per CPU which is > &

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-12 Thread Mathieu Poirier
[...] > > > > > >> + if (nr_pages < 2) > >> + return NULL; > >> + > >> + buf = kzalloc_node(sizeof(*buf), GFP_KERNEL, trbe_alloc_node(event)); > >> + if (IS_ERR(buf)) > >> + return ERR_PTR(-ENOMEM); > >> + > >> + pglist = kcalloc(nr_pages, sizeof(*pglist), GFP_KERNEL); >

[PATCH v5 18/19] remoteproc: Properly deal with detach request

2021-02-11 Thread Mathieu Poirier
This patch introduces the capability to detach a remote processor that has been attached to or booted by the remoteproc core. For that to happen a rproc::ops::detach() operation need to be available. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen

[PATCH v5 19/19] remoteproc: Refactor rproc delete and cdev release path

2021-02-11 Thread Mathieu Poirier
Refactor function rproc_del() and rproc_cdev_release() to take into account the policy specified in the device tree. Signed-off-by: Mathieu Poirier Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_cdev.c | 18 +++--- drivers/remoteproc/remoteproc_core.c | 36

[PATCH v5 15/19] remoteproc: Properly deal with a kernel panic when attached

2021-02-11 Thread Mathieu Poirier
The panic handler operation of registered remote processors should also be called when remote processors have been attached to. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 6 +- 1 file changed, 5 insertions

[PATCH v5 13/19] remoteproc: Properly deal with the resource table

2021-02-11 Thread Mathieu Poirier
-by: Arnaud POULIQUEN Signed-off-by: Mathieu Poirier --- drivers/remoteproc/remoteproc_core.c | 70 ++ drivers/remoteproc/remoteproc_elf_loader.c | 24 +++- include/linux/remoteproc.h | 3 + 3 files changed, 95 insertions(+), 2 deletions(-) diff --git

[PATCH v5 17/19] remoteproc: Properly deal with a start request when attached

2021-02-11 Thread Mathieu Poirier
This patch takes into account scenarios where a remote processor has been attached to when receiving a "start" command from sysfs. As with the "running" case, the command can't be carried out if the remote processor is already in operation. Signed-off-by: Mathieu Poirier

[PATCH v5 16/19] remoteproc: Properly deal with a stop request when attached

2021-02-11 Thread Mathieu Poirier
This patch introduces the capability to stop a remote processor that has been attached to by the remoteproc core. For that to happen a rproc::ops::stop() operation need to be available. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc

[PATCH v5 12/19] remoteproc: Introduce function rproc_detach()

2021-02-11 Thread Mathieu Poirier
Introduce function rproc_detach() to enable the remoteproc core to release the resources associated with a remote processor without stopping its operation. Signed-off-by: Mathieu Poirier --- New for V5: - Fixed comment about rproc_actuate() that no longer exists. - Added call

[PATCH v5 14/19] remoteproc: Add return value to function rproc_shutdown()

2021-02-11 Thread Mathieu Poirier
Add a return value to function rproc_shutdown() in order to properly deal with error conditions that may occur. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 19 ++- include/linux/remoteproc.h

[PATCH v5 10/19] remoteproc: Add new detach() remoteproc operation

2021-02-11 Thread Mathieu Poirier
Add an new detach() operation in order to support scenarios where the remoteproc core is going away but the remote processor is kept operating. This could be the case when the system is rebooted or when the platform driver is removed. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan

[PATCH v5 11/19] remoteproc: Introduce function __rproc_detach()

2021-02-11 Thread Mathieu Poirier
te processor while the latter is kept operating. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan --- New for V5: - Removed fancy error recovery when ops->detach() fails to replicate what is done in rproc->stop(). --- drivers/remoteproc/remoteproc_core.c | 30 ++

[PATCH v5 09/19] remoteproc: stm32: Move memory parsing to rproc_ops

2021-02-11 Thread Mathieu Poirier
From: Arnaud POULIQUEN Some actions such as memory resources reallocation are needed when trying to reattach a co-processor. Use the prepare() operation for these actions. Co-developed-by: Mathieu Poirier Signed-off-by: Mathieu Poirier Signed-off-by: Arnaud POULIQUEN --- drivers/remoteproc

[PATCH v5 05/19] remoteproc: Add new RPROC_ATTACHED state

2021-02-11 Thread Mathieu Poirier
Add a new RPROC_ATTACHED state to take into account scenarios where the remoteproc core needs to attach to a remote processor that is booted by another entity. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_sysfs.c | 1

[PATCH v5 08/19] remoteproc: stm32: Move resource table setup to rproc_ops

2021-02-11 Thread Mathieu Poirier
needs to be available at a later time than the platform driver's probe() function. Signed-off-by: Mathieu Poirier --- New for V5: - stm32_rproc_get_loaded_rsc_table() now returns a resource table pointer. --- drivers/remoteproc/stm32_rproc.c | 141 +++ 1 file changed

[PATCH v5 07/19] remoteproc: Add new get_loaded_rsc_table() to rproc_ops

2021-02-11 Thread Mathieu Poirier
Add a new get_loaded_rsc_table() operation in order to support scenarios where the remoteproc core has booted a remote processor and detaches from it. When re-attaching to the remote processor, the core needs to know where the resource table has been placed in memory. Signed-off-by: Mathieu

[PATCH v5 06/19] remoteproc: Properly represent the attached state

2021-02-11 Thread Mathieu Poirier
-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 20 +--- drivers/remoteproc/remoteproc_sysfs.c | 5 + include/linux/remoteproc.h| 2 -- 3 files changed, 2 insertions(+), 25 deletions(-) diff --git

[PATCH v5 03/19] remoteproc: Remove useless check in rproc_del()

2021-02-11 Thread Mathieu Poirier
when in fact it no longer exist. Invariably calling rproc_shutdown() is fine since it will return immediately if the remote processor has already been switched off. Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 4

[PATCH v5 02/19] remoteproc: Re-check state in rproc_shutdown()

2021-02-11 Thread Mathieu Poirier
The state of the remote processor may have changed between the time a call to rproc_shutdown() was made and the time it is executed. To avoid moving forward with an operation that may have been cancelled, recheck while holding the mutex. Cc: Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan

[PATCH v5 00/19] remoteproc: Add support for detaching a remote processor

2021-02-11 Thread Mathieu Poirier
(1): remoteproc: stm32: Move memory parsing to rproc_ops Mathieu Poirier (18): dt-bindings: remoteproc: Add bindind to support autonomous processors remoteproc: Re-check state in rproc_shutdown() remoteproc: Remove useless check in rproc_del() remoteproc: Rename function rproc_actuate

[PATCH v5 04/19] remoteproc: Rename function rproc_actuate()

2021-02-11 Thread Mathieu Poirier
Rename function rproc_actuate() to rproc_attach(). That way it is easy to understand that it does the opposite of rproc_detach(). Signed-off-by: Mathieu Poirier Reviewed-by: Peng Fan Reviewed-by: Arnaud Pouliquen --- drivers/remoteproc/remoteproc_core.c | 8 1 file changed, 4

[PATCH v5 01/19] dt-bindings: remoteproc: Add bindind to support autonomous processors

2021-02-11 Thread Mathieu Poirier
if "autonomous-on-core-reboot" is specified in the remote processor DT node, the remoteproc core will detach the remote processor rather than switching it off. Signed-off-by: Mathieu Poirier Reviewed-by: Rob Herring --- .../bindings/remoteproc/remoteproc-core.yaml | 27 +

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-11 Thread Mathieu Poirier
.P. The TRBE can also generate a CPU > private interrupt (PPI) on address translation errors and when the buffer > is full. Overall implementation here is inspired from the Arm SPE driver. > > Cc: Mathieu Poirier > Cc: Mike Leach > Cc: Suzuki K Poulose > Signed-off-by: Anshuman Kha

[PATCH v2 3/3] Documentation: coresight: Add PID tracing description

2021-02-11 Thread Mathieu Poirier
. Signed-off-by: Leo Yan Reviewed-by: Suzuki K Poulose Reviewed-by: Mike Leach Message-Id: <20210206150833.42120-9-leo@linaro.org> Signed-off-by: Mathieu Poirier --- Documentation/trace/coresight/coresight.rst | 32 + 1 file changed, 32 insertions(+) diff

[PATCH v2 2/3] coresight: etm-perf: Support PID tracing for kernel at EL2

2021-02-11 Thread Mathieu Poirier
as for the option that enables PID tracing. I.e, contextid == contextid1, on EL1 kernel. contextid == contextid2, on EL2 kernel. Cc: Mathieu Poirier Cc: Al Grant Cc: Mike Leach Cc: Leo Yan Signed-off-by: Suzuki K Poulose [ Added two config fo

[PATCH v2 1/3] coresight: etm-perf: Clarify comment on perf options

2021-02-11 Thread Mathieu Poirier
Poulose Message-Id: <20210206150833.42120-2-leo@linaro.org> Signed-off-by: Mathieu Poirier --- .../hwtracing/coresight/coresight-etm-perf.c| 5 - include/linux/coresight-pmu.h | 17 - 2 files changed, 16 insertions(+), 6 deletions(-) diff

[PATCH v2 0/3] coresight: Patches for v5.12 (part 2)

2021-02-11 Thread Mathieu Poirier
Good morning, My previous submission had the wrong baseline and as such was missing a patch. This set applies properly on [1]. Thanks for the patience, Mathieu [1]. 48139bad913d ACRN: update MAINTAINERS: mailing list is subscribers-only Leo Yan (2): coresight: etm-perf: Clarify comment on

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-10 Thread Mathieu Poirier
.P. The TRBE can also generate a CPU > private interrupt (PPI) on address translation errors and when the buffer > is full. Overall implementation here is inspired from the Arm SPE driver. > > Cc: Mathieu Poirier > Cc: Mike Leach > Cc: Suzuki K Poulose > Signed-off-by: Anshuman Kha

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-10 Thread Mathieu Poirier
On Wed, Feb 10, 2021 at 09:42:29AM +0530, Anshuman Khandual wrote: > > > On 2/9/21 11:09 PM, Mathieu Poirier wrote: > > On Fri, Feb 05, 2021 at 10:53:30AM -0700, Mathieu Poirier wrote: > >> On Wed, Jan 27, 2021 at 02:25:35PM +0530, Anshuman Khandual wrote: > >&

[PATCH 2/2] Documentation: coresight: Add PID tracing description

2021-02-10 Thread Mathieu Poirier
. Signed-off-by: Leo Yan Reviewed-by: Suzuki K Poulose Reviewed-by: Mike Leach Message-Id: <20210206150833.42120-9-leo@linaro.org> Signed-off-by: Mathieu Poirier --- Documentation/trace/coresight/coresight.rst | 32 + 1 file changed, 32 insertions(+) diff

[PATCH 1/2] coresight: etm-perf: Support PID tracing for kernel at EL2

2021-02-10 Thread Mathieu Poirier
as for the option that enables PID tracing. I.e, contextid == contextid1, on EL1 kernel. contextid == contextid2, on EL2 kernel. Cc: Mathieu Poirier Cc: Al Grant Cc: Mike Leach Cc: Leo Yan Signed-off-by: Suzuki K Poulose [ Added two config fo

[PATCH 0/2] coresight: Patches for v5.12 (part 2)

2021-02-10 Thread Mathieu Poirier
Hi Greg, Please see if you can add these 2 patches to your 5.12 tally. No worries if you think it is too close to the merge window, I'll simply queue them for the next one. Thanks, Mathieu Leo Yan (1): Documentation: coresight: Add PID tracing description Suzuki K Poulose (1): coresight:

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-09 Thread Mathieu Poirier
On Fri, Feb 05, 2021 at 10:53:30AM -0700, Mathieu Poirier wrote: > On Wed, Jan 27, 2021 at 02:25:35PM +0530, Anshuman Khandual wrote: > > Trace Buffer Extension (TRBE) implements a trace buffer per CPU which is > > accessible via the system registers. The TRBE supports diffe

Re: [PATCH v4 00/17] remoteproc: Add support for detaching a rproc

2021-02-08 Thread Mathieu Poirier
On Wed, Feb 03, 2021 at 08:58:15AM +0100, Arnaud POULIQUEN wrote: > > > On 2/2/21 11:42 PM, Mathieu Poirier wrote: > > On Tue, Feb 02, 2021 at 09:54:13AM +0100, Arnaud POULIQUEN wrote: > >> > >> > >> On 2/2/21 1:49 AM, Mathieu Poirier wrote: > >>

Re: [PATCH v3 8/8] Documentation: coresight: Add PID tracing description

2021-02-08 Thread Mathieu Poirier
On Sat, Feb 06, 2021 at 11:08:33PM +0800, Leo Yan wrote: > After support the PID tracing for the kernel in EL1 or EL2, the usage > gets more complicated. > > This patch gives description for the PMU formats of contextID configs, > this can help users to understand how to control the knobs for PID

Re: [PATCH v3 4/8] perf cs-etm: Fix bitmap for option

2021-02-08 Thread Mathieu Poirier
> +#define ETM_SET_OPT_CTXTID (1 << 0) > +#define ETM_SET_OPT_TS (1 << 1) > +#define ETM_SET_OPT_MASK (ETM_SET_OPT_CTXTID | ETM_SET_OPT_TS) > + I would much rather see this fixed with the BIT() macro as it is done in the rest of this set than defining new constant.

Re: [PATCH v3 7/8] perf cs-etm: Detect pid in VMID for kernel running at EL2

2021-02-08 Thread Mathieu Poirier
ve a valid VMID. > > Cc: Mike Leach > Cc: Mathieu Poirier > Cc: Al Grant > Signed-off-by: Suzuki K Poulose > Co-developed-by: Leo Yan > Signed-off-by: Leo Yan Reviewed-by: Mathieu Poirier > --- > .../perf/util/cs-etm-decoder/cs-etm-decoder.c | 38

Re: [PATCH v3 6/8] perf cs-etm: Add helper cs_etm__get_pid_fmt()

2021-02-08 Thread Mathieu Poirier
On Sat, Feb 06, 2021 at 11:08:31PM +0800, Leo Yan wrote: > This patch adds helper function cs_etm__get_pid_fmt(), by passing > parameter "traceID", it returns the PID format. > > Signed-off-by: Leo Yan Reviewed-by: Mathieu Poirier > --- > t

Re: [PATCH v3 5/8] perf cs-etm: Support PID tracing in config

2021-02-08 Thread Mathieu Poirier
cified any configs > from "contextid", "contextid1" or "contextid2"; otherwise, it > dynamically sets config based on PMU format "contextid". > > Cc: Mike Leach > Cc: Mathieu Poirier > Cc: Al Grant > Signed-off-by: Suzuki K Poulose

Re: [PATCH v3 2/8] tools headers UAPI: Update tools' copy of linux/coresight-pmu.h

2021-02-08 Thread Mathieu Poirier
On Sat, Feb 06, 2021 at 11:08:27PM +0800, Leo Yan wrote: > To get the changes in the commit: > > "coresight: etm-perf: Clarify comment on perf options". > > Signed-off-by: Leo Yan > Reviewed-by: Suzuki K Poulose Reviewed-by: Mathieu Poirier > --- > t

Re: [PATCH V3 11/14] coresight: sink: Add TRBE driver

2021-02-05 Thread Mathieu Poirier
apply/patch:76: new blank line at EOF. + warning: 1 line adds whitespace errors. > Cc: Mathieu Poirier > Cc: Mike Leach > Cc: Suzuki K Poulose > Signed-off-by: Anshuman Khandual > --- > Changes in V3: > > - Added new DT bindings document TRBE.yaml > - Changed TRB

Re: [PATCH V3 08/14] coresight: core: Add support for dedicated percpu sinks

2021-02-04 Thread Mathieu Poirier
are not present for certain > > percpu source and sink devices which are exclusively linked and dependent. > > Build the path directly and skip connection scanning for such devices. > > > > Cc: Mathieu Poirier > > Cc: Mike Leach > > Cc: Suzuki K Poulose > > S

Re: [PATCH v3 06/15] rpmsg: update rpmsg_chrdev_register_device function

2021-02-04 Thread Mathieu Poirier
On Thu, 4 Feb 2021 at 08:11, Arnaud POULIQUEN wrote: > > > > On 2/4/21 1:44 PM, kernel test robot wrote: > > Hi Arnaud, > > > > I love your patch! Yet something to improve: > > > > [auto build test ERROR on linus/master] > > [also build test ERROR on v5.11-rc6 next-20210125] > > [cannot apply to

Re: [PATCH V3 07/14] coresight: etm-perf: Handle stale output handles

2021-02-03 Thread Mathieu Poirier
by free_aux() as long as the event is active and tracing, > also provides us with access to the critical information > needed to wind up a session even in the absence of an active > output_handle. > > This is not an issue for the legacy sinks as none of them supports > an IRQ and is centrally ha

Re: [PATCH v5] perf: cs-etm: update ETM metadata format

2021-02-03 Thread Mathieu Poirier
mbers of parameters than in use at the > time perf was built. > > Signed-off-by: Mike Leach > Reviewed-by: Leo Yan > Tested-by: Leo Yan > Reviewed-by: Mathieu Poirier Arnaldo - please consider for inclusing in your tree. Thanks, Mathieu > --- > > Changes si

Re: [PATCH v4 00/17] remoteproc: Add support for detaching a rproc

2021-02-02 Thread Mathieu Poirier
On Tue, Feb 02, 2021 at 09:54:13AM +0100, Arnaud POULIQUEN wrote: > > > On 2/2/21 1:49 AM, Mathieu Poirier wrote: > > On Wed, Jan 27, 2021 at 10:21:24AM +0100, Arnaud POULIQUEN wrote: > >> Hi Mathieu > >> > >> On 12/18/20 6:32 PM, Mathieu Poirier wr

Re: [PATCH V3 05/14] coresight: ete: Add support for ETE tracing

2021-02-02 Thread Mathieu Poirier
ource status register is programmed > before the tracing is turned on. For the moment simply write to > it indicating TraceActive. > > Cc: Mathieu Poirier > Cc: Mike Leach > Signed-off-by: Suzuki K Poulose > Signed-off-by: Anshuman Khandual > --- > drivers

Re: [PATCH V3 03/14] coresight: etm4x: Add support for PE OS lock

2021-02-02 Thread Mathieu Poirier
he > PE OS lock > > Cc: Mathieu Poirier > Cc: Mike Leach > Signed-off-by: Suzuki K Poulose > Signed-off-by: Anshuman Khandual > --- > drivers/hwtracing/coresight/coresight-etm4x-core.c | 50 > ++ > drivers/hwtracing/coresight/coresight-etm

Re: [PATCH V3 04/14] coresight: ete: Add support for ETE sysreg access

2021-02-02 Thread Mathieu Poirier
ers. Re-arrange the ETMv4x list > to share the common definitions and add the ETE sysreg support. > > Cc: Mike Leach > Cc: Mathieu Poirier > Signed-off-by: Suzuki K Poulose > Signed-off-by: Anshuman Khandual > --- > drivers/hwtracing/coresight/coresight-etm4x-core.c | 32 +

Re: [PATCH V3 03/14] coresight: etm4x: Add support for PE OS lock

2021-02-02 Thread Mathieu Poirier
he > PE OS lock > > Cc: Mathieu Poirier > Cc: Mike Leach > Signed-off-by: Suzuki K Poulose > Signed-off-by: Anshuman Khandual > --- > drivers/hwtracing/coresight/coresight-etm4x-core.c | 50 > ++ > drivers/hwtracing/coresight/coresight-etm

<    1   2   3   4   5   6   7   8   9   10   >