summaryrefslogtreecommitdiffstats
path: root/discover/device-handler.h
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2013-03-19 14:00:53 +0800
committerJeremy Kerr <jk@ozlabs.org>2013-04-29 14:43:04 +1000
commit5e7c90eddd7ac2e4a3b05a7a5f6e29166edfa161 (patch)
tree2ad50697e3380c2c14f72522fa719d3d571e7f8b /discover/device-handler.h
parent45e92aa32a80fdbbf5ad3ad64e34b1ac872018ef (diff)
downloadtalos-petitboot-5e7c90eddd7ac2e4a3b05a7a5f6e29166edfa161.tar.gz
talos-petitboot-5e7c90eddd7ac2e4a3b05a7a5f6e29166edfa161.zip
discover: Add configuration methods
We'd like to be able to download petitboot configurations from other sources (not just local files), but we'll need some way to indicate to the parsers that a chunk of config data is from a specific source. This change adds "configuration methods". At present, we have only one: CONF_METHOD_LOCAL_FILE. For any incoming configuration data, we only run parsers that have registered themselves with that configuration method. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'discover/device-handler.h')
-rw-r--r--discover/device-handler.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/discover/device-handler.h b/discover/device-handler.h
index be55f73..ad9f50a 100644
--- a/discover/device-handler.h
+++ b/discover/device-handler.h
@@ -11,6 +11,11 @@ struct boot_command;
struct event;
struct device;
+enum conf_method {
+ CONF_METHOD_LOCAL_FILE, /* discover by looking at local files on this
+ block device */
+};
+
struct discover_device {
struct device *device;
@@ -43,6 +48,7 @@ struct discover_context {
struct event *event;
struct discover_device *device;
struct list boot_options;
+ enum conf_method method;
};
struct device_handler *device_handler_init(struct discover_server *server,
OpenPOWER on IntegriCloud