perf/marvell: Fix !CONFIG_OF build for CN10K DDR PMU driver
authorWill Deacon <will@kernel.org>
Wed, 9 Mar 2022 12:31:00 +0000 (12:31 +0000)
committerWill Deacon <will@kernel.org>
Wed, 9 Mar 2022 12:31:00 +0000 (12:31 +0000)
commit6676a42f1e4f1b8ec166b723a3801b7113c25a0e
tree6dca6c01c1a80a25b5c5c933b29bdf76bb514610
parent0162052214c7e850566ecef41003603c26667b5d
perf/marvell: Fix !CONFIG_OF build for CN10K DDR PMU driver

When compiling the Marvell CN10K DDR PMU driver with CONFIG_OF=n, the
build fails:

  | drivers/perf/marvell_cn10k_ddr_pmu.c:723:35: error: 'cn10k_ddr_pmu_of_match' undeclared here (not in a function); did you mean 'cn10k_ddr_pmu_driver'?

Use `of_match_ptr()` to avoid referencing the non-existent match table
in this configuration.

Link: https://lore.kernel.org/r/202203091424.Vfe8J4W9-lkp@intel.com
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Will Deacon <will@kernel.org>
drivers/perf/marvell_cn10k_ddr_pmu.c