Skip to content

Commit 17bf68a

Browse files
Yicong Yangwilldeacon
authored andcommitted
drivers/perf: hisi_pcie: Fix TLP headers bandwidth counting
We make the initial value of event ctrl register as HISI_PCIE_INIT_SET and modify according to the user options. This will make TLP headers bandwidth only counting never take effect since HISI_PCIE_INIT_SET configures to count the TLP payloads bandwidth. Fix this by making the initial value of event ctrl register as 0. Fixes: 17d5739 ("drivers/perf: hisi: Add TLP filter support") Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20240829090332.28756-3-yangyicong@huawei.com Signed-off-by: Will Deacon <will@kernel.org>
1 parent daecd33 commit 17bf68a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/perf/hisilicon/hisi_pcie_pmu.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ static void hisi_pcie_pmu_writeq(struct hisi_pcie_pmu *pcie_pmu, u32 reg_offset,
208208
static u64 hisi_pcie_pmu_get_event_ctrl_val(struct perf_event *event)
209209
{
210210
u64 port, trig_len, thr_len, len_mode;
211-
u64 reg = HISI_PCIE_INIT_SET;
211+
u64 reg = 0;
212212

213213
/* Config HISI_PCIE_EVENT_CTRL according to event. */
214214
reg |= FIELD_PREP(HISI_PCIE_EVENT_M, hisi_pcie_get_real_event(event));

0 commit comments

Comments
 (0)