]> git.ipfire.org Git - thirdparty/libvirt.git/commit
node_device: Expose link state & speed
authorMichal Privoznik <mprivozn@redhat.com>
Thu, 5 Jun 2014 15:36:31 +0000 (17:36 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Wed, 11 Jun 2014 08:59:39 +0000 (10:59 +0200)
commit0311ef3d65b6462e405f325f5fdde78de0137005
treeb6e1a17e65418eefe21dbe2090cf92749cb7242b
parentb2019ee4700f859a1541b483a63345ab22577b63
node_device: Expose link state & speed

While exposing the info under <interface/> in previous patch works, it
may work only in cases where interface is configured on the host.
However, orchestrating application may want to know the link state and
speed even in that case. That's why we ought to expose this in nodedev
XML too:

virsh # nodedev-dumpxml net_eth0_f0_de_f1_2b_1b_f3
<device>
  <name>net_eth0_f0_de_f1_2b_1b_f3</name>
  <path>/sys/devices/pci0000:00/0000:00:19.0/net/eth0</path>
  <parent>pci_0000_00_19_0</parent>
  <capability type='net'>
    <interface>eth0</interface>
    <address>f0:de:f1:2b:1b:f3</address>
    <link speed='1000' state='up'/>
    <capability type='80203'/>
  </capability>
</device>

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
docs/formatnode.html.in
docs/schemas/nodedev.rng
src/Makefile.am
src/conf/node_device_conf.c
src/conf/node_device_conf.h
src/node_device/node_device_driver.c
src/node_device/node_device_udev.c