diff options
author | Jeremy Kerr <jk@ozlabs.org> | 2013-05-13 09:16:00 +0800 |
---|---|---|
committer | Jeremy Kerr <jk@ozlabs.org> | 2013-05-15 14:38:04 +0800 |
commit | 1b50985db4e85030de3567792aedc13aa26e0fea (patch) | |
tree | 48cca47b21140712ca20b5eaff2c4b041fb6ac48 /discover/kboot-parser.c | |
parent | 07bf13167aacf49a694aea3341caa15379916bec (diff) | |
download | talos-petitboot-1b50985db4e85030de3567792aedc13aa26e0fea.tar.gz talos-petitboot-1b50985db4e85030de3567792aedc13aa26e0fea.zip |
discover: Always associate resources with a boot option
We should always be tallocing resources to a boot option context;
anything else (for example, the discover context) may have a different
lifetime.
In order to enforce this, we change the void *ctx argument to the
context_create functions to a struct discover_boot_option.
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'discover/kboot-parser.c')
-rw-r--r-- | discover/kboot-parser.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/discover/kboot-parser.c b/discover/kboot-parser.c index 4064a3e..4b4c2f7 100644 --- a/discover/kboot-parser.c +++ b/discover/kboot-parser.c @@ -84,7 +84,7 @@ static void kboot_process_pair(struct conf_context *conf, const char *name, } out_add: - d_opt->boot_image = create_devpath_resource(opt, + d_opt->boot_image = create_devpath_resource(d_opt, conf->dc->device, value); if (root) { @@ -94,7 +94,7 @@ out_add: opt->boot_args = args; if (initrd) { - d_opt->initrd = create_devpath_resource(opt, + d_opt->initrd = create_devpath_resource(d_opt, conf->dc->device, initrd); opt->description = talloc_asprintf(opt, "%s initrd=%s %s", |