From patchwork Thu May 7 13:29:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Simek X-Patchwork-Id: 6357971 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 3443BBEEE1 for ; Thu, 7 May 2015 13:32:31 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DA5F6203AD for ; Thu, 7 May 2015 13:32:27 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1C9F9203AA for ; Thu, 7 May 2015 13:32:25 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1YqLsZ-0002vY-Tf; Thu, 07 May 2015 13:30:19 +0000 Received: from mail-wg0-f50.google.com ([74.125.82.50]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YqLsT-0001LA-Jv for linux-arm-kernel@lists.infradead.org; Thu, 07 May 2015 13:30:14 +0000 Received: by wgyo15 with SMTP id o15so43618439wgy.2 for ; Thu, 07 May 2015 06:29:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id; bh=wc43FZ5Si60P47ec4mkRtJQo32VjbAvKnGrtBfHq20w=; b=cFjqah/VfMuQ7Bzu7jdnc7vdLHWL2rWci3EMs662nE5+w8nwCfd49Wgkl5YZv3XZTz fSabHORtFub5aBsaLNYq3EwSMfjfRsoZk/di0y6GhBRMdxJi7Mz+h3cwK8hygkHKYHtt DJXDa9cLW5zBLNkL5xyi93lj+5ckzIjrA41RFQZI40D19bBh7GEOJDvIdFKskFvHVLJx 5HTL+zCkdFKbGZCGTQvuF4UBg5MmDOfm06N+cOGZJcAmRBYWjrdd353xfcgUirhoEDP8 NJ2zB+URTdegmQUNwf0AkZCaZ8VoSwgZGj/fvbmm7V/4RaYxFHzSqLjsYX+T2AshI0la L1fQ== X-Gm-Message-State: ALoCoQnavTunzt+OclPbe+YKAGEZnpj/2p6jxr4EGiHUzVeEre+lKSwJmgEz1Z1/PesvBJDsFXbX X-Received: by 10.180.80.197 with SMTP id t5mr6668475wix.63.1431005359583; Thu, 07 May 2015 06:29:19 -0700 (PDT) Received: from localhost (nat-35.starnet.cz. [178.255.168.35]) by mx.google.com with ESMTPSA id fs9sm3453997wjc.34.2015.05.07.06.29.18 (version=TLSv1.1 cipher=RC4-SHA bits=128/128); Thu, 07 May 2015 06:29:18 -0700 (PDT) From: Michal Simek To: netdev@vger.kernel.org Subject: [PATCH] net: ll_temac: Use one return statement instead of two Date: Thu, 7 May 2015 15:29:17 +0200 Message-Id: X-Mailer: git-send-email 2.3.5 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150507_063013_841102_33A817E4 X-CRM114-Status: UNSURE ( 9.37 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.7 (/) Cc: Subbaraya Sundeep Bhatta , Michal Simek , linux-kernel@vger.kernel.org, Markus Elfring , Fabian Frederick , Julia Lawall , =?UTF-8?q?Manuel=20Sch=C3=B6lling?= , "David S. Miller" , =?UTF-8?q?S=C3=B6ren=20Brinkmann?= , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Michal Simek Use one return statement instead of two to simplify the code. Both are returning the same value. Signed-off-by: Michal Simek --- drivers/net/ethernet/xilinx/ll_temac_main.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/net/ethernet/xilinx/ll_temac_main.c b/drivers/net/ethernet/xilinx/ll_temac_main.c index 690a4c36b316..ca640d04fd93 100644 --- a/drivers/net/ethernet/xilinx/ll_temac_main.c +++ b/drivers/net/ethernet/xilinx/ll_temac_main.c @@ -688,10 +688,8 @@ static int temac_start_xmit(struct sk_buff *skb, struct net_device *ndev) cur_p = &lp->tx_bd_v[lp->tx_bd_tail]; if (temac_check_tx_bd_space(lp, num_frag)) { - if (!netif_queue_stopped(ndev)) { + if (!netif_queue_stopped(ndev)) netif_stop_queue(ndev); - return NETDEV_TX_BUSY; - } return NETDEV_TX_BUSY; }