All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bimmy Pujari <bimmy.pujari@intel.com>
To: intel-wired-lan@osuosl.org
Subject: [Intel-wired-lan] [next PATCH S51-V2 3/8] i40e: remove error_param_int label from i40e_vc_config_promiscuous_mode_msg
Date: Tue, 25 Oct 2016 16:08:48 -0700	[thread overview]
Message-ID: <1477436933-13679-4-git-send-email-bimmy.pujari@intel.com> (raw)
In-Reply-To: <1477436933-13679-1-git-send-email-bimmy.pujari@intel.com>

From: Jacob Keller <jacob.e.keller@intel.com>

This label is unnecessary, as are jumping to a block that checks aq_ret
and then immediately skipping it and returning. So just jump straight to
the error_param and remove this unnecessary label.

Also use goto error_param even in the last check for style consistency.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Change-ID: If487c7d10c4048e37c594e5eca167693aaed45f6
---
 drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c b/drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c
index 53b46553..46908c0 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c
@@ -1536,7 +1536,7 @@ static int i40e_vc_config_promiscuous_mode_msg(struct i40e_vf *vf,
 				vf->vf_id,
 				i40e_stat_str(&pf->hw, aq_ret),
 				i40e_aq_str(&pf->hw, aq_err));
-			goto error_param_int;
+			goto error_param;
 		}
 	}
 
@@ -1581,15 +1581,16 @@ static int i40e_vc_config_promiscuous_mode_msg(struct i40e_vf *vf,
 							     allmulti, NULL,
 							     true);
 		aq_err = pf->hw.aq.asq_last_status;
-		if (aq_ret)
+		if (aq_ret) {
 			dev_err(&pf->pdev->dev,
 				"VF %d failed to set unicast promiscuous mode %8.8x err %s aq_err %s\n",
 				vf->vf_id, info->flags,
 				i40e_stat_str(&pf->hw, aq_ret),
 				i40e_aq_str(&pf->hw, aq_err));
+			goto error_param;
+		}
 	}
 
-error_param_int:
 	if (!aq_ret) {
 		dev_info(&pf->pdev->dev,
 			 "VF %d successfully set unicast promiscuous mode\n",
-- 
2.4.11


  parent reply	other threads:[~2016-10-25 23:08 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-25 23:08 [Intel-wired-lan] [next PATCH S51-V2 0/8] i40e/i40evf updates Bimmy Pujari
2016-10-25 23:08 ` [Intel-wired-lan] [next PATCH S51-V2 1/8] i40e: Be much more verbose about what we can and cannot offload Bimmy Pujari
2016-10-26 21:17   ` Bowers, AndrewX
2016-10-25 23:08 ` [Intel-wired-lan] [next PATCH S51-V2 2/8] i40evf: " Bimmy Pujari
2016-10-27 16:13   ` Bowers, AndrewX
2016-10-25 23:08 ` Bimmy Pujari [this message]
2016-10-26 22:07   ` [Intel-wired-lan] [next PATCH S51-V2 3/8] i40e: remove error_param_int label from i40e_vc_config_promiscuous_mode_msg Bowers, AndrewX
2016-10-25 23:08 ` [Intel-wired-lan] [next PATCH S51-V2 4/8] i40e: remove second check of VLAN_N_VID in i40e_vlan_rx_add_vid Bimmy Pujari
2016-10-26 22:09   ` Bowers, AndrewX
2016-10-25 23:08 ` [Intel-wired-lan] [next PATCH S51-V2 5/8] i40e: avoid duplicate private flags definitions Bimmy Pujari
2016-10-26 22:13   ` Bowers, AndrewX
2016-10-25 23:08 ` [Intel-wired-lan] [next PATCH S51-V2 6/8] i40e: Add Clause22 implementation Bimmy Pujari
2016-10-26 22:21   ` Bowers, AndrewX
2016-10-25 23:08 ` [Intel-wired-lan] [next PATCH S51-V2 7/8] i40e: fix trivial typo in naming of i40e_sync_filters_subtask Bimmy Pujari
2016-10-26 22:23   ` Bowers, AndrewX
2016-10-25 23:08 ` [Intel-wired-lan] [next PATCH S51-V2 8/8] i40e: Add protocols over MCTP to i40e_aq_discover_capabilities Bimmy Pujari
2016-10-26 22:28   ` Bowers, AndrewX

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1477436933-13679-4-git-send-email-bimmy.pujari@intel.com \
    --to=bimmy.pujari@intel.com \
    --cc=intel-wired-lan@osuosl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.