arm_pmu: acpi: Add a representative platform device for TRBE
authorAnshuman Khandual <anshuman.khandual@arm.com>
Thu, 17 Aug 2023 05:54:03 +0000 (11:24 +0530)
committerWill Deacon <will@kernel.org>
Fri, 18 Aug 2023 17:07:10 +0000 (18:07 +0100)
commit1aa3d0274a4aac338ee45a3dfc3b17c944bcc2bc
treee0520212b012cae05dedab209f7cc2cf7a229db2
parent81e5ee471609848ee1ebf3beb2a46788113fe0eb
arm_pmu: acpi: Add a representative platform device for TRBE

ACPI TRBE does not have a HID for identification which could create and add
a platform device into the platform bus. Also without a platform device, it
cannot be probed and bound to a platform driver.

This creates a dummy platform device for TRBE after ascertaining that ACPI
provides required interrupts uniformly across all cpus on the system. This
device gets created inside drivers/perf/arm_pmu_acpi.c to accommodate TRBE
being built as a module.

Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com>
Link: https://lore.kernel.org/r/20230817055405.249630-3-anshuman.khandual@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
arch/arm64/include/asm/acpi.h
drivers/perf/arm_pmu_acpi.c
include/linux/perf/arm_pmu.h