From: Dasaratharaman Chandramouli Date: Sat, 29 Apr 2017 18:41:14 +0000 (-0400) Subject: IB/IPoIB: Remove 'else' when the 'if' has a return. X-Git-Tag: MMI-PSA29.97-13-9~5649^3~48 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=cfd519358f50e55d304eaf6539ebb07bdc3ac813;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git IB/IPoIB: Remove 'else' when the 'if' has a return. This patch fixes a checkpatch issue related to not having to use an 'else' if the 'if' path returns from the function. Reviewed-by: Ira Weiny Reviewed-by: Don Hiatt Reviewed-by: Sean Hefty Signed-off-by: Dasaratharaman Chandramouli Signed-off-by: Doug Ledford --- diff --git a/drivers/infiniband/ulp/ipoib/ipoib_multicast.c b/drivers/infiniband/ulp/ipoib/ipoib_multicast.c index 3385869443ec..21e8514a8847 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib_multicast.c +++ b/drivers/infiniband/ulp/ipoib/ipoib_multicast.c @@ -295,17 +295,16 @@ static int ipoib_mcast_join_finish(struct ipoib_mcast *mcast, -PTR_ERR(ah)); /* use original error */ return PTR_ERR(ah); - } else { - spin_lock_irq(&priv->lock); - mcast->ah = ah; - spin_unlock_irq(&priv->lock); - - ipoib_dbg_mcast(priv, "MGID %pI6 AV %p, LID 0x%04x, SL %d\n", - mcast->mcmember.mgid.raw, - mcast->ah->ah, - be16_to_cpu(mcast->mcmember.mlid), - mcast->mcmember.sl); } + spin_lock_irq(&priv->lock); + mcast->ah = ah; + spin_unlock_irq(&priv->lock); + + ipoib_dbg_mcast(priv, "MGID %pI6 AV %p, LID 0x%04x, SL %d\n", + mcast->mcmember.mgid.raw, + mcast->ah->ah, + be16_to_cpu(mcast->mcmember.mlid), + mcast->mcmember.sl); } /* actually send any queued packets */