Add EDAC support for Altera SDRAM Controller
Subsystems (3)
[PATCHv6 1/3] dt: bindings: Addition of the Altera SDRAM controller [PATCHv6 2/3] dt: bindings: Addition of the Altera SDRAM EDAC [PATCHv6 3/3] edac: altera: Add EDAC support for Altera SoC SDRAM
PATCH v6 1/3 devicetree: Addition of the Altera SDRAM controller
From: Thor Thayer <[email protected]>
v2: Changes to SoC SDRAM EDAC code.
v3: Implement code suggestions for SDRAM EDAC code.
v4: Remove syscon from SDRAM controller bindings.
v5: No Change, bump version for consistency.
v6: Only map the ctrlcfg register as syscon.
--- .../bindings/arm/altera/socfpga-sdram.txt | 11 +++++++++++ arch/arm/boot/dts/socfpga.dtsi | 5 +++++ 2 files changed, 16 insertions(+) create mode 100644 Documentation/devicetree/bindings/arm/altera/socfpga-sdram.txt
Documentation/devicetree/bindings/arm/altera/socfpga-sdram.txt new file +11 -0
@@ -0,0 +1,11 @@ +Altera SOCFPGA SDRAM Controller + +Required properties: +- compatible : "altr,sdr-ctl"; +- reg : Should contain 1 register ranges(address and length) + +Example: + sdrctl@ffc25000 { + compatible = "altr,sdr-ctl"; + reg = <0xffc25000 0x4>; + };
arch/arm/boot/dts/socfpga.dtsi +5 -0
@@ -682,6 +682,11 @@ clocks = <&l4_sp_clk>; }; + sdrctl@ffc25000 { + compatible = "altr,sdr-ctl", "syscon"; + reg = <0xffc25000 0x4>; + }; + rst: rstmgr@ffd05000 { compatible = "altr,rst-mgr"; reg = <0xffd05000 0x1000>;
Signature · 1 line
1.7.9.5
PATCH v6 2/3 devicetree: Addition of the Altera SDRAM EDAC
In reply to [email protected]From: Thor Thayer <[email protected]>
v2: Changes to SoC EDAC source code.
v3: Fix typo in device tree documentation.
v4,v5: No changes - bump version for consistency.
v6: Assign ECC registers in SDRAM controller to EDAC
--- .../bindings/arm/altera/socfpga-sdram-edac.txt | 15 +++++++++++++++ arch/arm/boot/dts/socfpga.dtsi | 6 ++++++ 2 files changed, 21 insertions(+) create mode 100644 Documentation/devicetree/bindings/arm/altera/socfpga-sdram-edac.txt
Documentation/devicetree/bindings/arm/altera/socfpga-sdram-edac.txt new file +15 -0
@@ -0,0 +1,15 @@ +Altera SOCFPGA SDRAM Error Detection & Correction [EDAC] + +Required properties: +- compatible : should contain "altr,sdram-edac"; +- reg : should contain the ECC register range in sdram + controller (address and length). +- interrupts : Should contain the SDRAM ECC IRQ in the + appropriate format for the IRQ controller. + +Example: + sdramedac@0 { + compatible = "altr,sdram-edac"; + reg = <0xffc2502C 0x28>; + interrupts = <0 39 4>; + };
arch/arm/boot/dts/socfpga.dtsi +6 -0
@@ -687,6 +687,12 @@ reg = <0xffc25000 0x4>; }; + sdramedac@0 { + compatible = "altr,sdram-edac"; + reg = <0xffc2502C 0x28>; + interrupts = <0 39 4>; + }; + rst: rstmgr@ffd05000 { compatible = "altr,rst-mgr"; reg = <0xffd05000 0x1000>;
Signature · 1 line
1.7.9.5
v6 cover Addition of Altera SDRAM EDAC
In reply to [email protected]From: Thor Thayer <[email protected]>
Addition of the Altera SDRAM controller to the EDAC driver.
Thor Thayer (3):
Addition of the Altera SDRAM controller bindings and device tree
changes to the Altera SoC project.
Addition of the Altera SDRAM EDAC bindings and device tree
changes to the Altera SoC project.
edac: altera: Add EDAC support for Altera SoC SDRAM Controller.
This patch adds support for the CycloneV and ArriaV SDRAM
controllers. Correction and reporting of SBEs, Panic on DBEs.
.../bindings/arm/altera/socfpga-sdram-edac.txt | 15 + .../bindings/arm/altera/socfpga-sdram.txt | 11 + arch/arm/boot/dts/socfpga.dtsi | 11 + drivers/edac/Kconfig | 9 + drivers/edac/Makefile | 2 + drivers/edac/altera_edac.c | 448 ++++++++++++++++++++ 6 files changed, 496 insertions(+) create mode 100644 Documentation/devicetree/bindings/arm/altera/socfpga-sdram-edac.txt create mode 100644 Documentation/devicetree/bindings/arm/altera/socfpga-sdram.txt create mode 100644 drivers/edac/altera_edac.c
Signature · 1 line
1.7.9.5
PATCH v6 3/3 edac: altera: Add EDAC support for SDRAM Ctlr
In reply to [email protected]From: Thor Thayer <[email protected]>
v2: Use the SDRAM controller registers to calculate memory size
instead of the Device Tree. Update To & Cc list. Add maintainer information.
v3: EDAC driver cleanup based on comments from Mailing list.
v4: Panic on DBE. Add macro around inject-error reads to prevent
them from being optimized out. Remove of_match_ptr since this will always use Device Tree.
v5: Addition of printk to trigger function to ensure read vars
are not optimized out.
v6: Changes to split out shared SDRAM controller reg (offset 0x00)
as a syscon device and allocate ECC specific SDRAM registers to EDAC.
--- drivers/edac/Kconfig | 9 + drivers/edac/Makefile | 2 + drivers/edac/altera_edac.c | 448 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 459 insertions(+) create mode 100644 drivers/edac/altera_edac.c
drivers/edac/Kconfig +9 -0
@@ -368,4 +368,13 @@ config EDAC_OCTEON_PCI Support for error detection and correction on the Cavium Octeon family of SOCs. +config EDAC_ALTERA_MC + bool "Altera SDRAM Memory Controller EDAC" + depends on EDAC_MM_EDAC && ARCH_SOCFPGA + help + Support for error detection and correction on the + Altera SDRAM memory controller. Note that the + preloader must initialize the SDRAM before loading + the kernel. + endif # EDAC
drivers/edac/Makefile +2 -0
@@ -64,3 +64,5 @@ obj-$(CONFIG_EDAC_OCTEON_PC) += octeon_edac-pc.o obj-$(CONFIG_EDAC_OCTEON_L2C) += octeon_edac-l2c.o obj-$(CONFIG_EDAC_OCTEON_LMC) += octeon_edac-lmc.o obj-$(CONFIG_EDAC_OCTEON_PCI) += octeon_edac-pci.o + +obj-$(CONFIG_EDAC_ALTERA_MC) += altera_edac.o
drivers/edac/altera_edac.c new file +448 -0
448 lines not on this page · raw message
Signature · 1 line
1.7.9.5