mbox series

[RFC,0/3] arm64: SPE ACPI enablement

Message ID 20190209004718.3292087-1-jeremy.linton@arm.com
Headers show
Series arm64: SPE ACPI enablement | expand

Message

Jeremy Linton Feb. 9, 2019, 12:47 a.m. UTC
This patch series enables the Arm Statistical
Profiling Extension (SPE) on ACPI platforms.

This is possible because ACPI 6.3 uses a previously
reserved field in the MADT to store the SPE interrupt
number, similarly to how the normal PMU is
described. If a consistent valid interrupt exists
across all the cores in the system, a platform
device is registered. That then triggers the SPE module,
which runs as normal.

Jeremy Linton (3):
  ACPICA: ACPI 6.3: Add MADT/GICC/SPE extension.
  arm_pmu: acpi: spe: Add initial MADT/SPE probing
  perf: arm_spe: Enable ACPI/Platform automatic module loading

 arch/arm64/include/asm/acpi.h |  4 +++
 drivers/perf/arm_pmu_acpi.c   | 67 +++++++++++++++++++++++++++++++++++
 drivers/perf/arm_spe_pmu.c    | 11 ++++--
 include/acpi/actbl2.h         |  5 +--
 4 files changed, 83 insertions(+), 4 deletions(-)

-- 
2.17.2

Comments

Schmauss, Erik Feb. 11, 2019, 6:27 p.m. UTC | #1
> -----Original Message-----

> From: Jeremy Linton [mailto:jeremy.linton@arm.com]

> Sent: Friday, February 8, 2019 4:47 PM

> To: linux-arm-kernel@lists.infradead.org

> Cc: linux-kernel@vger.kernel.org; linux-acpi@vger.kernel.org;

> devel@acpica.org; catalin.marinas@arm.com; will.deacon@arm.com;

> mark.rutland@arm.com; Moore, Robert <robert.moore@intel.com>;

> Schmauss, Erik <erik.schmauss@intel.com>; Wysocki, Rafael J

> <rafael.j.wysocki@intel.com>; lenb@kernel.org; Jeremy Linton

> <jeremy.linton@arm.com>

> Subject: [RFC 1/3] ACPICA: ACPI 6.3: Add MADT/GICC/SPE extension.

> 

Hi Jeremy,

> [Placeholder patch for upstream ACPICA commit]


FYI: we are planning on releasing ACPICA patches by the end of this week at the latest.

Erik
> 

> Add just ACPI 6.3 changes associated with the arm64 SPE.

> 

> Signed-off-by: Jeremy Linton <jeremy.linton@arm.com>

> ---

>  include/acpi/actbl2.h | 5 +++--

>  1 file changed, 3 insertions(+), 2 deletions(-)

> 

> diff --git a/include/acpi/actbl2.h b/include/acpi/actbl2.h index

> c50ef7e6b942..4b58eb6cf64e 100644

> --- a/include/acpi/actbl2.h

> +++ b/include/acpi/actbl2.h

> @@ -623,7 +623,7 @@ struct acpi_madt_local_x2apic_nmi {

>  	u8 reserved[3];		/* reserved - must be zero */

>  };

> 

> -/* 11: Generic Interrupt (ACPI 5.0 + ACPI 6.0 changes) */

> +/* 11: Generic Interrupt (ACPI 5.0 + 6.0 + 6.3 changes) */

> 

>  struct acpi_madt_generic_interrupt {

>  	struct acpi_subtable_header header;

> @@ -641,7 +641,8 @@ struct acpi_madt_generic_interrupt {

>  	u64 gicr_base_address;

>  	u64 arm_mpidr;

>  	u8 efficiency_class;

> -	u8 reserved2[3];

> +	u8 reserved2;

> +	u16 spe_overflow_interrupt;

>  };

> 

>  /* Masks for Flags field above */

> --

> 2.17.2