diff options
author | Qing He <qing.he@intel.com> | 2011-04-25 14:06:48 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-05-04 00:54:42 +0100 |
commit | a29b96e3828ecf8a4915856d1e6733a97cd4b89f (patch) | |
tree | 119531cc1adc53b34ea119b1e7a1483d3288dcb9 /meta/recipes-core/busybox/busybox-1.18.4/udhcpc-fix-nfsroot.patch | |
parent | b9e63d96addd5fa1d69877e9a58e6ea92482e19b (diff) | |
download | poky-a29b96e3828ecf8a4915856d1e6733a97cd4b89f.tar.gz |
busybox: upgrade to version 1.18.4
from version 1.17.3
- remove make-382-fix since it's upstreamed
(From OE-Core rev: bb92a1852e17232c07658eef013f243ca6780563)
Signed-off-by: Qing He <qing.he@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/busybox/busybox-1.18.4/udhcpc-fix-nfsroot.patch')
-rw-r--r-- | meta/recipes-core/busybox/busybox-1.18.4/udhcpc-fix-nfsroot.patch | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/meta/recipes-core/busybox/busybox-1.18.4/udhcpc-fix-nfsroot.patch b/meta/recipes-core/busybox/busybox-1.18.4/udhcpc-fix-nfsroot.patch new file mode 100644 index 0000000000..89eeb425ad --- /dev/null +++ b/meta/recipes-core/busybox/busybox-1.18.4/udhcpc-fix-nfsroot.patch | |||
@@ -0,0 +1,54 @@ | |||
1 | # copy commit message from OE as the patch comment: | ||
2 | # commit ec4da6df3ad5b8b03446d0dda9c50a2439ae325a | ||
3 | # Author: Denys Dmytriyenko <denis@denix.org> | ||
4 | # Date: Wed Feb 4 11:43:18 2009 -0500 | ||
5 | # | ||
6 | # busybox: fix nfsroot issues with resetting IP and deleting routes | ||
7 | # | ||
8 | # above comment added by Kevin Tian <kevin.tian@intel.com>, 2010-07-06 | ||
9 | Index: busybox-1.15.3/examples/udhcp/simple.script | ||
10 | =================================================================== | ||
11 | --- busybox-1.15.3.orig/examples/udhcp/simple.script 2010-06-27 12:17:14.116876946 +0200 | ||
12 | +++ busybox-1.15.3/examples/udhcp/simple.script 2010-06-27 12:18:38.607868533 +0200 | ||
13 | @@ -10,10 +10,17 @@ | ||
14 | BROADCAST="broadcast +" | ||
15 | [ -n "$broadcast" ] && BROADCAST="broadcast $broadcast" | ||
16 | |||
17 | +# return 0 if root is mounted on a network filesystem | ||
18 | +root_is_nfs() { | ||
19 | + grep -qe '^/dev/root.*\(nfs\|smbfs\|ncp\|coda\) .*' /proc/mounts | ||
20 | +} | ||
21 | + | ||
22 | case "$1" in | ||
23 | deconfig) | ||
24 | + if ! root_is_nfs ; then | ||
25 | echo "Setting IP address 0.0.0.0 on $interface" | ||
26 | - ifconfig $interface 0.0.0.0 | ||
27 | + ifconfig $interface 0.0.0.0 | ||
28 | + fi | ||
29 | ;; | ||
30 | |||
31 | renew|bound) | ||
32 | @@ -21,15 +28,17 @@ | ||
33 | ifconfig $interface $ip $NETMASK $BROADCAST | ||
34 | |||
35 | if [ -n "$router" ] ; then | ||
36 | - echo "Deleting routers" | ||
37 | - while route del default gw 0.0.0.0 dev $interface 2>/dev/null ; do | ||
38 | - : | ||
39 | - done | ||
40 | + if ! root_is_nfs ; then | ||
41 | + echo "Deleting routers" | ||
42 | + while route del default gw 0.0.0.0 dev $interface 2>/dev/null ; do | ||
43 | + : | ||
44 | + done | ||
45 | + fi | ||
46 | |||
47 | metric=0 | ||
48 | for i in $router ; do | ||
49 | echo "Adding router $i" | ||
50 | - route add default gw $i dev $interface metric $((metric++)) | ||
51 | + route add default gw $i dev $interface metric $((metric++)) 2>/dev/null | ||
52 | done | ||
53 | fi | ||
54 | |||