Skip to content

Commit f8f6211

Browse files
committed
Merge branch 'for-next/perf' into for-next/core
* for-next/perf: drivers/perf: hisi: Update HiSilicon PMU maintainers arm_pmu: acpi: Add a representative platform device for TRBE arm_pmu: acpi: Refactor arm_spe_acpi_register_device() hw_breakpoint: fix single-stepping when using bpf_overflow_handler perf/imx_ddr: don't enable counter0 if none of 4 counters are used perf/imx_ddr: speed up overflow frequency of cycle drivers/perf: hisi: Schedule perf session according to locality perf/arm-dmc620: Fix dmc620_pmu_irqs_lock/cpu_hotplug_lock circular lock dependency perf/smmuv3: Add MODULE_ALIAS for module auto loading perf/smmuv3: Enable HiSilicon Erratum 162001900 quirk for HIP08/09 perf: pmuv3: Remove comments from armv8pmu_[enable|disable]_event() perf/arm-cmn: Add CMN-700 r3 support perf/arm-cmn: Refactor HN-F event selector macros perf/arm-cmn: Remove spurious event aliases drivers/perf: Explicitly include correct DT includes perf: pmuv3: Add Cortex A520, A715, A720, X3 and X4 PMUs dt-bindings: arm: pmu: Add Cortex A520, A715, A720, X3, and X4 perf/smmuv3: Remove build dependency on ACPI perf: xgene_pmu: Convert to devm_platform_ioremap_resource() driver/perf: Add identifier sysfs file for Yitian 710 DDR
2 parents 7abb3e4 + 21b61fe commit f8f6211

28 files changed

+427
-147
lines changed

Documentation/arch/arm64/silicon-errata.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,9 @@ stable kernels.
195195
+----------------+-----------------+-----------------+-----------------------------+
196196
| Hisilicon | Hip08 SMMU PMCG | #162001800 | N/A |
197197
+----------------+-----------------+-----------------+-----------------------------+
198+
| Hisilicon | Hip08 SMMU PMCG | #162001900 | N/A |
199+
| | Hip09 SMMU PMCG | | |
200+
+----------------+-----------------+-----------------+-----------------------------+
198201
+----------------+-----------------+-----------------+-----------------------------+
199202
| Qualcomm Tech. | Kryo/Falkor v1 | E1003 | QCOM_FALKOR_ERRATUM_1003 |
200203
+----------------+-----------------+-----------------+-----------------------------+

Documentation/devicetree/bindings/arm/pmu.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,14 @@ properties:
4949
- arm,cortex-a77-pmu
5050
- arm,cortex-a78-pmu
5151
- arm,cortex-a510-pmu
52+
- arm,cortex-a520-pmu
5253
- arm,cortex-a710-pmu
54+
- arm,cortex-a715-pmu
55+
- arm,cortex-a720-pmu
5356
- arm,cortex-x1-pmu
5457
- arm,cortex-x2-pmu
58+
- arm,cortex-x3-pmu
59+
- arm,cortex-x4-pmu
5560
- arm,neoverse-e1-pmu
5661
- arm,neoverse-n1-pmu
5762
- arm,neoverse-n2-pmu

MAINTAINERS

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9306,7 +9306,7 @@ F: drivers/crypto/hisilicon/hpre/hpre_crypto.c
93069306
F: drivers/crypto/hisilicon/hpre/hpre_main.c
93079307

93089308
HISILICON HNS3 PMU DRIVER
9309-
M: Guangbin Huang <huangguangbin2@huawei.com>
9309+
M: Jijie Shao <shaojijie@huawei.com>
93109310
S: Supported
93119311
F: Documentation/admin-guide/perf/hns3-pmu.rst
93129312
F: drivers/perf/hisilicon/hns3_pmu.c
@@ -9344,7 +9344,7 @@ F: Documentation/devicetree/bindings/net/hisilicon*.txt
93449344
F: drivers/net/ethernet/hisilicon/
93459345

93469346
HISILICON PMU DRIVER
9347-
M: Shaokun Zhang <zhangshaokun@hisilicon.com>
9347+
M: Yicong Yang <yangyicong@hisilicon.com>
93489348
M: Jonathan Cameron <jonathan.cameron@huawei.com>
93499349
S: Supported
93509350
W: http://www.hisilicon.com

arch/arm/kernel/hw_breakpoint.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -626,7 +626,7 @@ int hw_breakpoint_arch_parse(struct perf_event *bp,
626626
hw->address &= ~alignment_mask;
627627
hw->ctrl.len <<= offset;
628628

629-
if (is_default_overflow_handler(bp)) {
629+
if (uses_default_overflow_handler(bp)) {
630630
/*
631631
* Mismatch breakpoints are required for single-stepping
632632
* breakpoints.
@@ -798,7 +798,7 @@ static void watchpoint_handler(unsigned long addr, unsigned int fsr,
798798
* Otherwise, insert a temporary mismatch breakpoint so that
799799
* we can single-step over the watchpoint trigger.
800800
*/
801-
if (!is_default_overflow_handler(wp))
801+
if (!uses_default_overflow_handler(wp))
802802
continue;
803803
step:
804804
enable_single_step(wp, instruction_pointer(regs));
@@ -811,7 +811,7 @@ static void watchpoint_handler(unsigned long addr, unsigned int fsr,
811811
info->trigger = addr;
812812
pr_debug("watchpoint fired: address = 0x%x\n", info->trigger);
813813
perf_bp_event(wp, regs);
814-
if (is_default_overflow_handler(wp))
814+
if (uses_default_overflow_handler(wp))
815815
enable_single_step(wp, instruction_pointer(regs));
816816
}
817817

@@ -886,7 +886,7 @@ static void breakpoint_handler(unsigned long unknown, struct pt_regs *regs)
886886
info->trigger = addr;
887887
pr_debug("breakpoint fired: address = 0x%x\n", addr);
888888
perf_bp_event(bp, regs);
889-
if (is_default_overflow_handler(bp))
889+
if (uses_default_overflow_handler(bp))
890890
enable_single_step(bp, addr);
891891
goto unlock;
892892
}

arch/arm64/include/asm/acpi.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,9 @@
4242
#define ACPI_MADT_GICC_SPE (offsetof(struct acpi_madt_generic_interrupt, \
4343
spe_interrupt) + sizeof(u16))
4444

45+
#define ACPI_MADT_GICC_TRBE (offsetof(struct acpi_madt_generic_interrupt, \
46+
trbe_interrupt) + sizeof(u16))
47+
4548
/* Basic configuration for ACPI */
4649
#ifdef CONFIG_ACPI
4750
pgprot_t __acpi_get_mem_attribute(phys_addr_t addr);

arch/arm64/kernel/hw_breakpoint.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -654,7 +654,7 @@ static int breakpoint_handler(unsigned long unused, unsigned long esr,
654654
perf_bp_event(bp, regs);
655655

656656
/* Do we need to handle the stepping? */
657-
if (is_default_overflow_handler(bp))
657+
if (uses_default_overflow_handler(bp))
658658
step = 1;
659659
unlock:
660660
rcu_read_unlock();
@@ -733,7 +733,7 @@ static u64 get_distance_from_watchpoint(unsigned long addr, u64 val,
733733
static int watchpoint_report(struct perf_event *wp, unsigned long addr,
734734
struct pt_regs *regs)
735735
{
736-
int step = is_default_overflow_handler(wp);
736+
int step = uses_default_overflow_handler(wp);
737737
struct arch_hw_breakpoint *info = counter_arch_bp(wp);
738738

739739
info->trigger = addr;

drivers/acpi/arm64/iort.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1711,7 +1711,10 @@ static void __init arm_smmu_v3_pmcg_init_resources(struct resource *res,
17111711
static struct acpi_platform_list pmcg_plat_info[] __initdata = {
17121712
/* HiSilicon Hip08 Platform */
17131713
{"HISI ", "HIP08 ", 0, ACPI_SIG_IORT, greater_than_or_equal,
1714-
"Erratum #162001800", IORT_SMMU_V3_PMCG_HISI_HIP08},
1714+
"Erratum #162001800, Erratum #162001900", IORT_SMMU_V3_PMCG_HISI_HIP08},
1715+
/* HiSilicon Hip09 Platform */
1716+
{"HISI ", "HIP09 ", 0, ACPI_SIG_IORT, greater_than_or_equal,
1717+
"Erratum #162001900", IORT_SMMU_V3_PMCG_HISI_HIP09},
17151718
{ }
17161719
};
17171720

drivers/perf/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ config ARM_PMU_ACPI
9292

9393
config ARM_SMMU_V3_PMU
9494
tristate "ARM SMMUv3 Performance Monitors Extension"
95-
depends on (ARM64 && ACPI) || (COMPILE_TEST && 64BIT)
95+
depends on ARM64 || (COMPILE_TEST && 64BIT)
9696
depends on GENERIC_MSI_IRQ
9797
help
9898
Provides support for the ARM SMMUv3 Performance Monitor Counter

drivers/perf/alibaba_uncore_drw_pmu.c

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,10 +236,37 @@ static const struct attribute_group ali_drw_pmu_cpumask_attr_group = {
236236
.attrs = ali_drw_pmu_cpumask_attrs,
237237
};
238238

239+
static ssize_t ali_drw_pmu_identifier_show(struct device *dev,
240+
struct device_attribute *attr,
241+
char *page)
242+
{
243+
return sysfs_emit(page, "%s\n", "ali_drw_pmu");
244+
}
245+
246+
static umode_t ali_drw_pmu_identifier_attr_visible(struct kobject *kobj,
247+
struct attribute *attr, int n)
248+
{
249+
return attr->mode;
250+
}
251+
252+
static struct device_attribute ali_drw_pmu_identifier_attr =
253+
__ATTR(identifier, 0444, ali_drw_pmu_identifier_show, NULL);
254+
255+
static struct attribute *ali_drw_pmu_identifier_attrs[] = {
256+
&ali_drw_pmu_identifier_attr.attr,
257+
NULL
258+
};
259+
260+
static const struct attribute_group ali_drw_pmu_identifier_attr_group = {
261+
.attrs = ali_drw_pmu_identifier_attrs,
262+
.is_visible = ali_drw_pmu_identifier_attr_visible
263+
};
264+
239265
static const struct attribute_group *ali_drw_pmu_attr_groups[] = {
240266
&ali_drw_pmu_events_attr_group,
241267
&ali_drw_pmu_cpumask_attr_group,
242268
&ali_drw_pmu_format_group,
269+
&ali_drw_pmu_identifier_attr_group,
243270
NULL,
244271
};
245272

drivers/perf/amlogic/meson_ddr_pmu_core.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
#include <linux/kernel.h>
1010
#include <linux/module.h>
1111
#include <linux/of.h>
12-
#include <linux/of_device.h>
13-
#include <linux/of_irq.h>
1412
#include <linux/perf_event.h>
1513
#include <linux/platform_device.h>
1614
#include <linux/printk.h>

0 commit comments

Comments
 (0)