From patchwork Sun Mar 18 21:39:21 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Gortmaker X-Patchwork-Id: 147439 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id 51B60B70E1 for ; Mon, 19 Mar 2012 08:46:13 +1100 (EST) Received: from mail.windriver.com (mail.windriver.com [147.11.1.11]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mail.windriver.com", Issuer "Intel External Basic Issuing CA 3A" (not verified)) by ozlabs.org (Postfix) with ESMTPS id DEE33B6FAA for ; Mon, 19 Mar 2012 08:39:45 +1100 (EST) Received: from yow-lpgnfs-02.corp.ad.wrs.com (yow-lpgnfs-02.ottawa.windriver.com [128.224.149.8]) by mail.windriver.com (8.14.3/8.14.3) with ESMTP id q2ILdUu9023271; Sun, 18 Mar 2012 14:39:35 -0700 (PDT) From: Paul Gortmaker To: davem@davemloft.net, eric.dumazet@gmail.com, therbert@google.com Subject: [PATCH net-next 4/4] gianfar: use netif_tx_queue_stopped instead of __netif_subqueue_stopped Date: Sun, 18 Mar 2012 17:39:21 -0400 Message-Id: <1332106761-18293-5-git-send-email-paul.gortmaker@windriver.com> X-Mailer: git-send-email 1.7.9.1 In-Reply-To: <1332106761-18293-1-git-send-email-paul.gortmaker@windriver.com> References: <1332089787-24086-1-git-send-email-paul.gortmaker@windriver.com> <1332106761-18293-1-git-send-email-paul.gortmaker@windriver.com> Cc: netdev@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, Paul Gortmaker X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org The __netif_subqueue_stopped() just does the following: struct netdev_queue *txq = netdev_get_tx_queue(dev, queue_index); return netif_tx_queue_stopped(txq); and since we already have the txq in scope, we can just call that directly in this case. Suggested-by: Eric Dumazet Signed-off-by: Paul Gortmaker --- drivers/net/ethernet/freescale/gianfar.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/net/ethernet/freescale/gianfar.c b/drivers/net/ethernet/freescale/gianfar.c index 6e66cc3..d9428f0 100644 --- a/drivers/net/ethernet/freescale/gianfar.c +++ b/drivers/net/ethernet/freescale/gianfar.c @@ -2565,7 +2565,7 @@ static int gfar_clean_tx_ring(struct gfar_priv_tx_q *tx_queue) } /* If we freed a buffer, we can restart transmission, if necessary */ - if (__netif_subqueue_stopped(dev, tqi) && tx_queue->num_txbdfree) + if (netif_tx_queue_stopped(txq) && tx_queue->num_txbdfree) netif_wake_subqueue(dev, tqi); /* Update dirty indicators */