build: Fix build breakage detected by buildbot
PATCH 1/1 build: Fix build breakage detected by buildbot
From: Dunrong Huang <[email protected]>
More details:
http://buildbot.b1-systems.de/qemu/builders/xen_unstable/builds/83/steps/compile/logs/stdio
VLANState has been removed since commit a005d07, so "vlan id" should be fetched using net_hub_id_for_client().
Signed-off-by Dunrong Huang <[email protected]>
--- hw/xen_backend.h | 1 + hw/xen_devconfig.c | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-)
hw/xen_backend.h +1 -0
@@ -4,6 +4,7 @@#include "xen_common.h" #include "sysemu.h" #include "net.h" +#include "net/hub.h" /* ------------------------------------------------------------- */
hw/xen_devconfig.c +6 -4
@@ -123,19 +123,21 @@ int xen_config_dev_nic(NICInfo *nic) {char fe[256 ], be[256 ];char mac[20 ]; +int vlan_id =-1 ; +net_hub_id_for_client (nic->netdev, &vlan_id);snprintf (mac,sizeof (mac),"%02x:%02x:%02x:%02x:%02x:%02x" , nic->macaddr.a[0 ], nic->macaddr.a[1 ], nic->macaddr.a[2 ], nic->macaddr.a[3 ], nic->macaddr.a[4 ], nic->macaddr.a[5 ]); -xen_be_printf (NULL ,1 ,"config nic %d: mac=\"%s\"\n" , nic->vlan->id, mac); -xen_config_dev_dirs ("vif" ,"qnic" , nic->vlan->id, fe, be,sizeof (fe)); +xen_be_printf (NULL ,1 ,"config nic %d: mac=\"%s\"\n" , vlan_id, mac); +xen_config_dev_dirs ("vif" ,"qnic" , vlan_id, fe, be,sizeof (fe));/* frontend */ -xenstore_write_int (fe,"handle" , nic->vlan->id); +xenstore_write_int (fe,"handle" , vlan_id);xenstore_write_str (fe,"mac" , mac);/* backend */ -xenstore_write_int (be,"handle" , nic->vlan->id); +xenstore_write_int (be,"handle" , vlan_id);xenstore_write_str (be,"mac" , mac);/* common stuff */
Signature · 1 line
1.7.8.6
Anthony Liguori
AppliedQuoted 9 lines · [email protected] writes:
From: Dunrong Huang <[email protected]>
More details:
http://buildbot.b1-systems.de/qemu/builders/xen_unstable/builds/83/steps/compile/logs/stdioVLANState has been removed since commit a005d07, so "vlan id" should be fetched using
net_hub_id_for_client().Signed-off-by Dunrong Huang <[email protected]>
Applied. Thanks.
Regards,
Anthony Liguori
Quoted 49 lines
--- hw/xen_backend.h | 1 + hw/xen_devconfig.c | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-)hw/xen_backend.h +1
-0@@ -4,6 +4,7 @@#include "xen_common.h" #include "sysemu.h" #include "net.h" +#include "net/hub.h" /* ------------------------------------------------------------- */ hw/xen_devconfig.c +6
-4@@ -123,19 +123,21 @@ int xen_config_dev_nic(NICInfo *nic) {char fe[256 ], be[256 ];char mac[20 ]; +int vlan_id =-1 ; +net_hub_id_for_client (nic->netdev, &vlan_id);snprintf (mac,sizeof (mac),"%02x:%02x:%02x:%02x:%02x:%02x" , nic->macaddr.a[0 ], nic->macaddr.a[1 ], nic->macaddr.a[2 ], nic->macaddr.a[3 ], nic->macaddr.a[4 ], nic->macaddr.a[5 ]); -xen_be_printf (NULL ,1 ,"config nic %d: mac=\"%s\"\n" , nic->vlan->id, mac); -xen_config_dev_dirs ("vif" ,"qnic" , nic->vlan->id, fe, be,sizeof (fe)); +xen_be_printf (NULL ,1 ,"config nic %d: mac=\"%s\"\n" , vlan_id, mac); +xen_config_dev_dirs ("vif" ,"qnic" , vlan_id, fe, be,sizeof (fe));/* frontend */ -xenstore_write_int (fe,"handle" , nic->vlan->id); +xenstore_write_int (fe,"handle" , vlan_id);xenstore_write_str (fe,"mac" , mac);/* backend */ -xenstore_write_int (be,"handle" , nic->vlan->id); +xenstore_write_int (be,"handle" , vlan_id);xenstore_write_str (be,"mac" , mac);/* common stuff */ Signature · 1 line
1.7.8.6