i40e: make error message more useful
authorMitch Williams <mitch.a.williams@intel.com>
Mon, 26 Oct 2015 23:44:37 +0000 (19:44 -0400)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Wed, 2 Dec 2015 06:53:58 +0000 (22:53 -0800)
If we get an invalid message from a VF, we should tell the user which VF
is being naughty, rather than making them guess.

Change-ID: I9252cef7baea3d8584043ed6ff12619a94e2f99c
Signed-off-by: Mitch Williams <mitch.a.williams@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c

index 9c54ca2bd04dbaa4f75fbecdc10d790d4ffc652d..26f247d5cad31361c3ea1247b57ba902470fceab 100644 (file)
@@ -1094,8 +1094,8 @@ static int i40e_vc_send_msg_to_vf(struct i40e_vf *vf, u32 v_opcode,
        /* single place to detect unsuccessful return values */
        if (v_retval) {
                vf->num_invalid_msgs++;
-               dev_err(&pf->pdev->dev, "Failed opcode %d Error: %d\n",
-                       v_opcode, v_retval);
+               dev_err(&pf->pdev->dev, "VF %d failed opcode %d, error: %d\n",
+                       vf->vf_id, v_opcode, v_retval);
                if (vf->num_invalid_msgs >
                    I40E_DEFAULT_NUM_INVALID_MSGS_ALLOWED) {
                        dev_err(&pf->pdev->dev,