net/i40evf: fix return value if admin queue command fails
authorJingjing Wu <jingjing.wu@intel.com>
Tue, 10 May 2016 02:51:59 +0000 (10:51 +0800)
committerBruce Richardson <bruce.richardson@intel.com>
Wed, 15 Jun 2016 15:13:54 +0000 (17:13 +0200)
commit90f12e7a4dccdc144f5597a6c5b06ea4d2aa77f8
treecbf9b4262ef6a1df4d62f6e6ead14424ac708bbe
parentb20971b6cca0d01c41ff06e161581754810bfeb7
net/i40evf: fix return value if admin queue command fails

Previously, if an adminq message is sent successfully, but no response is
received, function "i40evf_execute_vf_cmd" will return without error.
The root cause is value "err" is overwritten. This patch fixes this by
ensuring the value of err is set appropriately for each cmd.

Fixes: ae19955e7c86 ("i40evf: support reporting PF reset")

Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
drivers/net/i40e/i40e_ethdev_vf.c