[PATCH rhel6-branch] Implement dhcptimeout boot option (#769145)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The support in NM will go to rhel 6.3.

Resolves: rhbz#769145
---
 loader/loader.c |    2 +-
 loader/net.c    |    6 +++++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/loader/loader.c b/loader/loader.c
index 70a45df..0e6be44 100644
--- a/loader/loader.c
+++ b/loader/loader.c
@@ -2073,7 +2073,7 @@ int main(int argc, char ** argv) {
     loaderData.method = -1;
     loaderData.fw_loader_pid = -1;
     loaderData.fw_search_pathz_len = -1;
-    loaderData.dhcpTimeout = -1;
+    loaderData.dhcpTimeout = 0;
 
     extraArgs[0] = NULL;
     parseCmdLineFlags(&loaderData, cmdLine);
diff --git a/loader/net.c b/loader/net.c
index 3cba60b..db86d88 100644
--- a/loader/net.c
+++ b/loader/net.c
@@ -1316,6 +1316,10 @@ int writeEnabledNetInfo(iface_t *iface) {
     fprintf(fp, "send vendor-class-identifier \"%s\";\n",
             iface->vendorclass);
 
+    if (iface->dhcptimeout) {
+        fprintf(fp, "timeout %d", iface->dhcptimeout);
+    }
+
     if (fclose(fp) == EOF) {
         free(ofile);
         return 19;
@@ -1581,7 +1585,7 @@ void setKickstartNetwork(struct loaderData_s * loaderData, int argc,
     iface_t iface;
     gchar *bootProto = NULL, *device = NULL, *class = NULL, *ethtool = NULL;
     gchar *essid = NULL, *wepkey = NULL, *onboot = NULL, *gateway = NULL;
-    gint mtu = 1500, dhcpTimeout = -1;
+    gint mtu = 1500, dhcpTimeout = 0;
     gboolean noipv4 = FALSE, noipv6 = FALSE, noDns = FALSE, noksdev = FALSE, activate = FALSE, nodefroute=FALSE, firstnetdev=FALSE;
     GOptionContext *optCon = g_option_context_new(NULL);
     GError *optErr = NULL;
-- 
1.7.4

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux