WindCharger: Sysvar/Uboot shared env bugfix.
Fixes check that should map sysvar -> uboot instead of uboot -> uboot.
Change-Id: I0e5230e5c3c2d0d82d8ce2d261b412ea461e1ac9
diff --git a/common/cmd_sysvar.c b/common/cmd_sysvar.c
index 503437e..49bab01 100644
--- a/common/cmd_sysvar.c
+++ b/common/cmd_sysvar.c
@@ -697,7 +697,7 @@
const char *get_uboot_name(const char *sysvar_name) {
int i;
for (i = 0; i < ARRAY_SIZE(su_mappings); ++i) {
- if (strcmp(sysvar_name, su_mappings[i].uboot_name) == 0) {
+ if (strcmp(sysvar_name, su_mappings[i].sysvar_name) == 0) {
return su_mappings[i].uboot_name;
}
}