diff -NurpP --minimal linux-2.6.8.1-vs1.9.2.20-vnet0.2/net/core/dev_mcast.c linux-2.6.8.1-vs1.9.2.20-vnet0.3/net/core/dev_mcast.c --- linux-2.6.8.1-vs1.9.2.20-vnet0.2/net/core/dev_mcast.c 2004-08-23 01:14:33.000000000 +0200 +++ linux-2.6.8.1-vs1.9.2.20-vnet0.3/net/core/dev_mcast.c 2004-08-23 01:42:59.000000000 +0200 @@ -253,7 +253,7 @@ static int dev_mc_seq_show(struct seq_fi struct nx_info *nxi = current->nx_info; if (!dev_in_nx_info(dev, nxi)) - return; + return 0; spin_lock_bh(&dev->xmit_lock); for (m = dev->mc_list; m; m = m->next) { diff -NurpP --minimal linux-2.6.8.1-vs1.9.2.20-vnet0.2/net/ipv4/devinet.c linux-2.6.8.1-vs1.9.2.20-vnet0.3/net/ipv4/devinet.c --- linux-2.6.8.1-vs1.9.2.20-vnet0.2/net/ipv4/devinet.c 2004-08-22 00:39:08.000000000 +0200 +++ linux-2.6.8.1-vs1.9.2.20-vnet0.3/net/ipv4/devinet.c 2004-08-23 08:36:50.000000000 +0200 @@ -593,6 +593,9 @@ int devinet_ioctl(unsigned int cmd, void *colon = ':'; if ((in_dev = __in_dev_get(dev)) != NULL) { + int fake = (!vx_check(0, VX_ADMIN) && + (dev->priv_flags & IFF_VNET)); + if (tryaddrmatch) { /* Matthias Andree */ /* compare label and address (4.4BSD style) */ @@ -601,7 +604,8 @@ int devinet_ioctl(unsigned int cmd, void This is checked above. */ for (ifap = &in_dev->ifa_list; (ifa = *ifap) != NULL; ifap = &ifa->ifa_next) { - if (!strcmp(ifr.ifr_name, ifa->ifa_label) && + /* FIXME Correct label handling */ + if (!strcmp(ifr.ifr_name, (fake)?"ethX":ifa->ifa_label) && sin_orig.sin_addr.s_addr == ifa->ifa_address) { break; /* found */ @@ -614,7 +618,8 @@ int devinet_ioctl(unsigned int cmd, void if (!ifa) { for (ifap = &in_dev->ifa_list; (ifa = *ifap) != NULL; ifap = &ifa->ifa_next) - if (!strcmp(ifr.ifr_name, ifa->ifa_label)) + /* FIXME Correct label handling */ + if (!strcmp(ifr.ifr_name, (fake)?"ethX":ifa->ifa_label)) break; } } @@ -762,6 +767,8 @@ static int inet_gifconf(struct net_devic struct in_ifaddr *ifa; struct ifreq ifr; int done = 0; + int fake = (!vx_check(0, VX_ADMIN) && + (dev->priv_flags & IFF_VNET)); if (!in_dev || (ifa = in_dev->ifa_list) == NULL) goto out; @@ -777,9 +784,13 @@ static int inet_gifconf(struct net_devic break; memset(&ifr, 0, sizeof(struct ifreq)); if (ifa->ifa_label) - strcpy(ifr.ifr_name, ifa->ifa_label); + /* FIXME + * Label may look like eth0:123 we should take care of that + * and not simply replace it with ethX ... + */ + strcpy(ifr.ifr_name, (fake)?"ethX":ifa->ifa_label); else - strcpy(ifr.ifr_name, dev->name); + strcpy(ifr.ifr_name, (fake)?"ethX":dev->name); (*(struct sockaddr_in *)&ifr.ifr_addr).sin_family = AF_INET; (*(struct sockaddr_in *)&ifr.ifr_addr).sin_addr.s_addr =