summaryrefslogtreecommitdiff
path: root/README
diff options
context:
space:
mode:
authorJulius Werner <jwerner@chromium.org>2016-04-19 13:20:52 -0700
committerPhilip Chen <philipchen@chromium.org>2016-11-15 18:32:40 +0000
commit5d3e4d772a7ab61daa8e6b83a4cb7ec8df73a512 (patch)
tree20dc6a74705bf7bb770debbd4bddf04187275574 /README
parent5d652cdffa70dc772e80548a760e1f0d67de273f (diff)
downloadvboot-5d3e4d772a7ab61daa8e6b83a4cb7ec8df73a512.tar.gz
cgpt: Fully write out primary GPT before starting to write secondary
The point of having two GPTs is to always have a known good one if one of them gets corrupted. One of the most obvious ways that could happen is if the write stopped half-way through (e.g. due to a crash or random power loss). Unfortunately, the way we currently save modified GPTs can leave both copies invalid if we stop writing at just the wrong time. Since a GPT header contains a checksum over the GPT entries, we need to write both the header and entries for one GPT (and make sure they're synced to disk) before we start writing the other. BRANCH=None BUG=chrome-os-partner:52595 TEST=None Change-Id: I2d4b56bcfba9a94395af5896f274ebade9e39081 Signed-off-by: Julius Werner <jwerner@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/340071 Reviewed-by: Nam Nguyen <namnguyen@google.com> (cherry picked from commit 5de0000ece70bf419130db9bdbaf444ffc98bf30) Reviewed-on: https://chromium-review.googlesource.com/411475 Reviewed-by: Philip Chen <philipchen@chromium.org> Commit-Queue: Philip Chen <philipchen@chromium.org> Tested-by: Philip Chen <philipchen@chromium.org>
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions