Commit 0d6ef41
committed
chroe: properly perform checksums on partition table arrays
Some partitioning tools like ones based on libparted (parted and
GParted) don't wipe the entire GPT partition name field before writing
new partition names. Additionally, it is not guaranteed to be properly
zeroed since the UEFI specification does not clearly state that.
Use a dedicated raw buffer holding the entire partition name field
without any conversion for performing checksums and serializations.
Signed-off-by: Xinhui Yang <[email protected]>1 parent 7bd1432 commit 0d6ef41
1 file changed
+28
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
377 | 377 | | |
378 | 378 | | |
379 | 379 | | |
| 380 | + | |
380 | 381 | | |
381 | | - | |
| 382 | + | |
382 | 383 | | |
383 | 384 | | |
384 | 385 | | |
| |||
395 | 396 | | |
396 | 397 | | |
397 | 398 | | |
398 | | - | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
399 | 406 | | |
400 | 407 | | |
401 | 408 | | |
| |||
412 | 419 | | |
413 | 420 | | |
414 | 421 | | |
415 | | - | |
| 422 | + | |
| 423 | + | |
416 | 424 | | |
417 | | - | |
418 | | - | |
419 | | - | |
420 | | - | |
421 | | - | |
422 | | - | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
423 | 435 | | |
424 | | - | |
425 | 436 | | |
426 | | - | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
427 | 441 | | |
428 | 442 | | |
429 | 443 | | |
| |||
441 | 455 | | |
442 | 456 | | |
443 | 457 | | |
444 | | - | |
445 | | - | |
446 | | - | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
447 | 461 | | |
448 | 462 | | |
449 | 463 | | |
| |||
0 commit comments