edac.txt 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808
  1. EDAC - Error Detection And Correction
  2. =====================================
  3. "bluesmoke" was the name for this device driver when it was "out-of-tree"
  4. and maintained at sourceforge.net. When it was pushed into 2.6.16 for the
  5. first time, it was renamed to 'EDAC'.
  6. PURPOSE
  7. -------
  8. The 'edac' kernel module's goal is to detect and report hardware errors
  9. that occur within the computer system running under linux.
  10. MEMORY
  11. ------
  12. Memory Correctable Errors (CE) and Uncorrectable Errors (UE) are the
  13. primary errors being harvested. These types of errors are harvested by
  14. the 'edac_mc' device.
  15. Detecting CE events, then harvesting those events and reporting them,
  16. *can* but must not necessarily be a predictor of future UE events. With
  17. CE events only, the system can and will continue to operate as no data
  18. has been damaged yet.
  19. However, preventive maintenance and proactive part replacement of memory
  20. DIMMs exhibiting CEs can reduce the likelihood of the dreaded UE events
  21. and system panics.
  22. OTHER HARDWARE ELEMENTS
  23. -----------------------
  24. A new feature for EDAC, the edac_device class of device, was added in
  25. the 2.6.23 version of the kernel.
  26. This new device type allows for non-memory type of ECC hardware detectors
  27. to have their states harvested and presented to userspace via the sysfs
  28. interface.
  29. Some architectures have ECC detectors for L1, L2 and L3 caches,
  30. along with DMA engines, fabric switches, main data path switches,
  31. interconnections, and various other hardware data paths. If the hardware
  32. reports it, then a edac_device device probably can be constructed to
  33. harvest and present that to userspace.
  34. PCI BUS SCANNING
  35. ----------------
  36. In addition, PCI devices are scanned for PCI Bus Parity and SERR Errors
  37. in order to determine if errors are occurring during data transfers.
  38. The presence of PCI Parity errors must be examined with a grain of salt.
  39. There are several add-in adapters that do *not* follow the PCI specification
  40. with regards to Parity generation and reporting. The specification says
  41. the vendor should tie the parity status bits to 0 if they do not intend
  42. to generate parity. Some vendors do not do this, and thus the parity bit
  43. can "float" giving false positives.
  44. There is a PCI device attribute located in sysfs that is checked by
  45. the EDAC PCI scanning code. If that attribute is set, PCI parity/error
  46. scanning is skipped for that device. The attribute is:
  47. broken_parity_status
  48. and is located in /sys/devices/pci<XXX>/0000:XX:YY.Z directories for
  49. PCI devices.
  50. VERSIONING
  51. ----------
  52. EDAC is composed of a "core" module (edac_core.ko) and several Memory
  53. Controller (MC) driver modules. On a given system, the CORE is loaded
  54. and one MC driver will be loaded. Both the CORE and the MC driver (or
  55. edac_device driver) have individual versions that reflect current
  56. release level of their respective modules.
  57. Thus, to "report" on what version a system is running, one must report
  58. both the CORE's and the MC driver's versions.
  59. LOADING
  60. -------
  61. If 'edac' was statically linked with the kernel then no loading
  62. is necessary. If 'edac' was built as modules then simply modprobe
  63. the 'edac' pieces that you need. You should be able to modprobe
  64. hardware-specific modules and have the dependencies load the necessary
  65. core modules.
  66. Example:
  67. $> modprobe amd76x_edac
  68. loads both the amd76x_edac.ko memory controller module and the edac_mc.ko
  69. core module.
  70. SYSFS INTERFACE
  71. ---------------
  72. EDAC presents a 'sysfs' interface for control and reporting purposes. It
  73. lives in the /sys/devices/system/edac directory.
  74. Within this directory there currently reside 2 components:
  75. mc memory controller(s) system
  76. pci PCI control and status system
  77. Memory Controller (mc) Model
  78. ----------------------------
  79. Each 'mc' device controls a set of DIMM memory modules. These modules
  80. are laid out in a Chip-Select Row (csrowX) and Channel table (chX).
  81. There can be multiple csrows and multiple channels.
  82. Memory controllers allow for several csrows, with 8 csrows being a
  83. typical value. Yet, the actual number of csrows depends on the layout of
  84. a given motherboard, memory controller and DIMM characteristics.
  85. Dual channels allows for 128 bit data transfers to/from the CPU from/to
  86. memory. Some newer chipsets allow for more than 2 channels, like Fully
  87. Buffered DIMMs (FB-DIMMs). The following example will assume 2 channels:
  88. Channel 0 Channel 1
  89. ===================================
  90. csrow0 | DIMM_A0 | DIMM_B0 |
  91. csrow1 | DIMM_A0 | DIMM_B0 |
  92. ===================================
  93. ===================================
  94. csrow2 | DIMM_A1 | DIMM_B1 |
  95. csrow3 | DIMM_A1 | DIMM_B1 |
  96. ===================================
  97. In the above example table there are 4 physical slots on the motherboard
  98. for memory DIMMs:
  99. DIMM_A0
  100. DIMM_B0
  101. DIMM_A1
  102. DIMM_B1
  103. Labels for these slots are usually silk-screened on the motherboard.
  104. Slots labeled 'A' are channel 0 in this example. Slots labeled 'B' are
  105. channel 1. Notice that there are two csrows possible on a physical DIMM.
  106. These csrows are allocated their csrow assignment based on the slot into
  107. which the memory DIMM is placed. Thus, when 1 DIMM is placed in each
  108. Channel, the csrows cross both DIMMs.
  109. Memory DIMMs come single or dual "ranked". A rank is a populated csrow.
  110. Thus, 2 single ranked DIMMs, placed in slots DIMM_A0 and DIMM_B0 above
  111. will have 1 csrow, csrow0. csrow1 will be empty. On the other hand,
  112. when 2 dual ranked DIMMs are similarly placed, then both csrow0 and
  113. csrow1 will be populated. The pattern repeats itself for csrow2 and
  114. csrow3.
  115. The representation of the above is reflected in the directory
  116. tree in EDAC's sysfs interface. Starting in directory
  117. /sys/devices/system/edac/mc each memory controller will be represented
  118. by its own 'mcX' directory, where 'X' is the index of the MC.
  119. ..../edac/mc/
  120. |
  121. |->mc0
  122. |->mc1
  123. |->mc2
  124. ....
  125. Under each 'mcX' directory each 'csrowX' is again represented by a
  126. 'csrowX', where 'X' is the csrow index:
  127. .../mc/mc0/
  128. |
  129. |->csrow0
  130. |->csrow2
  131. |->csrow3
  132. ....
  133. Notice that there is no csrow1, which indicates that csrow0 is composed
  134. of a single ranked DIMMs. This should also apply in both Channels, in
  135. order to have dual-channel mode be operational. Since both csrow2 and
  136. csrow3 are populated, this indicates a dual ranked set of DIMMs for
  137. channels 0 and 1.
  138. Within each of the 'mcX' and 'csrowX' directories are several EDAC
  139. control and attribute files.
  140. 'mcX' directories
  141. -----------------
  142. In 'mcX' directories are EDAC control and attribute files for
  143. this 'X' instance of the memory controllers.
  144. For a description of the sysfs API, please see:
  145. Documentation/ABI/testing/sysfs-devices-edac
  146. 'csrowX' directories
  147. --------------------
  148. When CONFIG_EDAC_LEGACY_SYSFS is enabled, sysfs will contain the csrowX
  149. directories. As this API doesn't work properly for Rambus, FB-DIMMs and
  150. modern Intel Memory Controllers, this is being deprecated in favor of
  151. dimmX directories.
  152. In the 'csrowX' directories are EDAC control and attribute files for
  153. this 'X' instance of csrow:
  154. Total Uncorrectable Errors count attribute file:
  155. 'ue_count'
  156. This attribute file displays the total count of uncorrectable
  157. errors that have occurred on this csrow. If panic_on_ue is set
  158. this counter will not have a chance to increment, since EDAC
  159. will panic the system.
  160. Total Correctable Errors count attribute file:
  161. 'ce_count'
  162. This attribute file displays the total count of correctable
  163. errors that have occurred on this csrow. This count is very
  164. important to examine. CEs provide early indications that a
  165. DIMM is beginning to fail. This count field should be
  166. monitored for non-zero values and report such information
  167. to the system administrator.
  168. Total memory managed by this csrow attribute file:
  169. 'size_mb'
  170. This attribute file displays, in count of megabytes, the memory
  171. that this csrow contains.
  172. Memory Type attribute file:
  173. 'mem_type'
  174. This attribute file will display what type of memory is currently
  175. on this csrow. Normally, either buffered or unbuffered memory.
  176. Examples:
  177. Registered-DDR
  178. Unbuffered-DDR
  179. EDAC Mode of operation attribute file:
  180. 'edac_mode'
  181. This attribute file will display what type of Error detection
  182. and correction is being utilized.
  183. Device type attribute file:
  184. 'dev_type'
  185. This attribute file will display what type of DRAM device is
  186. being utilized on this DIMM.
  187. Examples:
  188. x1
  189. x2
  190. x4
  191. x8
  192. Channel 0 CE Count attribute file:
  193. 'ch0_ce_count'
  194. This attribute file will display the count of CEs on this
  195. DIMM located in channel 0.
  196. Channel 0 UE Count attribute file:
  197. 'ch0_ue_count'
  198. This attribute file will display the count of UEs on this
  199. DIMM located in channel 0.
  200. Channel 0 DIMM Label control file:
  201. 'ch0_dimm_label'
  202. This control file allows this DIMM to have a label assigned
  203. to it. With this label in the module, when errors occur
  204. the output can provide the DIMM label in the system log.
  205. This becomes vital for panic events to isolate the
  206. cause of the UE event.
  207. DIMM Labels must be assigned after booting, with information
  208. that correctly identifies the physical slot with its
  209. silk screen label. This information is currently very
  210. motherboard specific and determination of this information
  211. must occur in userland at this time.
  212. Channel 1 CE Count attribute file:
  213. 'ch1_ce_count'
  214. This attribute file will display the count of CEs on this
  215. DIMM located in channel 1.
  216. Channel 1 UE Count attribute file:
  217. 'ch1_ue_count'
  218. This attribute file will display the count of UEs on this
  219. DIMM located in channel 0.
  220. Channel 1 DIMM Label control file:
  221. 'ch1_dimm_label'
  222. This control file allows this DIMM to have a label assigned
  223. to it. With this label in the module, when errors occur
  224. the output can provide the DIMM label in the system log.
  225. This becomes vital for panic events to isolate the
  226. cause of the UE event.
  227. DIMM Labels must be assigned after booting, with information
  228. that correctly identifies the physical slot with its
  229. silk screen label. This information is currently very
  230. motherboard specific and determination of this information
  231. must occur in userland at this time.
  232. SYSTEM LOGGING
  233. --------------
  234. If logging for UEs and CEs is enabled, then system logs will contain
  235. information indicating that errors have been detected:
  236. EDAC MC0: CE page 0x283, offset 0xce0, grain 8, syndrome 0x6ec3, row 0,
  237. channel 1 "DIMM_B1": amd76x_edac
  238. EDAC MC0: CE page 0x1e5, offset 0xfb0, grain 8, syndrome 0xb741, row 0,
  239. channel 1 "DIMM_B1": amd76x_edac
  240. The structure of the message is:
  241. the memory controller (MC0)
  242. Error type (CE)
  243. memory page (0x283)
  244. offset in the page (0xce0)
  245. the byte granularity (grain 8)
  246. or resolution of the error
  247. the error syndrome (0xb741)
  248. memory row (row 0)
  249. memory channel (channel 1)
  250. DIMM label, if set prior (DIMM B1
  251. and then an optional, driver-specific message that may
  252. have additional information.
  253. Both UEs and CEs with no info will lack all but memory controller, error
  254. type, a notice of "no info" and then an optional, driver-specific error
  255. message.
  256. PCI Bus Parity Detection
  257. ------------------------
  258. On Header Type 00 devices, the primary status is looked at for any
  259. parity error regardless of whether parity is enabled on the device or
  260. not. (The spec indicates parity is generated in some cases). On Header
  261. Type 01 bridges, the secondary status register is also looked at to see
  262. if parity occurred on the bus on the other side of the bridge.
  263. SYSFS CONFIGURATION
  264. -------------------
  265. Under /sys/devices/system/edac/pci are control and attribute files as follows:
  266. Enable/Disable PCI Parity checking control file:
  267. 'check_pci_parity'
  268. This control file enables or disables the PCI Bus Parity scanning
  269. operation. Writing a 1 to this file enables the scanning. Writing
  270. a 0 to this file disables the scanning.
  271. Enable:
  272. echo "1" >/sys/devices/system/edac/pci/check_pci_parity
  273. Disable:
  274. echo "0" >/sys/devices/system/edac/pci/check_pci_parity
  275. Parity Count:
  276. 'pci_parity_count'
  277. This attribute file will display the number of parity errors that
  278. have been detected.
  279. MODULE PARAMETERS
  280. -----------------
  281. Panic on UE control file:
  282. 'edac_mc_panic_on_ue'
  283. An uncorrectable error will cause a machine panic. This is usually
  284. desirable. It is a bad idea to continue when an uncorrectable error
  285. occurs - it is indeterminate what was uncorrected and the operating
  286. system context might be so mangled that continuing will lead to further
  287. corruption. If the kernel has MCE configured, then EDAC will never
  288. notice the UE.
  289. LOAD TIME: module/kernel parameter: edac_mc_panic_on_ue=[0|1]
  290. RUN TIME: echo "1" > /sys/module/edac_core/parameters/edac_mc_panic_on_ue
  291. Log UE control file:
  292. 'edac_mc_log_ue'
  293. Generate kernel messages describing uncorrectable errors. These errors
  294. are reported through the system message log system. UE statistics
  295. will be accumulated even when UE logging is disabled.
  296. LOAD TIME: module/kernel parameter: edac_mc_log_ue=[0|1]
  297. RUN TIME: echo "1" > /sys/module/edac_core/parameters/edac_mc_log_ue
  298. Log CE control file:
  299. 'edac_mc_log_ce'
  300. Generate kernel messages describing correctable errors. These
  301. errors are reported through the system message log system.
  302. CE statistics will be accumulated even when CE logging is disabled.
  303. LOAD TIME: module/kernel parameter: edac_mc_log_ce=[0|1]
  304. RUN TIME: echo "1" > /sys/module/edac_core/parameters/edac_mc_log_ce
  305. Polling period control file:
  306. 'edac_mc_poll_msec'
  307. The time period, in milliseconds, for polling for error information.
  308. Too small a value wastes resources. Too large a value might delay
  309. necessary handling of errors and might loose valuable information for
  310. locating the error. 1000 milliseconds (once each second) is the current
  311. default. Systems which require all the bandwidth they can get, may
  312. increase this.
  313. LOAD TIME: module/kernel parameter: edac_mc_poll_msec=[0|1]
  314. RUN TIME: echo "1000" > /sys/module/edac_core/parameters/edac_mc_poll_msec
  315. Panic on PCI PARITY Error:
  316. 'panic_on_pci_parity'
  317. This control file enables or disables panicking when a parity
  318. error has been detected.
  319. module/kernel parameter: edac_panic_on_pci_pe=[0|1]
  320. Enable:
  321. echo "1" > /sys/module/edac_core/parameters/edac_panic_on_pci_pe
  322. Disable:
  323. echo "0" > /sys/module/edac_core/parameters/edac_panic_on_pci_pe
  324. EDAC device type
  325. ----------------
  326. In the header file, edac_core.h, there is a series of edac_device structures
  327. and APIs for the EDAC_DEVICE.
  328. User space access to an edac_device is through the sysfs interface.
  329. At the location /sys/devices/system/edac (sysfs) new edac_device devices will
  330. appear.
  331. There is a three level tree beneath the above 'edac' directory. For example,
  332. the 'test_device_edac' device (found at the bluesmoke.sourceforget.net website)
  333. installs itself as:
  334. /sys/devices/systm/edac/test-instance
  335. in this directory are various controls, a symlink and one or more 'instance'
  336. directories.
  337. The standard default controls are:
  338. log_ce boolean to log CE events
  339. log_ue boolean to log UE events
  340. panic_on_ue boolean to 'panic' the system if an UE is encountered
  341. (default off, can be set true via startup script)
  342. poll_msec time period between POLL cycles for events
  343. The test_device_edac device adds at least one of its own custom control:
  344. test_bits which in the current test driver does nothing but
  345. show how it is installed. A ported driver can
  346. add one or more such controls and/or attributes
  347. for specific uses.
  348. One out-of-tree driver uses controls here to allow
  349. for ERROR INJECTION operations to hardware
  350. injection registers
  351. The symlink points to the 'struct dev' that is registered for this edac_device.
  352. INSTANCES
  353. ---------
  354. One or more instance directories are present. For the 'test_device_edac' case:
  355. test-instance0
  356. In this directory there are two default counter attributes, which are totals of
  357. counter in deeper subdirectories.
  358. ce_count total of CE events of subdirectories
  359. ue_count total of UE events of subdirectories
  360. BLOCKS
  361. ------
  362. At the lowest directory level is the 'block' directory. There can be 0, 1
  363. or more blocks specified in each instance.
  364. test-block0
  365. In this directory the default attributes are:
  366. ce_count which is counter of CE events for this 'block'
  367. of hardware being monitored
  368. ue_count which is counter of UE events for this 'block'
  369. of hardware being monitored
  370. The 'test_device_edac' device adds 4 attributes and 1 control:
  371. test-block-bits-0 for every POLL cycle this counter
  372. is incremented
  373. test-block-bits-1 every 10 cycles, this counter is bumped once,
  374. and test-block-bits-0 is set to 0
  375. test-block-bits-2 every 100 cycles, this counter is bumped once,
  376. and test-block-bits-1 is set to 0
  377. test-block-bits-3 every 1000 cycles, this counter is bumped once,
  378. and test-block-bits-2 is set to 0
  379. reset-counters writing ANY thing to this control will
  380. reset all the above counters.
  381. Use of the 'test_device_edac' driver should enable any others to create their own
  382. unique drivers for their hardware systems.
  383. The 'test_device_edac' sample driver is located at the
  384. bluesmoke.sourceforge.net project site for EDAC.
  385. NEHALEM USAGE OF EDAC APIs
  386. --------------------------
  387. This chapter documents some EXPERIMENTAL mappings for EDAC API to handle
  388. Nehalem EDAC driver. They will likely be changed on future versions
  389. of the driver.
  390. Due to the way Nehalem exports Memory Controller data, some adjustments
  391. were done at i7core_edac driver. This chapter will cover those differences
  392. 1) On Nehalem, there is one Memory Controller per Quick Patch Interconnect
  393. (QPI). At the driver, the term "socket" means one QPI. This is
  394. associated with a physical CPU socket.
  395. Each MC have 3 physical read channels, 3 physical write channels and
  396. 3 logic channels. The driver currently sees it as just 3 channels.
  397. Each channel can have up to 3 DIMMs.
  398. The minimum known unity is DIMMs. There are no information about csrows.
  399. As EDAC API maps the minimum unity is csrows, the driver sequentially
  400. maps channel/dimm into different csrows.
  401. For example, supposing the following layout:
  402. Ch0 phy rd0, wr0 (0x063f4031): 2 ranks, UDIMMs
  403. dimm 0 1024 Mb offset: 0, bank: 8, rank: 1, row: 0x4000, col: 0x400
  404. dimm 1 1024 Mb offset: 4, bank: 8, rank: 1, row: 0x4000, col: 0x400
  405. Ch1 phy rd1, wr1 (0x063f4031): 2 ranks, UDIMMs
  406. dimm 0 1024 Mb offset: 0, bank: 8, rank: 1, row: 0x4000, col: 0x400
  407. Ch2 phy rd3, wr3 (0x063f4031): 2 ranks, UDIMMs
  408. dimm 0 1024 Mb offset: 0, bank: 8, rank: 1, row: 0x4000, col: 0x400
  409. The driver will map it as:
  410. csrow0: channel 0, dimm0
  411. csrow1: channel 0, dimm1
  412. csrow2: channel 1, dimm0
  413. csrow3: channel 2, dimm0
  414. exports one
  415. DIMM per csrow.
  416. Each QPI is exported as a different memory controller.
  417. 2) Nehalem MC has the ability to generate errors. The driver implements this
  418. functionality via some error injection nodes:
  419. For injecting a memory error, there are some sysfs nodes, under
  420. /sys/devices/system/edac/mc/mc?/:
  421. inject_addrmatch/*:
  422. Controls the error injection mask register. It is possible to specify
  423. several characteristics of the address to match an error code:
  424. dimm = the affected dimm. Numbers are relative to a channel;
  425. rank = the memory rank;
  426. channel = the channel that will generate an error;
  427. bank = the affected bank;
  428. page = the page address;
  429. column (or col) = the address column.
  430. each of the above values can be set to "any" to match any valid value.
  431. At driver init, all values are set to any.
  432. For example, to generate an error at rank 1 of dimm 2, for any channel,
  433. any bank, any page, any column:
  434. echo 2 >/sys/devices/system/edac/mc/mc0/inject_addrmatch/dimm
  435. echo 1 >/sys/devices/system/edac/mc/mc0/inject_addrmatch/rank
  436. To return to the default behaviour of matching any, you can do:
  437. echo any >/sys/devices/system/edac/mc/mc0/inject_addrmatch/dimm
  438. echo any >/sys/devices/system/edac/mc/mc0/inject_addrmatch/rank
  439. inject_eccmask:
  440. specifies what bits will have troubles,
  441. inject_section:
  442. specifies what ECC cache section will get the error:
  443. 3 for both
  444. 2 for the highest
  445. 1 for the lowest
  446. inject_type:
  447. specifies the type of error, being a combination of the following bits:
  448. bit 0 - repeat
  449. bit 1 - ecc
  450. bit 2 - parity
  451. inject_enable starts the error generation when something different
  452. than 0 is written.
  453. All inject vars can be read. root permission is needed for write.
  454. Datasheet states that the error will only be generated after a write on an
  455. address that matches inject_addrmatch. It seems, however, that reading will
  456. also produce an error.
  457. For example, the following code will generate an error for any write access
  458. at socket 0, on any DIMM/address on channel 2:
  459. echo 2 >/sys/devices/system/edac/mc/mc0/inject_addrmatch/channel
  460. echo 2 >/sys/devices/system/edac/mc/mc0/inject_type
  461. echo 64 >/sys/devices/system/edac/mc/mc0/inject_eccmask
  462. echo 3 >/sys/devices/system/edac/mc/mc0/inject_section
  463. echo 1 >/sys/devices/system/edac/mc/mc0/inject_enable
  464. dd if=/dev/mem of=/dev/null seek=16k bs=4k count=1 >& /dev/null
  465. For socket 1, it is needed to replace "mc0" by "mc1" at the above
  466. commands.
  467. The generated error message will look like:
  468. EDAC MC0: UE row 0, channel-a= 0 channel-b= 0 labels "-": NON_FATAL (addr = 0x0075b980, socket=0, Dimm=0, Channel=2, syndrome=0x00000040, count=1, Err=8c0000400001009f:4000080482 (read error: read ECC error))
  469. 3) Nehalem specific Corrected Error memory counters
  470. Nehalem have some registers to count memory errors. The driver uses those
  471. registers to report Corrected Errors on devices with Registered Dimms.
  472. However, those counters don't work with Unregistered Dimms. As the chipset
  473. offers some counters that also work with UDIMMS (but with a worse level of
  474. granularity than the default ones), the driver exposes those registers for
  475. UDIMM memories.
  476. They can be read by looking at the contents of all_channel_counts/
  477. $ for i in /sys/devices/system/edac/mc/mc0/all_channel_counts/*; do echo $i; cat $i; done
  478. /sys/devices/system/edac/mc/mc0/all_channel_counts/udimm0
  479. 0
  480. /sys/devices/system/edac/mc/mc0/all_channel_counts/udimm1
  481. 0
  482. /sys/devices/system/edac/mc/mc0/all_channel_counts/udimm2
  483. 0
  484. What happens here is that errors on different csrows, but at the same
  485. dimm number will increment the same counter.
  486. So, in this memory mapping:
  487. csrow0: channel 0, dimm0
  488. csrow1: channel 0, dimm1
  489. csrow2: channel 1, dimm0
  490. csrow3: channel 2, dimm0
  491. The hardware will increment udimm0 for an error at the first dimm at either
  492. csrow0, csrow2 or csrow3;
  493. The hardware will increment udimm1 for an error at the second dimm at either
  494. csrow0, csrow2 or csrow3;
  495. The hardware will increment udimm2 for an error at the third dimm at either
  496. csrow0, csrow2 or csrow3;
  497. 4) Standard error counters
  498. The standard error counters are generated when an mcelog error is received
  499. by the driver. Since, with udimm, this is counted by software, it is
  500. possible that some errors could be lost. With rdimm's, they display the
  501. contents of the registers
  502. AMD64_EDAC REFERENCE DOCUMENTS USED
  503. -----------------------------------
  504. amd64_edac module is based on the following documents
  505. (available from http://support.amd.com/en-us/search/tech-docs):
  506. 1. Title: BIOS and Kernel Developer's Guide for AMD Athlon 64 and AMD
  507. Opteron Processors
  508. AMD publication #: 26094
  509. Revision: 3.26
  510. Link: http://support.amd.com/TechDocs/26094.PDF
  511. 2. Title: BIOS and Kernel Developer's Guide for AMD NPT Family 0Fh
  512. Processors
  513. AMD publication #: 32559
  514. Revision: 3.00
  515. Issue Date: May 2006
  516. Link: http://support.amd.com/TechDocs/32559.pdf
  517. 3. Title: BIOS and Kernel Developer's Guide (BKDG) For AMD Family 10h
  518. Processors
  519. AMD publication #: 31116
  520. Revision: 3.00
  521. Issue Date: September 07, 2007
  522. Link: http://support.amd.com/TechDocs/31116.pdf
  523. 4. Title: BIOS and Kernel Developer's Guide (BKDG) for AMD Family 15h
  524. Models 30h-3Fh Processors
  525. AMD publication #: 49125
  526. Revision: 3.06
  527. Issue Date: 2/12/2015 (latest release)
  528. Link: http://support.amd.com/TechDocs/49125_15h_Models_30h-3Fh_BKDG.pdf
  529. 5. Title: BIOS and Kernel Developer's Guide (BKDG) for AMD Family 15h
  530. Models 60h-6Fh Processors
  531. AMD publication #: 50742
  532. Revision: 3.01
  533. Issue Date: 7/23/2015 (latest release)
  534. Link: http://support.amd.com/TechDocs/50742_15h_Models_60h-6Fh_BKDG.pdf
  535. 6. Title: BIOS and Kernel Developer's Guide (BKDG) for AMD Family 16h
  536. Models 00h-0Fh Processors
  537. AMD publication #: 48751
  538. Revision: 3.03
  539. Issue Date: 2/23/2015 (latest release)
  540. Link: http://support.amd.com/TechDocs/48751_16h_bkdg.pdf
  541. CREDITS:
  542. ========
  543. Written by Doug Thompson <dougthompson@xmission.com>
  544. 7 Dec 2005
  545. 17 Jul 2007 Updated
  546. (c) Mauro Carvalho Chehab
  547. 05 Aug 2009 Nehalem interface
  548. EDAC authors/maintainers:
  549. Doug Thompson, Dave Jiang, Dave Peterson et al,
  550. Mauro Carvalho Chehab
  551. Borislav Petkov
  552. original author: Thayne Harbaugh