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

Bug found in HAL_NAND_Read_Page_8b and HAL_NAND_Read_SpareArea_8b #6

Closed
huoxingdawang opened this issue Sep 7, 2023 · 1 comment · Fixed by #7
Closed

Bug found in HAL_NAND_Read_Page_8b and HAL_NAND_Read_SpareArea_8b #6

huoxingdawang opened this issue Sep 7, 2023 · 1 comment · Fixed by #7
Assignees
Labels
bug Something isn't working duplicate This issue or pull request already exists hal HAL-LL driver-related issue or pull-request.
Milestone

Comments

@huoxingdawang
Copy link
Contributor

huoxingdawang commented Sep 7, 2023

The code for reading data from the NAND Flash in the stm32f7xx_hal_nand.c is *buff = *(uint8_t *)deviceaddress; rather than *(__IO uint8_t *)deviceaddress; which may cause the data always to be the first data read from the nand flash when code is optimized by the compiler.

https://github.com/STMicroelectronics/stm32f7xx_hal_driver/blob/a89b85ba16ab07f42165ca67949c0366a9ea1c3a/Src/stm32f7xx_hal_nand.c#L638

https://github.com/STMicroelectronics/stm32f7xx_hal_driver/blob/a89b85ba16ab07f42165ca67949c0366a9ea1c3a/Src/stm32f7xx_hal_nand.c#L1288

And the bug is still exists in this version:
image

@huoxingdawang
Copy link
Contributor Author

I created PR #7 to fix this bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working duplicate This issue or pull request already exists hal HAL-LL driver-related issue or pull-request.
Projects
3 participants