hardware/peripherals/edac/ibecc.html · hardware/peripherals/edac/ibecc.rst 공식 원문 ↗

Zephyr 3.7.0 · Hardware · Peripherals · EDAC · IBECC

In-Band Error Correction Code(IBECC)

Out-of-band ECC가 없는 memory의 error detection·correction과 NMI policy를 설명합니다.

Official pathhardware/peripherals/edac/ibecc.html
Source filehardware/peripherals/edac/ibecc.rst
Source versionZephyr 3.7.0
TranslationFull · reviewed

본문 기준: Zephyr 3.7.0 LTS3 · 이후 유지보수 패치는 별도입니다.

Part 1

요약·해설

1/32 syndrome overhead, 세 operation mode, CE/UE logging과 atomic-only NMI synchronization을 다룹니다.

Memory

1/32 ECC syndrome overhead

Errors

CE · UE · injection

NMI

atomic synchronization only

Part 2

접을 수 있는 영어 원문 전체

영어 원문 전체 펼치기
원문 SHA-256 80755439B70CF7AC90D60D594765CF3E1CD97A26DF625D16DFF32EB2EC37B603
.. _edac_ibecc:

In Band Error Correction Code (IBECC)
#####################################

Overview
********

The mechanism initially found in Intel Elkhart Lake SOCs and later boards is
an integrated memory controller with IBECC.

The In-Band Error Correction Code (IBECC) improves reliability by providing
error detection and correction. IBECC can work for all or for specific regions
of physical memory space. The IBECC is useful for memory technologies that do
not support the out-of-band ECC.

IBECC adds memory overhead of 1/32 of the memory. This memory is not accessible
and used to store ECC syndrome data. IBECC converts read / write transactions
to two separate transactions: one for actual data and another for cache line
containing ECC value.

There is a debug feature IBECC Error Injection which helps to debug and verify
IBECC functionality. ECC errors are injected on the write path and cause ECC
errors on the read path.

IBECC Configuration
*******************

There are three IBECC operation modes which can be selected by Bootloader. They
are listed below:

* OPERATION_MODE = 0x0 sets functional mode to protect requests based on
  address range

* OPERATION_MODE = 0x1 sets functional mode to all requests not be protected and
  to ignore range checks

* OPERATION_MODE = 0x2 sets functional mode to protect all requests and ignore
  range checks

IBECC operational mode is configured through BIOS or Bootloader. For operation
mode 0 there are more BIOS configuration options such as memory regions.

Due to high security risk Error Injection capability should not be enabled for
production. Error Injection is only enabled for tests.

IBECC Logging
*************

IBECC logs the following fields:

* Error Address

* Error Syndrome

* Error Type

  * Correctable Error (CE) - error is detected and corrected by IBECC module.

  * Uncorrectable Error (UE) - error is detected by IBECC module and not
    automatically corrected.

The IBECC driver provides error type for the higher-level application to
implement desired policy with respect for handling those memory errors. Error
syndrome is not used in the IBECC driver but provided to higher-level
application.

Usage notes
***********

Exceptional care needs to be taken with Non Maskable Interrupt (NMI). NMI will
arrive at any time, even if the local CPU has disabled interrupts. That means
that no locking mechanism can protect code against an NMI happening. Zephyr's
IPC mechanisms universally use local IRQ locking as the base layer for all
higher-level synchronization primitives. So, you cannot share anything that is
"protected" by a lock with an NMI, because the protection does not work. The
only tool you have available for synchronization in the Zephyr API that works
against an NMI is the atomic layer. This also applies to callback function
which is called by NMI handler.

Configuration option
********************

Related configuration option:

* :kconfig:option:`CONFIG_EDAC_IBECC`

Part 3

한국어 전문 번역

개요

Intel Elkhart Lake SoC와 이후 board에서 처음 사용된 mechanism은 IBECC가 통합된 memory controller입니다.

In-Band Error Correction Code(IBECC)는 error detection·correction으로 reliability를 높입니다. Physical memory space 전체 또는 특정 region에 적용할 수 있으며 out-of-band ECC를 지원하지 않는 memory technology에 유용합니다.

IBECC는 memory의 1/32만큼 overhead를 추가합니다. 이 영역은 접근할 수 없고 ECC syndrome data를 저장합니다. IBECC는 read/write transaction을 실제 data용 transaction과 ECC 값을 담은 cache line용 transaction 두 개로 바꿉니다.

IBECC Error Injection debug 기능은 IBECC를 debug·검증하는 데 사용합니다. Write path에서 ECC error를 주입해 read path에서 ECC error가 발생하게 합니다.

IBECC 설정

Bootloader가 선택할 수 있는 IBECC operation mode는 세 가지입니다.

  • OPERATION_MODE = 0x0: address range에 따라 request를 보호합니다.
  • OPERATION_MODE = 0x1: 모든 request를 보호하지 않고 range check를 무시합니다.
  • OPERATION_MODE = 0x2: 모든 request를 보호하고 range check를 무시합니다.

Operational mode는 BIOS 또는 Bootloader에서 설정합니다. Mode 0에는 memory region 같은 BIOS option이 더 있습니다.

Error Injection은 security risk가 높으므로 production에서 절대 켜면 안 되며 test에서만 활성화합니다.

IBECC logging

IBECC는 Error Address, Error Syndrome, Error Type을 기록합니다.

  • Correctable Error(CE): IBECC module이 error를 감지하고 수정합니다.
  • Uncorrectable Error(UE): IBECC module이 감지하지만 자동 수정하지 못합니다.

IBECC driver는 상위 application이 memory error 처리 policy를 구현할 수 있도록 error type을 제공합니다. Error syndrome은 driver 내부에서 쓰지 않지만 상위 application에 전달합니다.

사용 시 주의 사항

Non Maskable Interrupt(NMI)는 local CPU가 interrupt를 disable해도 언제든 도착하므로 어떤 lock도 NMI 발생으로부터 code를 보호할 수 없습니다. Zephyr IPC mechanism은 모두 local IRQ lock을 상위 synchronization primitive의 기반으로 사용하므로 lock으로 보호한다고 생각한 data를 NMI와 공유할 수 없습니다.

Zephyr API에서 NMI에 대해서도 동작하는 유일한 synchronization 수단은 atomic layer입니다. 이 제한은 NMI handler가 호출하는 callback function에도 적용됩니다.

설정 option

관련 설정 option은 CONFIG_EDAC_IBECC입니다.

Source

출처

영어 원문에는 문단, 문서 지시문, 표, 코드, 코드 심벌, 경로를 그대로 보존했습니다.