1
linux/drivers/hwtracing/coresight/coresight-etm4x-cfg.h
Mike Leach 7fdc9bb2ce coresight: config: Add preloaded configurations
Preload set of configurations.

This patch creates a small set of preloaded configurations and features
that are available immediately after coresight has been initialised.

The current set provides a strobing feature for ETMv4, that creates a
periodic sampling of trace by switching trace generation on and off
using counters in the ETM.

A configuration called "autofdo" is also provided that uses the 'strobing'
feature and provides a couple of preset values, selectable on the perf
command line.

Link: https://lore.kernel.org/r/20210723165444.1048-9-mike.leach@linaro.org
Signed-off-by: Mike Leach <mike.leach@linaro.org>
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Link: https://lore.kernel.org/r/20210818194022.379573-9-mathieu.poirier@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-08-18 22:33:28 +02:00

31 lines
765 B
C

/* SPDX-License-Identifier: GPL-2.0 */
/*
* Copyright (c) 2014-2020, The Linux Foundation. All rights reserved.
*/
#ifndef _CORESIGHT_ETM4X_CFG_H
#define _CORESIGHT_ETM4X_CFG_H
#include "coresight-config.h"
#include "coresight-etm4x.h"
/* ETMv4 specific config defines */
/* resource IDs */
#define ETM4_CFG_RES_CTR 0x001
#define ETM4_CFG_RES_CMP 0x002
#define ETM4_CFG_RES_CMP_PAIR0 0x003
#define ETM4_CFG_RES_CMP_PAIR1 0x004
#define ETM4_CFG_RES_SEL 0x005
#define ETM4_CFG_RES_SEL_PAIR0 0x006
#define ETM4_CFG_RES_SEL_PAIR1 0x007
#define ETM4_CFG_RES_SEQ 0x008
#define ETM4_CFG_RES_TS 0x009
#define ETM4_CFG_RES_MASK 0x00F
/* ETMv4 specific config functions */
int etm4_cscfg_register(struct coresight_device *csdev);
#endif /* CORESIGHT_ETM4X_CFG_H */