All of lore.kernel.org
 help / color / mirror / Atom feed
From: kbuild test robot <fengguang.wu@intel.com>
To: intel-wired-lan@osuosl.org
Subject: [Intel-wired-lan] [PATCH] ixgbe: fix simple_return.cocci warnings
Date: Wed, 29 Jul 2015 15:11:25 +0800	[thread overview]
Message-ID: <20150729071125.GA23999@lkp-nex05> (raw)
In-Reply-To: <201507291522.YuNdtPvl%fengguang.wu@intel.com>

drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c:153:1-7: WARNING: end returns can be simpified

 Simplify a trivial if-return sequence.  Possibly combine with a
 preceding function call.
Generated by: scripts/coccinelle/misc/simple_return.cocci

CC: Mark Rustad <mark.d.rustad@intel.com>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
---

 ixgbe_x550.c |    6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c
@@ -150,12 +150,8 @@ static s32 ixgbe_get_cs4227_status(struc
 	if (status)
 		return status;
 
-	status = ixgbe_check_cs4227_reg(hw, IXGBE_CS4227_HOST_SPARE24_LSB +
+	return ixgbe_check_cs4227_reg(hw, IXGBE_CS4227_HOST_SPARE24_LSB +
 					(1 << 12));
-	if (status)
-		return status;
-
-	return 0;
 }
 
 /**

  reply	other threads:[~2015-07-29  7:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-29  7:11 [Intel-wired-lan] [jkirsher-next-queue:dev-queue 127/128] drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c:153:1-7: WARNING: end returns can be simpified kbuild test robot
2015-07-29  7:11 ` kbuild test robot [this message]
2015-07-29 20:55   ` [Intel-wired-lan] [PATCH] ixgbe: fix simple_return.cocci warnings Rustad, Mark D

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=20150729071125.GA23999@lkp-nex05 \
    --to=fengguang.wu@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.