Patch "drivers: perf: added capabilities for legacy PMU" has been added to the 6.7-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    drivers: perf: added capabilities for legacy PMU

to the 6.7-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     drivers-perf-added-capabilities-for-legacy-pmu.patch
and it can be found in the queue-6.7 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 5b8ca818c16cc39bfa611b471dd19750a8e0f184
Author: Vadim Shakirov <vadim.shakirov@xxxxxxxxxxxxx>
Date:   Tue Feb 27 20:00:01 2024 +0300

    drivers: perf: added capabilities for legacy PMU
    
    [ Upstream commit 65730fe8f4fb039683d76fa8ea7e8d18a53c6cc6 ]
    
    Added the PERF_PMU_CAP_NO_INTERRUPT flag because the legacy pmu driver
    does not provide sampling capabilities
    
    Added the PERF_PMU_CAP_NO_EXCLUDE flag because the legacy pmu driver
    does not provide the ability to disable counter incrementation in
    different privilege modes
    
    Suggested-by: Atish Patra <atishp@xxxxxxxxxxxx>
    Signed-off-by: Vadim Shakirov <vadim.shakirov@xxxxxxxxxxxxx>
    Reviewed-by: Atish Patra <atishp@xxxxxxxxxxxx>
    Fixes: 9b3e150e310e ("RISC-V: Add a simple platform driver for RISC-V  legacy perf")
    Link: https://lore.kernel.org/r/20240227170002.188671-2-vadim.shakirov@xxxxxxxxxxxxx
    Signed-off-by: Palmer Dabbelt <palmer@xxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/perf/riscv_pmu_legacy.c b/drivers/perf/riscv_pmu_legacy.c
index 79fdd667922e8..a85fc9a15f039 100644
--- a/drivers/perf/riscv_pmu_legacy.c
+++ b/drivers/perf/riscv_pmu_legacy.c
@@ -117,6 +117,8 @@ static void pmu_legacy_init(struct riscv_pmu *pmu)
 	pmu->event_mapped = pmu_legacy_event_mapped;
 	pmu->event_unmapped = pmu_legacy_event_unmapped;
 	pmu->csr_index = pmu_legacy_csr_index;
+	pmu->pmu.capabilities |= PERF_PMU_CAP_NO_INTERRUPT;
+	pmu->pmu.capabilities |= PERF_PMU_CAP_NO_EXCLUDE;
 
 	perf_pmu_register(&pmu->pmu, "cpu", PERF_TYPE_RAW);
 }




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux