From patchwork Wed Aug 31 09:53:00 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ripduman Sohan X-Patchwork-Id: 112494 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 113F2B6F7F for ; Wed, 31 Aug 2011 19:53:18 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754236Ab1HaJxM (ORCPT ); Wed, 31 Aug 2011 05:53:12 -0400 Received: from mta1.cl.cam.ac.uk ([128.232.25.21]:52229 "EHLO mta1.cl.cam.ac.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752489Ab1HaJxK (ORCPT ); Wed, 31 Aug 2011 05:53:10 -0400 Received: from tusker.lce.cl.cam.ac.uk ([128.232.23.62]) by mta1.cl.cam.ac.uk with esmtp (Exim 4.63) (envelope-from ) id 1QyhTn-00030J-Bm; Wed, 31 Aug 2011 10:53:07 +0100 Received: from rss39 by tusker.lce.cl.cam.ac.uk with local (Exim 4.72) (envelope-from ) id 1QyhTk-0007yw-0F; Wed, 31 Aug 2011 10:53:04 +0100 From: Ripduman Sohan To: linux-net-drivers@solarflare.com, shodgson@solarflare.com, bhutchings@solarflare.com Cc: netdev@vger.kernel.org, Ripduman Sohan Subject: [PATCH 2/2] sfc: Report correct tx-usecs-irq value when driver is loaded with separate_tx_channels set Date: Wed, 31 Aug 2011 10:53:00 +0100 Message-Id: <1314784380-30656-1-git-send-email-ripduman.sohan@cl.cam.ac.uk> X-Mailer: git-send-email 1.7.1 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org If the driver is loaded with the separate_tx_channels parameter set it incorrectly reports TX moderation as 0 usecs regardless of the current value. This patch fixes this oversight. --- drivers/net/sfc/ethtool.c | 7 ++----- 1 files changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/net/sfc/ethtool.c b/drivers/net/sfc/ethtool.c index 0a52447..dac0a84 100644 --- a/drivers/net/sfc/ethtool.c +++ b/drivers/net/sfc/ethtool.c @@ -600,11 +600,8 @@ static int efx_ethtool_get_coalesce(struct net_device *net_dev, if (!efx_channel_has_tx_queues(channel)) continue; if (channel->irq_moderation < coalesce->tx_coalesce_usecs_irq) { - if (channel->channel < efx->n_rx_channels) - coalesce->tx_coalesce_usecs_irq = - channel->irq_moderation; - else - coalesce->tx_coalesce_usecs_irq = 0; + coalesce->tx_coalesce_usecs_irq = + channel->irq_moderation; } }