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

norflash erase last address calculation error #179

Open
CosmicRoach opened this issue Apr 24, 2024 · 1 comment
Open

norflash erase last address calculation error #179

CosmicRoach opened this issue Apr 24, 2024 · 1 comment
Assignees

Comments

@CosmicRoach
Copy link

last_address = (address + size) & (~(dev->sector_sz - 1));

Use the size to calculate the last address needs to subtract 1:
last_address = (address + size -1) & (~(dev->sector_sz - 1));

@abrodkin
Copy link
Member

@CosmicRoach could you please submit a pull-request with the proposed fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants