From: Athira Rajeev Date: Mon, 13 Jan 2025 07:58:58 +0000 (+0530) Subject: selftests/powerpc/pmu: Update comment with details to understand auxv_generic_compat_... X-Git-Tag: v6.15-rc1~133^2~50 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c96b1402cc8fe818b0aaaee280221a5e7b6b2242;p=thirdparty%2Flinux.git selftests/powerpc/pmu: Update comment with details to understand auxv_generic_compat_pmu() utility function auxv_generic_compat_pmu() utility function is to detect whether the system is having generic compat PMU. The check is based on base platform value from /proc/self/auxv. Update the comment with details on how auxv is used to detect the platform. Signed-off-by: Athira Rajeev Signed-off-by: Madhavan Srinivasan Link: https://patch.msgid.link/20250113075858.45137-5-atrajeev@linux.vnet.ibm.com --- diff --git a/tools/testing/selftests/powerpc/pmu/sampling_tests/misc.c b/tools/testing/selftests/powerpc/pmu/sampling_tests/misc.c index 1ba675802ee9a..8a538b6182a16 100644 --- a/tools/testing/selftests/powerpc/pmu/sampling_tests/misc.c +++ b/tools/testing/selftests/powerpc/pmu/sampling_tests/misc.c @@ -497,6 +497,13 @@ int get_thresh_cmp_val(struct event event) * Utility function to check for generic compat PMU * by comparing base_platform value from auxv and real * PVR value. + * auxv_base_platform() func gives information of "base platform" + * corresponding to PVR value. Incase, if the distro doesn't + * support platform PVR (missing cputable support), base platform + * in auxv will have a default value other than the real PVR's. + * In this case, ISAv3 PMU (generic compat PMU) will be registered + * in the system. auxv_generic_compat_pmu() makes use of the base + * platform value from auxv to do this check. */ static bool auxv_generic_compat_pmu(void) {