Loading Documentation/devicetree/bindings/edac/kryo-edac.txt 0 → 100644 +32 −0 Original line number Diff line number Diff line * Kryo EDAC node Kryo EDAC node is defined to describe on-chip error detection and correction for the Kryo core. Kryo will report all SBE and DBE found in L1/L2/L3/SCU caches in two registers: ERRXSTATUS - Error Record Primary Status Register ERRXMISC0 - Error Record Miscellaneous Register Current implementation of Kryo ECC mechanism is based on interrupts. The following section describes the DT node binding for kryo_cpu_erp. Required properties: - compatible : Shall be "arm,arm64-kryo-cpu-erp". - interrupts : Interrupt-specifier for L1/L2, L3/SCU error IRQ(s) - interrupt-names : Descriptive names of the interrupts Example: kryo-erp { compatible = "arm,arm64-kryo-cpu-erp"; interrupts = <1 6 4>, <1 7 4>, <0 34 4>, <0 35 4>; interrupt-names = "l1-l2-faultirq", "l1-l2-errirq", "l3-scu-errirq", "l3-scu-faultirq"; }; arch/arm64/include/asm/kryo-arm64-edac.h 0 → 100644 +15 −0 Original line number Diff line number Diff line /* SPDX-License-Identifier: GPL-2.0 */ /* * Copyright (c) 2017-2018, The Linux Foundation. All rights reserved. */ #ifndef ASM_KRYO_EDAC_H #define ASM_KRYO_EDAC_H #if defined(CONFIG_EDAC_KRYO_ARM64) void kryo_poll_cache_errors(void *info); #else static inline void kryo_poll_cache_errors(void *info) { } #endif #endif arch/arm64/mm/fault.c +2 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ #include <asm/system_misc.h> #include <asm/pgtable.h> #include <asm/tlbflush.h> #include <asm/kryo-arm64-edac.h> #include <asm/traps.h> #include <acpi/ghes.h> Loading Loading @@ -620,6 +621,7 @@ static int do_alignment_fault(unsigned long addr, unsigned int esr, static int do_bad(unsigned long addr, unsigned int esr, struct pt_regs *regs) { kryo_poll_cache_errors(NULL); return 1; /* "fault" */ } Loading drivers/edac/Kconfig +41 −0 Original line number Diff line number Diff line Loading @@ -446,6 +446,47 @@ config EDAC_SYNOPSYS Support for error detection and correction on the Synopsys DDR memory controller. config EDAC_KRYO_ARM64 depends on ARM64 tristate "ARM KRYO Gold and Silver L1/L2/L3/SCU Caches" help Support for error detection and correction on the Kryo3xx Gold and Silver CPUs. Reports errors caught by Kryo3xx ECC mechanism. For debugging issues having to do with stability and overall system health, you should probably say 'Y' here. config EDAC_KRYO_ARM64_POLL depends on EDAC_KRYO_ARM64 bool "Poll on kryo ECC registers - kryo" help This option chooses whether or not you want to poll on the Kryo3xx ECC registers. When this is enabled, the polling rate can be set as a module parameter. By default, it will call the polling function every second. This option should only be used if the associated interrupt lines are not enabled. config EDAC_KRYO_ARM64_PANIC_ON_CE depends on EDAC_KRYO_ARM64 bool "Panic on correctable errors - kryo" help Forcibly cause a kernel panic if an correctable error (CE) is detected, even though the error is (by definition) correctable and would otherwise result in no adverse system effects. This can reduce debugging times on hardware which may be operating at voltages or frequencies outside normal specification. For production builds, you should definitely say 'N' here. config EDAC_KRYO_ARM64_PANIC_ON_UE depends on EDAC_KRYO_ARM64 bool "Panic on uncorrectable errors - kryo" help Forcibly cause a kernel panic if an uncorrectable error (UE) is detected. This can reduce debugging times on hardware which may be operating at voltages or frequencies outside normal specification. For production builds, you should probably say 'N' here. config EDAC_XGENE tristate "APM X-Gene SoC" depends on (ARM64 || COMPILE_TEST) Loading drivers/edac/Makefile +1 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ obj-$(CONFIG_EDAC_IE31200) += ie31200_edac.o obj-$(CONFIG_EDAC_X38) += x38_edac.o obj-$(CONFIG_EDAC_I82860) += i82860_edac.o obj-$(CONFIG_EDAC_R82600) += r82600_edac.o obj-$(CONFIG_EDAC_KRYO_ARM64) += kryo_arm64_edac.o amd64_edac_mod-y := amd64_edac.o amd64_edac_mod-$(CONFIG_EDAC_DEBUG) += amd64_edac_dbg.o Loading Loading
Documentation/devicetree/bindings/edac/kryo-edac.txt 0 → 100644 +32 −0 Original line number Diff line number Diff line * Kryo EDAC node Kryo EDAC node is defined to describe on-chip error detection and correction for the Kryo core. Kryo will report all SBE and DBE found in L1/L2/L3/SCU caches in two registers: ERRXSTATUS - Error Record Primary Status Register ERRXMISC0 - Error Record Miscellaneous Register Current implementation of Kryo ECC mechanism is based on interrupts. The following section describes the DT node binding for kryo_cpu_erp. Required properties: - compatible : Shall be "arm,arm64-kryo-cpu-erp". - interrupts : Interrupt-specifier for L1/L2, L3/SCU error IRQ(s) - interrupt-names : Descriptive names of the interrupts Example: kryo-erp { compatible = "arm,arm64-kryo-cpu-erp"; interrupts = <1 6 4>, <1 7 4>, <0 34 4>, <0 35 4>; interrupt-names = "l1-l2-faultirq", "l1-l2-errirq", "l3-scu-errirq", "l3-scu-faultirq"; };
arch/arm64/include/asm/kryo-arm64-edac.h 0 → 100644 +15 −0 Original line number Diff line number Diff line /* SPDX-License-Identifier: GPL-2.0 */ /* * Copyright (c) 2017-2018, The Linux Foundation. All rights reserved. */ #ifndef ASM_KRYO_EDAC_H #define ASM_KRYO_EDAC_H #if defined(CONFIG_EDAC_KRYO_ARM64) void kryo_poll_cache_errors(void *info); #else static inline void kryo_poll_cache_errors(void *info) { } #endif #endif
arch/arm64/mm/fault.c +2 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ #include <asm/system_misc.h> #include <asm/pgtable.h> #include <asm/tlbflush.h> #include <asm/kryo-arm64-edac.h> #include <asm/traps.h> #include <acpi/ghes.h> Loading Loading @@ -620,6 +621,7 @@ static int do_alignment_fault(unsigned long addr, unsigned int esr, static int do_bad(unsigned long addr, unsigned int esr, struct pt_regs *regs) { kryo_poll_cache_errors(NULL); return 1; /* "fault" */ } Loading
drivers/edac/Kconfig +41 −0 Original line number Diff line number Diff line Loading @@ -446,6 +446,47 @@ config EDAC_SYNOPSYS Support for error detection and correction on the Synopsys DDR memory controller. config EDAC_KRYO_ARM64 depends on ARM64 tristate "ARM KRYO Gold and Silver L1/L2/L3/SCU Caches" help Support for error detection and correction on the Kryo3xx Gold and Silver CPUs. Reports errors caught by Kryo3xx ECC mechanism. For debugging issues having to do with stability and overall system health, you should probably say 'Y' here. config EDAC_KRYO_ARM64_POLL depends on EDAC_KRYO_ARM64 bool "Poll on kryo ECC registers - kryo" help This option chooses whether or not you want to poll on the Kryo3xx ECC registers. When this is enabled, the polling rate can be set as a module parameter. By default, it will call the polling function every second. This option should only be used if the associated interrupt lines are not enabled. config EDAC_KRYO_ARM64_PANIC_ON_CE depends on EDAC_KRYO_ARM64 bool "Panic on correctable errors - kryo" help Forcibly cause a kernel panic if an correctable error (CE) is detected, even though the error is (by definition) correctable and would otherwise result in no adverse system effects. This can reduce debugging times on hardware which may be operating at voltages or frequencies outside normal specification. For production builds, you should definitely say 'N' here. config EDAC_KRYO_ARM64_PANIC_ON_UE depends on EDAC_KRYO_ARM64 bool "Panic on uncorrectable errors - kryo" help Forcibly cause a kernel panic if an uncorrectable error (UE) is detected. This can reduce debugging times on hardware which may be operating at voltages or frequencies outside normal specification. For production builds, you should probably say 'N' here. config EDAC_XGENE tristate "APM X-Gene SoC" depends on (ARM64 || COMPILE_TEST) Loading
drivers/edac/Makefile +1 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ obj-$(CONFIG_EDAC_IE31200) += ie31200_edac.o obj-$(CONFIG_EDAC_X38) += x38_edac.o obj-$(CONFIG_EDAC_I82860) += i82860_edac.o obj-$(CONFIG_EDAC_R82600) += r82600_edac.o obj-$(CONFIG_EDAC_KRYO_ARM64) += kryo_arm64_edac.o amd64_edac_mod-y := amd64_edac.o amd64_edac_mod-$(CONFIG_EDAC_DEBUG) += amd64_edac_dbg.o Loading