summaryrefslogtreecommitdiff
path: root/payloads/libpayload/drivers/options.c
diff options
context:
space:
mode:
authorNico Huber <nico.huber@secunet.com>2012-11-09 18:12:21 +0100
committerPatrick Georgi <patrick@georgi-clan.de>2012-11-30 06:05:50 +0100
commit0227dec291ac825aae514b7841bb39a936bcec77 (patch)
treeb61b155909b2ddbdc8ba64df8c3d121512311bfe /payloads/libpayload/drivers/options.c
parent48e21ec430cf83f540bf189b1dfa372938cc9b36 (diff)
libpayload: Fix lookup by label in CMOS layouts
The condition to compare the labels was twisted. Change-Id: I34a665aa87e2ff0480eda0f249bbbea8a8fe68d8 Signed-off-by: Nico Huber <nico.huber@secunet.com> Reviewed-on: http://review.coreboot.org/1941 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'payloads/libpayload/drivers/options.c')
-rw-r--r--payloads/libpayload/drivers/options.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/payloads/libpayload/drivers/options.c b/payloads/libpayload/drivers/options.c
index d15d81be57..d497c0aae6 100644
--- a/payloads/libpayload/drivers/options.c
+++ b/payloads/libpayload/drivers/options.c
@@ -243,7 +243,7 @@ static struct cb_cmos_enums *lookup_cmos_enum_core(struct cb_cmos_option_table *
cmos_enum;
cmos_enum = next_cmos_enum_of_id(cmos_enum, config_id)) {
if (((value == NULL) || (cmos_enum->value == *value)) &&
- ((text == NULL) || (memcmp((const char*)cmos_enum->text, text, len)))) {
+ ((text == NULL) || (memcmp((const char*)cmos_enum->text, text, len) == 0))) {
return cmos_enum;
}
}