To inject UE Errors

Linux Drivers

Release Date
2023-07-22
Configure the bit positions to generate UE Error
 
# echo 4 > /sys/devices/system/edac/zynqmp_ocm/inject_fault_count
# echo 7 > /sys/devices/system/edac/zynqmp_ocm/inject_uebitpos0
# echo 32 > /sys/devices/system/edac/zynqmp_ocm/inject_uebitpos1
Write any data to any OCM Memory area, so at the time of writing data the controller injects errors and will report when you read back
the location
# devmem 0xfffc0000 64 0xFFFFFFFFFFFF
# devmem 0xfffc0000
[   64.973665] Unhandled fault: synchronous external abort (0x92999219) at 0x0000007f9182b000)
[   64.973674] EDAC DEVICE0: UE: zynqmp_ocm instance: zynqmp_ocm0 block: zynqmp_ocm0 '
OCM ECC error type :UE
Addr: [0xFFFC0000]
Fault Data[31:0]: [0xFFFFFF7F]
Fault Data[63:32]: [0xFFFE]'
0x0000FFFEFFFFFF7F
here we have written 0xFFFFFFFFFFFF and configured bitposition0 as 7 and bitposition1 as 32,
so a  ctual Data Written: 0xFFFFFFFFFFFF
Fault Data              : 0xFFFEFFFFFF7F