Skip to contentSkip to conversation

netbase: change allow-hotplug to auto for usb0 on om-gta01/02 as this seems to not work with busybox ifup/down and handle default route via up/down

PATCH New [email protected] 1 participant 1 message Nov 22, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 netbase: change allow-hotplug to auto for usb0 on om-gta01/02 as this seems to not work with busybox ifup/down and handle default route via up/down

From: Klaus Kurzmann <[email protected]>

---
 recipes/netbase/netbase/om-gta01/interfaces |    5 +++--
 recipes/netbase/netbase/om-gta02/interfaces |    7 ++++---
 2 files changed, 7 insertions(+), 5 deletions(-)
recipes/netbase/netbase/om-gta01/interfaces +3 -2
index 56c485e..e595239 100644
@@ -16,14 +16,15 @@ iface eth1 inet dhcp
 
 # Ethernet/RNDIS gadget (g_ether)
 # ... or on host side, usbnet and random hwaddr
-allow-hotplug usb0
+auto usb0
 iface usb0 inet static
 	address 192.168.0.202
 	netmask 255.255.255.0
 	network 192.168.0.0
-	gateway 192.168.0.200
+	up route add default gw 192.168.0.200 metric 8
 	up echo nameserver 208.67.222.222 >> /etc/resolv.conf
 	up echo nameserver 208.67.220.220 >> /etc/resolv.conf
+	down route del default gw 192.168.0.200 metric 8
 
 # Bluetooth networking
 iface bnep0 inet dhcp
recipes/netbase/netbase/om-gta02/interfaces +4 -3
index ceedfc5..08bd3bb 100644
@@ -16,14 +16,15 @@ iface eth1 inet dhcp
 
 # Ethernet/RNDIS gadget (g_ether)
 # ... or on host side, usbnet and random hwaddr
-allow-hotplug usb0
+auto usb0
 iface usb0 inet static
 	address 192.168.0.202
 	netmask 255.255.255.0
 	network 192.168.0.0
-	gateway 192.168.0.200
-	up echo nameserver 208.67.222.222 >> /etc/resolv.conf
+	up route add default gw 192.168.0.200 metric 8
+	up echo nameserver 208.67.222.222 > /etc/resolv.conf
 	up echo nameserver 208.67.220.220 >> /etc/resolv.conf
+	down route del default gw 192.168.0.200 metric 8
 
 # Bluetooth networking
 iface bnep0 inet dhcp
Signature · 1 line
1.6.5.2