summaryrefslogtreecommitdiffstats
path: root/lib/pb-config
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2013-12-23 16:42:21 +0800
committerJeremy Kerr <jk@ozlabs.org>2013-12-23 17:06:55 +0800
commitfafa0c268844aa3921f9df0ef72a1cb7c860793f (patch)
tree9235f81650d4370a40530165490fe604212ae24b /lib/pb-config
parentb49d86901dcdf0a6ddddba7c90d67b62c4acf2f8 (diff)
downloadtalos-petitboot-fafa0c268844aa3921f9df0ef72a1cb7c860793f.tar.gz
talos-petitboot-fafa0c268844aa3921f9df0ef72a1cb7c860793f.zip
config/powerpc: Always call update_network_config
Currently, we have a bug when setting the default network configuration (ie, no devices have any specific config), as we won't call update_network_config to clear out the value of the petitboot,network parameter. This change always invokes update_network_config, regardless of the number of interfaces configured. This ensures we clear out the petitboot,network param, which is then synced to nvram if the param has changed. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'lib/pb-config')
-rw-r--r--lib/pb-config/storage-powerpc-nvram.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/pb-config/storage-powerpc-nvram.c b/lib/pb-config/storage-powerpc-nvram.c
index 92305f9..42de598 100644
--- a/lib/pb-config/storage-powerpc-nvram.c
+++ b/lib/pb-config/storage-powerpc-nvram.c
@@ -481,8 +481,7 @@ static int update_config(struct powerpc_nvram_storage *nv,
talloc_free(val);
}
- if (config->network.n_interfaces)
- update_network_config(nv, config);
+ update_network_config(nv, config);
return write_nvram(nv);
}
OpenPOWER on IntegriCloud