Don't overwrite boot sector unless OTA changes it by earlephilhower · Pull Request #7547 · esp8266/Arduino · GitHub
Skip to content

Don't overwrite boot sector unless OTA changes it#7547

Merged
devyte merged 2 commits into
esp8266:masterfrom
earlephilhower:noboom
Sep 2, 2020
Merged

Don't overwrite boot sector unless OTA changes it#7547
devyte merged 2 commits into
esp8266:masterfrom
earlephilhower:noboom

Conversation

@earlephilhower

Copy link
Copy Markdown
Collaborator

There is a window where the eboot sector is erased and
unwritten/partially written. If there's a power cycle at this time, the
chip will brick due to eboot being corrupted.

Avoid this by checking if the new eboot 4K sector is identical to the
one already in flash, and if so don't rewrite it.

There is a window where the eboot sector is erased and
unwritten/partially written.  If there's a power cycle at this time, the
chip will brick due to eboot being corrupted.

Avoid this by checking if the new eboot 4K sector is identical to the
one already in flash, and if so don't rewrite it.
@davisonja

Copy link
Copy Markdown

@devyte

devyte commented Sep 1, 2020

Copy link
Copy Markdown
Collaborator

Yes, we're merging for v3 these days. We'll get there.

@davisonja

davisonja commented Sep 1, 2020 via email

Copy link
Copy Markdown

@devyte devyte added this to the 3.0.0 milestone Sep 2, 2020
@earlephilhower

Copy link
Copy Markdown
Collaborator Author

@davisonja, sorry, I actually thought #6538 was abandoned. If you want to integrate this boot-block check there, I'm happy to axe this PR. It should be orthogonal to your changes, though.

Can you spend a few mins to make #6538 mergeable? It also has some issues w/the branch pulling in old versions of multiple libraries, so it's in kind of a weird state beyond just the code merge issues.

@devyte

devyte commented Sep 2, 2020

Copy link
Copy Markdown
Collaborator

@devyte devyte merged commit d02bc02 into esp8266:master Sep 2, 2020
@earlephilhower earlephilhower deleted the noboom branch September 2, 2020 23:15
Jason2866 added a commit to Jason2866/Arduino that referenced this pull request Sep 17, 2020
Jason2866 added a commit to Jason2866/Arduino that referenced this pull request Sep 17, 2020
Jason2866 added a commit to Jason2866/Tasmota that referenced this pull request Sep 17, 2020
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

Successfully merging this pull request may close these issues.

3 participants