summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/pb-config/pb-config.c8
-rw-r--r--lib/pb-config/pb-config.h1
2 files changed, 7 insertions, 2 deletions
diff --git a/lib/pb-config/pb-config.c b/lib/pb-config/pb-config.c
index 315d990..53ed6d6 100644
--- a/lib/pb-config/pb-config.c
+++ b/lib/pb-config/pb-config.c
@@ -13,6 +13,7 @@ static struct config_storage *storage;
static void config_set_defaults(struct config *config)
{
config->autoboot_enabled = true;
+ config->autoboot_timeout_sec = 10;
config->network.interfaces = NULL;
config->network.n_interfaces = 0;
}
@@ -23,8 +24,11 @@ static void dump_config(struct config *config)
pb_log("configuration:\n");
- pb_log(" autoboot: %s\n",
- config->autoboot_enabled ? "enabled" : "disabled");
+ if (config->autoboot_enabled)
+ pb_log(" autoboot: enabled, %d sec\n",
+ config->autoboot_timeout_sec);
+ else
+ pb_log(" autoboot: disabled\n");
if (config->network.n_interfaces || config->network.n_dns_servers)
pb_log(" network configuration:\n");
diff --git a/lib/pb-config/pb-config.h b/lib/pb-config/pb-config.h
index 6a64ef1..c74fa1b 100644
--- a/lib/pb-config/pb-config.h
+++ b/lib/pb-config/pb-config.h
@@ -32,6 +32,7 @@ struct network_config {
struct config {
bool autoboot_enabled;
+ int autoboot_timeout_sec;
struct network_config network;
};
OpenPOWER on IntegriCloud