| .. | .. | 
|---|
 | 1 | +/* SPDX-License-Identifier: GPL-2.0-only */  | 
|---|
| 1 | 2 |  /* | 
|---|
| 2 | 3 |   *  linux/arch/arm/include/asm/pmu.h | 
|---|
| 3 | 4 |   * | 
|---|
| 4 | 5 |   *  Copyright (C) 2009 picoChip Designs Ltd, Jamie Iles | 
|---|
| 5 |  | - *  | 
|---|
| 6 |  | - * This program is free software; you can redistribute it and/or modify  | 
|---|
| 7 |  | - * it under the terms of the GNU General Public License version 2 as  | 
|---|
| 8 |  | - * published by the Free Software Foundation.  | 
|---|
| 9 |  | - *  | 
|---|
| 10 | 6 |   */ | 
|---|
| 11 | 7 |   | 
|---|
| 12 | 8 |  #ifndef __ARM_PMU_H__ | 
|---|
| .. | .. | 
|---|
| 77 | 73 |  	ARMPMU_ATTR_GROUP_COMMON, | 
|---|
| 78 | 74 |  	ARMPMU_ATTR_GROUP_EVENTS, | 
|---|
| 79 | 75 |  	ARMPMU_ATTR_GROUP_FORMATS, | 
|---|
 | 76 | +	ARMPMU_ATTR_GROUP_CAPS,  | 
|---|
| 80 | 77 |  	ARMPMU_NR_ATTR_GROUPS | 
|---|
| 81 | 78 |  }; | 
|---|
| 82 | 79 |   | 
|---|
| .. | .. | 
|---|
| 84 | 81 |  	struct pmu	pmu; | 
|---|
| 85 | 82 |  	cpumask_t	supported_cpus; | 
|---|
| 86 | 83 |  	char		*name; | 
|---|
 | 84 | +	int		pmuver;  | 
|---|
| 87 | 85 |  	irqreturn_t	(*handle_irq)(struct arm_pmu *pmu); | 
|---|
| 88 | 86 |  	void		(*enable)(struct perf_event *event); | 
|---|
| 89 | 87 |  	void		(*disable)(struct perf_event *event); | 
|---|
| .. | .. | 
|---|
| 102 | 100 |  	int		(*filter_match)(struct perf_event *event); | 
|---|
| 103 | 101 |  	int		num_events; | 
|---|
| 104 | 102 |  	bool		secure_access; /* 32-bit ARM only */ | 
|---|
| 105 |  | -#define ARMV8_PMUV3_MAX_COMMON_EVENTS 0x40  | 
|---|
 | 103 | +#define ARMV8_PMUV3_MAX_COMMON_EVENTS		0x40  | 
|---|
| 106 | 104 |  	DECLARE_BITMAP(pmceid_bitmap, ARMV8_PMUV3_MAX_COMMON_EVENTS); | 
|---|
 | 105 | +#define ARMV8_PMUV3_EXT_COMMON_EVENT_BASE	0x4000  | 
|---|
 | 106 | +	DECLARE_BITMAP(pmceid_ext_bitmap, ARMV8_PMUV3_MAX_COMMON_EVENTS);  | 
|---|
| 107 | 107 |  	struct platform_device	*plat_device; | 
|---|
| 108 | 108 |  	struct pmu_hw_events	__percpu *hw_events; | 
|---|
| 109 | 109 |  	struct hlist_node	node; | 
|---|
| 110 | 110 |  	struct notifier_block	cpu_pm_nb; | 
|---|
| 111 | 111 |  	/* the attr_groups array must be NULL-terminated */ | 
|---|
| 112 | 112 |  	const struct attribute_group *attr_groups[ARMPMU_NR_ATTR_GROUPS + 1]; | 
|---|
 | 113 | +	/* store the PMMIR_EL1 to expose slots */  | 
|---|
 | 114 | +	u64		reg_pmmir;  | 
|---|
| 113 | 115 |   | 
|---|
| 114 | 116 |  	/* Only to be used by ACPI probing code */ | 
|---|
| 115 | 117 |  	unsigned long acpi_cpuid; | 
|---|
| .. | .. | 
|---|
| 173 | 175 |   | 
|---|
| 174 | 176 |  #endif /* CONFIG_ARM_PMU */ | 
|---|
| 175 | 177 |   | 
|---|
 | 178 | +#define ARMV8_SPE_PDEV_NAME "arm,spe-v1"  | 
|---|
 | 179 | +  | 
|---|
| 176 | 180 |  #endif /* __ARM_PMU_H__ */ | 
|---|