summaryrefslogtreecommitdiffstats
path: root/lib/pb-config/pb-config.h
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2014-01-29 13:28:06 +0800
committerJeremy Kerr <jk@ozlabs.org>2014-01-30 21:59:10 +0800
commitc14b12980885edd035322cd3bc87efff444c39b1 (patch)
tree138bac8bfacd9d1a36d04421d91e0eedf4164da2 /lib/pb-config/pb-config.h
parentdea7842fb28ff055b4e0f43a6a1fdaf3c4b5ba89 (diff)
downloadtalos-petitboot-c14b12980885edd035322cd3bc87efff444c39b1.tar.gz
talos-petitboot-c14b12980885edd035322cd3bc87efff444c39b1.zip
pb-config: Move config storage modules to "platform" modules in discover code
There's no need to include the config storage code in lib/ as only the discover server should be using it. This change moves the config-storage code to discover/, with the platform-specific parts moved to a 'struct platform'. Each platform has a probe function, which is called during init. The first probe function to return a platform is used. At present we only have the one platform, but it's now non-intrusive to add others. We keep an array of platform pointers in a separate ("platforms") section, to allow the test module to drop-in its own test "platform". Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'lib/pb-config/pb-config.h')
-rw-r--r--lib/pb-config/pb-config.h19
1 files changed, 3 insertions, 16 deletions
diff --git a/lib/pb-config/pb-config.h b/lib/pb-config/pb-config.h
index e430301..2bcc251 100644
--- a/lib/pb-config/pb-config.h
+++ b/lib/pb-config/pb-config.h
@@ -1,22 +1,9 @@
-#ifndef CONFIGURATION_H
-#define CONFIGURATION_H
-
-#include <stdbool.h>
-#include <stdint.h>
+#ifndef PB_CONFIG_H
+#define PB_CONFIG_H
#include <types/types.h>
-
-int config_init(void *ctx);
-const struct config *config_get(void);
-int config_set(struct config *config);
-void config_set_autoboot(bool autoboot_enabled);
-int config_fini(void);
-
-/* for use by the storage backends */
-void config_set_defaults(struct config *config);
-
struct config *config_copy(void *ctx, const struct config *src);
-#endif /* CONFIGURATION_H */
+#endif /* PB_CONFIG_H */
OpenPOWER on IntegriCloud