summaryrefslogtreecommitdiff
path: root/cgpt/cgpt_show.c
diff options
context:
space:
mode:
authorBill Richardson <wfrichar@chromium.org>2013-03-20 15:02:34 -0700
committerChromeBot <chrome-bot@google.com>2013-03-20 23:47:50 -0700
commit3f806a2abf07d7b801852a4a6f3a9080a4b5c427 (patch)
tree936deb68cac1010957023c1e7cc8f2988feddd25 /cgpt/cgpt_show.c
parent95bae09c7e54a604d89f16b4a8e8b946642af8e7 (diff)
downloadvboot-3f806a2abf07d7b801852a4a6f3a9080a4b5c427.tar.gz
Apply consistent naming scheme for hostlib functions.
The chromeos-installer uses several functions from the vboot_reference userspace library, but the names of those functions are inconsistent: IsZero MapFile VbGetSystemPropertyString cgpt_add cgpt_boot cgpt_create cgpt_get_boot_partition_number cgpt_get_num_non_empty_partitions cgpt_get_partition_details cgpt_prioritize cgpt_set_attributes find_kernel_config The Google C++ style guide says types and functions should use CamelCase, while variables use lower_case_with_underscores. Kernel style (which vboot_reference tries to be more-or-less compatible with) uses lower_case_with_underscores for everything, but that really only has to apply to firmware stuff. For userspace, we can use the Google style. BUG=chromium:221544 BRANCH=none TEST=buildbot CQ-DEPEND=CL:46045 Renaming/cleanup only; no functional changes. Change-Id: I9c82c9ff8909be88586194c8ffdb435fc771195f Signed-off-by: Bill Richardson <wfrichar@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/46044
Diffstat (limited to 'cgpt/cgpt_show.c')
-rw-r--r--cgpt/cgpt_show.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/cgpt/cgpt_show.c b/cgpt/cgpt_show.c
index 45837d97..6c2160ca 100644
--- a/cgpt/cgpt_show.c
+++ b/cgpt/cgpt_show.c
@@ -158,14 +158,14 @@ void EntriesDetails(GptData *gpt, const int secondary, int raw) {
GptEntry *entry;
entry = GetEntry(gpt, secondary, i);
- if (IsZero(&entry->type))
+ if (GuidIsZero(&entry->type))
continue;
EntryDetails(entry, i, raw);
}
}
-int cgpt_get_num_non_empty_partitions(CgptShowParams *params) {
+int CgptGetNumNonEmptyPartitions(CgptShowParams *params) {
struct drive drive;
int gpt_retval;
int retval;
@@ -188,7 +188,7 @@ int cgpt_get_num_non_empty_partitions(CgptShowParams *params) {
int i;
for(i = 0; i < numEntries; i++) {
GptEntry *entry = GetEntry(&drive.gpt, ANY_VALID, i);
- if (IsZero(&entry->type))
+ if (GuidIsZero(&entry->type))
continue;
params->num_partitions++;
@@ -201,7 +201,7 @@ done:
return retval;
}
-int cgpt_show(CgptShowParams *params) {
+int CgptShow(CgptShowParams *params) {
struct drive drive;
int gpt_retval;
@@ -275,7 +275,7 @@ int cgpt_show(CgptShowParams *params) {
for (i = 0; i < GetNumberOfEntries(&drive.gpt); ++i) {
entry = GetEntry(&drive.gpt, ANY_VALID, i);
- if (IsZero(&entry->type))
+ if (GuidIsZero(&entry->type))
continue;
if (!params->numeric && CGPT_OK == ResolveType(&entry->type, type)) {