aboutsummaryrefslogtreecommitdiffstats
path: root/extras/mini-os/lib
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2009-04-23 12:19:14 +0100
committerKeir Fraser <keir.fraser@citrix.com>2009-04-23 12:19:14 +0100
commit82ed447498424443f9ea1585bfa5dcfb95f1ab3a (patch)
tree9238b5b3bd79627b33dee56498658836db225e89 /extras/mini-os/lib
parent5bacab31726fb8e4dbedeba2eb737541b13b0aab (diff)
downloadxen-82ed447498424443f9ea1585bfa5dcfb95f1ab3a.tar.gz
xen-82ed447498424443f9ea1585bfa5dcfb95f1ab3a.tar.bz2
xen-82ed447498424443f9ea1585bfa5dcfb95f1ab3a.zip
stubdom: drop lwip support
Network support is still provided the same way: using the tap interface, created in qemu using netfront. The lwip stack is still available to avoid additional compilation issues. However the stubdom is not going to have its own vif anymore, this means that the only vnc server supported is the one in dom0. You can still enable the vnc server in a stubdom at compile time, if you want so. Probably the most important change caused by this patch to xen users is that you don't have to specify two vif in the stubdom config file anymore, but just one: -vif = [ '', 'ip=10.0.1.1,mac=aa:00:00:12:23:34'] +vif = ['ip=10.0.1.1,mac=aa:00:00:12:23:34'] Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Diffstat (limited to 'extras/mini-os/lib')
-rw-r--r--extras/mini-os/lib/sys.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/extras/mini-os/lib/sys.c b/extras/mini-os/lib/sys.c
index 7c5f05cd41..12395bf730 100644
--- a/extras/mini-os/lib/sys.c
+++ b/extras/mini-os/lib/sys.c
@@ -677,7 +677,7 @@ static int select_poll(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exce
{
int i, n = 0;
#ifdef HAVE_LWIP
- int sock_n, sock_nfds = 0;
+ int sock_n = 0, sock_nfds = 0;
fd_set sock_readfds, sock_writefds, sock_exceptfds;
struct timeval timeout = { .tv_sec = 0, .tv_usec = 0};
#endif
@@ -711,12 +711,14 @@ static int select_poll(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exce
}
}
}
- DEBUG("lwip_select(");
- dump_set(nfds, &sock_readfds, &sock_writefds, &sock_exceptfds, &timeout);
- DEBUG("); -> ");
- sock_n = lwip_select(sock_nfds, &sock_readfds, &sock_writefds, &sock_exceptfds, &timeout);
- dump_set(nfds, &sock_readfds, &sock_writefds, &sock_exceptfds, &timeout);
- DEBUG("\n");
+ if (sock_nfds > 0) {
+ DEBUG("lwip_select(");
+ dump_set(nfds, &sock_readfds, &sock_writefds, &sock_exceptfds, &timeout);
+ DEBUG("); -> ");
+ sock_n = lwip_select(sock_nfds, &sock_readfds, &sock_writefds, &sock_exceptfds, &timeout);
+ dump_set(nfds, &sock_readfds, &sock_writefds, &sock_exceptfds, &timeout);
+ DEBUG("\n");
+ }
#endif
/* Then see others as well. */