From 6da09a5853a26d87e5d3a56791db6a0b04fc001e Mon Sep 17 00:00:00 2001 From: Minda Chen Date: Thu, 2 Mar 2023 17:16:01 +0800 Subject: [PATCH] perf: sbi: disable cpu hotplug callback. register cpu hotplug callback will cause dhrystone and coremark benchmark reduce the scores. this CPU hotplug ops will do in sbi cpu/on and off. So disable this no side effect. Signed-off-by: Minda Chen Signed-off-by: Hal Feng --- drivers/perf/riscv_pmu_sbi.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/perf/riscv_pmu_sbi.c b/drivers/perf/riscv_pmu_sbi.c index de4f47f73919..69dc2148feda 100644 --- a/drivers/perf/riscv_pmu_sbi.c +++ b/drivers/perf/riscv_pmu_sbi.c @@ -1114,9 +1114,11 @@ static int pmu_sbi_device_probe(struct platform_device *pdev) } pdev->dev.groups = pmu_sbi_groups; +#ifndef CONFIG_ARCH_STARFIVE ret = cpuhp_state_add_instance(CPUHP_AP_PERF_RISCV_STARTING, &pmu->node); if (ret) return ret; +#endif ret = riscv_pm_pmu_register(pmu); if (ret)