diff options
author | Albert Chaulk <achaulk@chromium.org> | 2013-07-19 12:56:38 -0700 |
---|---|---|
committer | ChromeBot <chrome-bot@google.com> | 2013-07-31 15:40:23 -0700 |
commit | 494646dbadedae88776d6fced396e3ee8af38e54 (patch) | |
tree | e5d2dffbb2610cbdef31e86e0fdd701f4b51cd1d /host/include | |
parent | 32fd6dead10a8255fea27f6e5ce9ba92d8716008 (diff) | |
download | vboot-494646dbadedae88776d6fced396e3ee8af38e54.tar.gz |
Fix some issues with LBA vs byte offsets
In several places the existing code assumes LBA, but was improperly converted
to use byte offsets, so multiply by the sector size to correct it and maintain
the same interface between MTD & GPT.
Also, since we will need to cgpt create on /dev/fts, which isn't a stat()able
device, allow providing the disk size on the commandline.
BRANCH=none
BUG=chromium:221745
TEST=make runtests; cgpt create -s 12345 on MTD image
Change-Id: Icc89a4505aba9a3dfc39b176a372f6e12d106aed
Reviewed-on: https://gerrit.chromium.org/gerrit/62675
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Tested-by: Albert Chaulk <achaulk@chromium.org>
Commit-Queue: Albert Chaulk <achaulk@chromium.org>
Diffstat (limited to 'host/include')
-rw-r--r-- | host/include/cgpt_params.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/host/include/cgpt_params.h b/host/include/cgpt_params.h index 14e380a2..72de99dc 100644 --- a/host/include/cgpt_params.h +++ b/host/include/cgpt_params.h @@ -16,6 +16,7 @@ enum { typedef struct CgptCreateParams { char *drive_name; int zap; + uint64_t size; } CgptCreateParams; typedef struct CgptAddParams { |