MFC: r282908

netfront: wait for backend to connect before sending ARP

Sponsored by: Citrix Systems R&D
This commit is contained in:
Roger Pau Monné 2015-05-21 10:28:33 +00:00
parent 0e545d0456
commit edc9f99bb6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/stable/10/; revision=283218

View File

@ -683,7 +683,6 @@ netfront_backend_changed(device_t dev, XenbusState newstate)
switch (newstate) {
case XenbusStateInitialising:
case XenbusStateInitialised:
case XenbusStateConnected:
case XenbusStateUnknown:
case XenbusStateClosed:
case XenbusStateReconfigured:
@ -695,13 +694,15 @@ netfront_backend_changed(device_t dev, XenbusState newstate)
if (network_connect(sc) != 0)
break;
xenbus_set_state(dev, XenbusStateConnected);
#ifdef INET
netfront_send_fake_arp(dev, sc);
#endif
break;
case XenbusStateClosing:
xenbus_set_state(dev, XenbusStateClosed);
break;
case XenbusStateConnected:
#ifdef INET
netfront_send_fake_arp(dev, sc);
#endif
break;
}
}