netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
To: netdev@vger.kernel.org
Cc: Anton Blanchard <anton@samba.org>,
	Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
Subject: [PATCH 01/15] ehea: Remove NETIF_F_LLTX
Date: Fri, 14 Oct 2011 12:30:58 -0300	[thread overview]
Message-ID: <1318606272-27647-2-git-send-email-cascardo@linux.vnet.ibm.com> (raw)
In-Reply-To: <1318606272-27647-1-git-send-email-cascardo@linux.vnet.ibm.com>

From: Anton Blanchard <anton@samba.org>

Remove the deprecated NETIF_F_LLTX feature. Since the network stack
now provides the locking we can remove the driver specific
pr->xmit_lock.

Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
---
 drivers/net/ethernet/ibm/ehea/ehea.h      |    1 -
 drivers/net/ethernet/ibm/ehea/ehea_main.c |   12 ++----------
 2 files changed, 2 insertions(+), 11 deletions(-)

diff --git a/drivers/net/ethernet/ibm/ehea/ehea.h b/drivers/net/ethernet/ibm/ehea/ehea.h
index 0b8e6a9..5b5c1b5 100644
--- a/drivers/net/ethernet/ibm/ehea/ehea.h
+++ b/drivers/net/ethernet/ibm/ehea/ehea.h
@@ -363,7 +363,6 @@ struct ehea_port_res {
 	struct port_stats p_stats;
 	struct ehea_mr send_mr;       	/* send memory region */
 	struct ehea_mr recv_mr;       	/* receive memory region */
-	spinlock_t xmit_lock;
 	struct ehea_port *port;
 	char int_recv_name[EHEA_IRQ_NAME_SIZE];
 	char int_send_name[EHEA_IRQ_NAME_SIZE];
diff --git a/drivers/net/ethernet/ibm/ehea/ehea_main.c b/drivers/net/ethernet/ibm/ehea/ehea_main.c
index dfefe80..ce9a670 100644
--- a/drivers/net/ethernet/ibm/ehea/ehea_main.c
+++ b/drivers/net/ethernet/ibm/ehea/ehea_main.c
@@ -1534,7 +1534,6 @@ static int ehea_init_port_res(struct ehea_port *port, struct ehea_port_res *pr,
 	pr->rx_packets = rx_packets;
 
 	pr->port = port;
-	spin_lock_init(&pr->xmit_lock);
 	spin_lock_init(&pr->netif_queue);
 
 	pr->eq = ehea_create_eq(adapter, eq_type, EHEA_MAX_ENTRIES_EQ, 0);
@@ -2254,14 +2253,9 @@ static int ehea_start_xmit(struct sk_buff *skb, struct net_device *dev)
 
 	pr = &port->port_res[ehea_hash_skb(skb, port->num_tx_qps)];
 
-	if (!spin_trylock(&pr->xmit_lock))
+	if (pr->queue_stopped)
 		return NETDEV_TX_BUSY;
 
-	if (pr->queue_stopped) {
-		spin_unlock(&pr->xmit_lock);
-		return NETDEV_TX_BUSY;
-	}
-
 	swqe = ehea_get_swqe(pr->qp, &swqe_index);
 	memset(swqe, 0, SWQE_HEADER_SIZE);
 	atomic_dec(&pr->swqe_avail);
@@ -2325,8 +2319,6 @@ static int ehea_start_xmit(struct sk_buff *skb, struct net_device *dev)
 		}
 		spin_unlock_irqrestore(&pr->netif_queue, flags);
 	}
-	dev->trans_start = jiffies; /* NETIF_F_LLTX driver :( */
-	spin_unlock(&pr->xmit_lock);
 
 	return NETDEV_TX_OK;
 }
@@ -3233,7 +3225,7 @@ struct ehea_port *ehea_setup_single_port(struct ehea_adapter *adapter,
 	dev->features = NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_TSO
 		      | NETIF_F_HIGHDMA | NETIF_F_IP_CSUM | NETIF_F_HW_VLAN_TX
 		      | NETIF_F_HW_VLAN_RX | NETIF_F_HW_VLAN_FILTER
-		      | NETIF_F_LLTX | NETIF_F_RXCSUM;
+		      | NETIF_F_RXCSUM;
 	dev->watchdog_timeo = EHEA_WATCH_DOG_TIMEOUT;
 
 	if (use_lro)
-- 
1.7.4.4

  reply	other threads:[~2011-10-14 15:31 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-14 15:30 EHEA updates Thadeu Lima de Souza Cascardo
2011-10-14 15:30 ` Thadeu Lima de Souza Cascardo [this message]
2011-10-14 15:30 ` [PATCH 02/15] ehea: Update multiqueue support Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 03/15] ehea: Remove force_irq logic in napi poll routine Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 04/15] ehea: Remove num_tx_qps module option Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 05/15] ehea: Dont check NETIF_F_TSO in TX path Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 06/15] ehea: Add vlan_features Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 07/15] ehea: Allocate large enough skbs to avoid partial cacheline DMA writes Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 08/15] ehea: Simplify ehea_xmit2 and ehea_xmit3 Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 09/15] ehea: Merge swqe2 TSO and non TSO paths Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 10/15] ehea: Simplify type 3 transmit routine Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 11/15] ehea: Remove some unused definitions Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 12/15] ehea: Add 64bit statistics Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 13/15] ehea: Remove LRO support Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 14/15] ehea: Add GRO support Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 15/15] ehea: Remove unused tcp_end field in send WQ Thadeu Lima de Souza Cascardo
2011-10-17 23:06 ` EHEA updates David Miller
  -- strict thread matches above, loose matches on Subject: below --
2011-05-12  0:52 [PATCH 00/15] ehea updates v2 Anton Blanchard
2011-05-12  0:52 ` [PATCH 01/15] ehea: Remove NETIF_F_LLTX Anton Blanchard

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=1318606272-27647-2-git-send-email-cascardo@linux.vnet.ibm.com \
    --to=cascardo@linux.vnet.ibm.com \
    --cc=anton@samba.org \
    --cc=netdev@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;
as well as URLs for NNTP newsgroup(s).