Skip to content

Commit fc51060

Browse files
hober-yaowilldeacon
authored andcommitted
perf: arm-ni: Fix missing platform_set_drvdata()
Add missing platform_set_drvdata in arm_ni_probe(), otherwise calling platform_get_drvdata() in remove returns NULL. Fixes: 4d5a768 ("perf: Add driver for Arm NI-700 interconnect PMU") Signed-off-by: Hongbo Yao <andy.xu@hj-micro.com> Reviewed-by: Robin Murphy <robin.murphy@arm.com> Link: https://lore.kernel.org/r/20250401054248.3985814-1-andy.xu@hj-micro.com Signed-off-by: Will Deacon <will@kernel.org>
1 parent 7f57afd commit fc51060

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/perf/arm-ni.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -660,6 +660,7 @@ static int arm_ni_probe(struct platform_device *pdev)
660660
ni->num_cds = num_cds;
661661
ni->part = part;
662662
ni->id = atomic_fetch_inc(&id);
663+
platform_set_drvdata(pdev, ni);
663664

664665
for (int v = 0; v < cfg.num_components; v++) {
665666
reg = readl_relaxed(cfg.base + NI_CHILD_PTR(v));

0 commit comments

Comments
 (0)