examples/ethtool: fix querying non-PCI devices
authorRemy Horton <remy.horton@intel.com>
Wed, 30 Nov 2016 02:47:29 +0000 (10:47 +0800)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Tue, 20 Dec 2016 15:06:41 +0000 (16:06 +0100)
commit6c66be9a769fdfeee3ca1d4c0d444e23402ce073
tree291355be1b041883a5ecfb27bb851c260ff362a9
parent7dbdc5373c04cc83a7259675038e32c01b21b2a8
examples/ethtool: fix querying non-PCI devices

Doing a device information query on a non-PCI device such as
vhost was resulting in the dereferencing of a NULL pointer
(the absent PCI data), causing a segmentation fault.

Fixes: bda68ab9d1e7 ("examples/ethtool: add user-space ethtool sample application")

Signed-off-by: Remy Horton <remy.horton@intel.com>
doc/guides/rel_notes/release_17_02.rst
examples/ethtool/lib/rte_ethtool.c