summaryrefslogtreecommitdiffstats
path: root/discover/user-event.c
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2014-01-20 08:58:49 +0800
committerJeremy Kerr <jk@ozlabs.org>2014-01-21 13:36:01 +0800
commit6d05fe798a06ba93418a1f8517e8f30cadcfd5e4 (patch)
treedee01306db5a2e16554d437d74b3dadc0eb9282a /discover/user-event.c
parent416647ec10a0ca505de35348620391fde80043c0 (diff)
downloadpetitboot-6d05fe798a06ba93418a1f8517e8f30cadcfd5e4.zip
petitboot-6d05fe798a06ba93418a1f8517e8f30cadcfd5e4.tar.gz
utils/pb-udhcpc: Unify references to DHCP bootfile parameter
udhcpc may pass the bootfile parameter as either $bootfile or $boot_file, depending on whether the option is present in the BOOTP header, or as a DHCP vendor option. We have code in pb-udhcpc to unify this to $bootfile, but we only use the unified value in one of the user events. This change uses the correct value of bootfile, and fixes the check to conditionally generate the explicit add event. We also need to update the user-event code to use the right event parameter name. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'discover/user-event.c')
-rw-r--r--discover/user-event.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/discover/user-event.c b/discover/user-event.c
index 7acd237..dc671d9 100644
--- a/discover/user-event.c
+++ b/discover/user-event.c
@@ -89,9 +89,9 @@ static struct resource *user_event_resource(struct discover_boot_option *opt,
return NULL;
}
- boot_file = event_get_param(event, "boot_file");
+ boot_file = event_get_param(event, "bootfile");
if (!boot_file) {
- pb_log("%s: boot_file not found\n", __func__);
+ pb_log("%s: bootfile not found\n", __func__);
return NULL;
}
OpenPOWER on IntegriCloud