EDAC: OcteonTX: Add EDAC driver OcteonTX2/Octeon10
Subsystems (4)
PATCH 1/1 EDAC: OcteonTX: Add EDAC driver OcteonTX2/Octeon10
Marvell OcteonTX2/Octeon10 (CN10K) SoCs have support for EDAC capable on-chip peripherals, namely the DRAM controllers and internal memory controllers for tad/cache diagnostics. Platforms support correct one bit errors and detect two bit errors. Driver get notified via SDEI after firmware first handling from TF-ARM Return the apei_hest_parse function, which we use for error source enumeration, and adapt the HEST error status
block address after being modified by firmware to satisfy DRAM property and layout. Revert commit:
commit 06606646af97 ("ACPI: APEI: mark apei_hest_parse() static")
Signed-off-by Vasyl Gomonovych <[email protected]>
--- drivers/acpi/apei/hest.c | 5 +- drivers/edac/Kconfig | 11 + drivers/edac/Makefile | 1 + drivers/edac/octeontx_edac.c | 598 +++++++++++++++++++++++++++++++++++ drivers/edac/octeontx_edac.h | 102 ++++++ include/acpi/apei.h | 3 + 6 files changed, 717 insertions(+), 3 deletions(-) create mode 100644 drivers/edac/octeontx_edac.c create mode 100644 drivers/edac/octeontx_edac.h
drivers/acpi/apei/hest.c +2 -3
@@ -86,9 +86,7 @@ static int hest_esrc_len(struct acpi_hest_header *hest_hdr)return len; }; -typedef int (*apei_hest_func_t )(struct acpi_hest_header *hest_hdr,void *data); - -static int apei_hest_parse (apei_hest_func_t func,void *data) +int apei_hest_parse (apei_hest_func_t func,void *data) {struct acpi_hest_header *hest_hdr;int i, rc, len;
@@ -123,6 +121,7 @@ static int apei_hest_parse(apei_hest_func_t func, void *data)return 0 ; } +EXPORT_SYMBOL_GPL (apei_hest_parse);/* * Check if firmware advertises firmware first mode. We need FF bit to be set
drivers/edac/Kconfig +11 -0
@@ -539,4 +539,15 @@ config EDAC_DMC520 Support for error detection and correction on the SoCs with ARM DMC-520 DRAM controller. +config EDAC_OCTEONTX + bool "Marvell OcteonTX2 Octeon10 SoC EDAC" + select ARM_SDE_INTERFACE + select ACPI_APEI_GHES + help + Support for error detection and correction on the + Marvell OcteonTX2 and Octeon10 (CN10K) SoCs. + This driver will allow SECDED errors detected in + the firmware first model and reported via SDEI callbacks. + EDAC Driver report Single Bit Errors and Double Bit Errors. + endif # EDAC
drivers/edac/Makefile +1 -0
@@ -84,3 +84,4 @@ obj-$(CONFIG_EDAC_QCOM) += qcom_edac.o obj-$(CONFIG_EDAC_ASPEED) += aspeed_edac.o obj-$(CONFIG_EDAC_BLUEFIELD) += bluefield_edac.o obj-$(CONFIG_EDAC_DMC520) += dmc520_edac.o +obj-$(CONFIG_EDAC_OCTEONTX) += octeontx_edac.o
drivers/edac/octeontx_edac.c new file +598 -0
598 lines not on this page · raw message
drivers/edac/octeontx_edac.h new file +102 -0
102 lines not on this page · raw message
include/acpi/apei.h +3 -0
@@ -39,6 +39,9 @@ void __init acpi_hest_init(void);static inline void acpi_hest_init (void ) { }#endif +typedef int (*apei_hest_func_t )(struct acpi_hest_header *hest_hdr,void *data); +int apei_hest_parse (apei_hest_func_t func,void *data); +int erst_write (const struct cper_record_header *record);ssize_t erst_get_record_count (void );int erst_get_record_id_begin (int *pos);
Signature · 1 line
2.17.1