public inbox for initramfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Thomas Renninger <trenn-l3A5Bk7waGM@public.gmane.org>
To: harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org
Cc: initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	trenn-l3A5Bk7waGM@public.gmane.org,
	Hannes Reinecke <hare-l3A5Bk7waGM@public.gmane.org>
Subject: [PATCH 3/4] 40network: always start netroot in ifup.sh
Date: Mon, 23 Mar 2015 17:12:17 +0100	[thread overview]
Message-ID: <1427127138-12932-4-git-send-email-trenn@suse.de> (raw)
In-Reply-To: <1427127138-12932-1-git-send-email-trenn-l3A5Bk7waGM@public.gmane.org>

From: Hannes Reinecke <hare-l3A5Bk7waGM@public.gmane.org>

It's totally irrelevant how the network is configured when
trying to setup netroot. It only matters if it could be
configured at all.
So change the logic the check for correct network setup
and then start netroot.

References: bnc#881235

Signed-off-by: Hannes Reinecke <hare-l3A5Bk7waGM@public.gmane.org>
Signed-off-by: Thomas Renninger <trenn-l3A5Bk7waGM@public.gmane.org>
---
 modules.d/40network/ifup.sh | 22 ++++++++--------------
 1 file changed, 8 insertions(+), 14 deletions(-)

diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
index de518b6..9af5474 100755
--- a/modules.d/40network/ifup.sh
+++ b/modules.d/40network/ifup.sh
@@ -338,21 +338,15 @@ for p in $(getargs ip=); do
         esac
     done
 
-    > /tmp/net.${netif}.up
+    if [ $? -eq 0 ]; then
+        > /tmp/net.${netif}.up
 
-    case $autoconf in
-        dhcp|on|any|dhcp6)
-            ;;
-        *)
-            if [ $? -eq 0 ]; then
-                setup_net $netif
-                source_hook initqueue/online $netif
-                if [ -z "$manualup" ]; then
-                    /sbin/netroot $netif
-                fi
-            fi
-            ;;
-    esac
+        setup_net $netif
+        source_hook initqueue/online $netif
+        if [ -z "$manualup" ]; then
+            /sbin/netroot $netif
+        fi
+    fi
 
     exit 0
 done
-- 
2.1.4

  parent reply	other threads:[~2015-03-23 16:12 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-23 16:12 Some tiny fixes Thomas Renninger
     [not found] ` <1427127138-12932-1-git-send-email-trenn-l3A5Bk7waGM@public.gmane.org>
2015-03-23 16:12   ` [PATCH 1/4] Correct paths for openSUSE Thomas Renninger
     [not found]     ` <1427127138-12932-2-git-send-email-trenn-l3A5Bk7waGM@public.gmane.org>
2015-06-02 10:25       ` Harald Hoyer
2015-03-23 16:12   ` [PATCH 2/4] 40network: Fix race condition when wait for networks Thomas Renninger
     [not found]     ` <1427127138-12932-3-git-send-email-trenn-l3A5Bk7waGM@public.gmane.org>
2015-06-02 10:15       ` Harald Hoyer
     [not found]         ` <556D823E.1090104-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2015-06-02 10:50           ` Pawel Wieczorkiewicz
2015-03-23 16:12   ` Thomas Renninger [this message]
     [not found]     ` <1427127138-12932-4-git-send-email-trenn-l3A5Bk7waGM@public.gmane.org>
2015-06-02 10:24       ` [PATCH 3/4] 40network: always start netroot in ifup.sh Harald Hoyer
2015-03-23 16:12   ` [PATCH 4/4] 95fcoe-uefi: Test for EFI firmware Thomas Renninger
     [not found]     ` <1427127138-12932-5-git-send-email-trenn-l3A5Bk7waGM@public.gmane.org>
2015-03-26 15:38       ` [Dracut GitHub] Patchset imported to github Dracut GitHub Import Bot
2015-06-02 10:25       ` [PATCH 4/4] 95fcoe-uefi: Test for EFI firmware Harald Hoyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1427127138-12932-4-git-send-email-trenn@suse.de \
    --to=trenn-l3a5bk7wagm@public.gmane.org \
    --cc=harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=hare-l3A5Bk7waGM@public.gmane.org \
    --cc=initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox