- Package:
- memtest86+
- Source:
- memtest86+
- Description:
- thorough real-mode memory tester
- Submitter:
- Algis Rudys
- Date:
- 2024-07-05 18:15:03 UTC
- Severity:
- important
- Tags:
Hello -- The code which generates the badram= statements in memtest86+ is broken; when two addresses are combined, the mask is incorrectly computed. The correct algorithm is: A bit should be set in the new mask if it is set in both component masks and the corresponding bit in the component are equal. Which is to say: newmask = mask1 & mask2 & ((adr1 & adr2) | (~adr1 & ~adr2)); I cannot say for certain that the current code misses bad memory regions, but it is incorrect nonetheless. A patch against the file patn.c fixing this bug is attached. In addition, the patch changes the address computation for combined addresses from using | to using &. This is not strictly necessary, but removes the need for &ing the new address with the new mask (which statement is left in in case someone wants to fix the bug differently). This bug is marked important because, although the package still does what it's supposed to, a large part of the package (including a feature advertised in the package description) is broken. This bug exists in Memtest86 as well, and I've filed it accordingly (it's the same bug with the same patch to fix, so if there's some way of combining the reports, feel free). Thanks, Algis R.
Hi Samuel, Some time ago a user reported this problem. Do you confirm his diagnostic ? Best regards,
This issue is very old, in latest 2 versions in git there is the part changed but different from the patch, I suppose was fixed long time ago. Can you tell me if the issue is still present on latest version instead?
I saw on upstream git history that there was some improvements related to badram output included in 6.10: https://github.com/memtest86plus/memtest86plus/pull/178 if someone will test it please tell me if sectors reported to set in badram works correctly in 6.10 and this bug can be closed
Judging by its title that pull request does not target correctness. The bookworm version of memtest86+ definitely reports wrong BadRAM patterns. Upstream 7.00 reports them correctly. I haven't checked the bookworm- backports version. Not for 6.10.
Il 05/07/2024 15:56, Ferenc Wágner ha scritto: Thanks for report, if 7.00 report correctly so you can use bookworm-backports that have it From a fast look to upstream repository there is another fix related in 7.00: https://github.com/memtest86plus/memtest86plus/commit/df803bf2942747457c7275439c0b4da4e3e287f1 If will be confirmed that is fully solved I'll close this