Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NXP drivers: flash: soc_flash_mcux: CMD_MARGIN_CHECK fails infrequently #83599

Closed
DerekSnell opened this issue Jan 6, 2025 · 5 comments · Fixed by #83472
Closed

NXP drivers: flash: soc_flash_mcux: CMD_MARGIN_CHECK fails infrequently #83599

DerekSnell opened this issue Jan 6, 2025 · 5 comments · Fixed by #83472
Labels
area: Flash bug The issue is a bug, or the PR is fixing a bug platform: NXP Drivers NXP Semiconductors, drivers

Comments

@DerekSnell
Copy link
Contributor

On LPC5500 devices, using CMD_MARGIN_CHECK in the is_area_readable() can return with an error code, even when the flash is readable and operating as expected. The CMD_MARGIN_CHECK should be removed from is_area_readable() in this driver.

From the LPC55S69 datasheet: "As cells age and lose charge, a correctly programmed address will fail this check, while still being able to be read successfully for the remaining duration of the data retention time."

Replicating the issue can be challenging, as the CMD_MARGIN_CHECK returns errors on a small percentage of devices, or after a flash sector has been erased/programmed many times. But these errors have been seen on custom boards with the LPC55S69.

@bravl
Copy link
Contributor

bravl commented Feb 21, 2025

Hi @DerekSnell,

Could you share the part / page of the LPC55S69 datasheet you mention? I'm currently using an LPC55S69 device where I see the issue described here and would love to have a better understanding of why this occurs.

Thanks!

@DerekSnell
Copy link
Contributor Author

Hi @bravl ,
I see this statement was removed from the datasheet. I also see that NXP has defeatured the CMD_MARGIN_CHECK. That command is not intended for the application level, it is an internal test used by NXP. The references to CMD_MARGIN_CHECK will also be removed from the User Manuals.

Best regards

@bravl
Copy link
Contributor

bravl commented Feb 21, 2025

Hi @DerekSnell,

Thanks for your response! Just a small extra question, is there any reason for "concern" that this check fails on relatively new chips? The boards we've seen it on are only a couple of months old and the part of the flash that reports the error has only been written once.

Bram

@DerekSnell
Copy link
Contributor Author

Hi @bravl ,
No concern needed. This command can return false errors on perfectly good flash. That is the reason the command is defeatured from applications, and removed from this driver.

You can sleep easy, my friend :) Best regards

@bravl
Copy link
Contributor

bravl commented Feb 21, 2025

Hi @DerekSnell

Awesome, thank you for the explanation!

Bram

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Flash bug The issue is a bug, or the PR is fixing a bug platform: NXP Drivers NXP Semiconductors, drivers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants