public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kbuild test robot <fengguang.wu@intel.com>
To: Alan Cox <alan@linux.intel.com>
Cc: kbuild-all@01.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: [PATCH] i2o: fix simple_return.cocci warnings
Date: Thu, 30 Apr 2015 21:03:04 +0800	[thread overview]
Message-ID: <20150430130303.GA57164@athens> (raw)
In-Reply-To: <201504302132.UufsL5Kz%fengguang.wu@intel.com>

drivers/staging/i2o/iop.c:777:1-3: 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: Alan Cox <alan@linux.intel.com>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
---

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

--- a/drivers/staging/i2o/iop.c
+++ b/drivers/staging/i2o/iop.c
@@ -774,11 +774,7 @@ static int i2o_iop_online(struct i2o_con
 
 	/* In READY state */
 	osm_debug("%s: Attempting to enable...\n", c->name);
-	rc = i2o_iop_enable(c);
-	if (rc)
-		return rc;
-
-	return 0;
+	return i2o_iop_enable(c);
 };
 
 /**

      parent reply	other threads:[~2015-04-30 13:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <201504302132.UufsL5Kz%fengguang.wu@intel.com>
2015-04-30 13:03 ` [PATCH] i2o: fix semicolon.cocci warnings kbuild test robot
2015-04-30 14:12   ` Greg Kroah-Hartman
2015-04-30 13:03 ` kbuild test robot [this message]

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=20150430130303.GA57164@athens \
    --to=fengguang.wu@intel.com \
    --cc=alan@linux.intel.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=kbuild-all@01.org \
    --cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox