From 7afe383db3fa4ff76719c78517560211e61fd18c Mon Sep 17 00:00:00 2001 From: "Wesley W. Terpstra" Date: Fri, 3 Feb 2017 16:21:09 -0800 Subject: [PATCH] Ecc: detect uncorrectable errors also for SEC --- src/main/scala/uncore/util/Ecc.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/scala/uncore/util/Ecc.scala b/src/main/scala/uncore/util/Ecc.scala index b478e3c2..bfaaed12 100644 --- a/src/main/scala/uncore/util/Ecc.scala +++ b/src/main/scala/uncore/util/Ecc.scala @@ -10,7 +10,7 @@ abstract class Decoding def uncorrected: UInt def corrected: UInt def correctable: Bool - def uncorrectable: Bool + def uncorrectable: Bool // If true, correctable should be ignored def error = correctable || uncorrectable } @@ -81,7 +81,7 @@ class SECCode extends Code def uncorrected = swizzle(y) def corrected = swizzle(((y << 1) ^ UIntToOH(syndrome)) >> 1) def correctable = syndrome.orR - def uncorrectable = Bool(false) + def uncorrectable = syndrome > UInt(n) } private def mapping(i: Int) = i-1-log2Up(i) }