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: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>,
	Yevgeny Petrilin <yevgenyp@mellanox.co.il>
Subject: [PATCH] mlx4_en: fix transmit of packages when blue frame is enabled
Date: Fri, 30 Sep 2011 10:23:15 -0300	[thread overview]
Message-ID: <1317388995-411-1-git-send-email-cascardo@linux.vnet.ibm.com> (raw)

With the addition of Blue Frame support in the network driver for mlx4,
the doorbell is not written in the path where blue frame is enabled and
the package follows some characteristics.

The consequence of that is that ICMP ECHO requests, for example, were
not transmitted by the device. A ping flood, for example, would make the
watchdog dispatch, because the ring was full and transmissions have
timed out.

After this fix, I could ping two systems using mlx4_en (both with the
fix).

Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
Cc: Yevgeny Petrilin <yevgenyp@mellanox.co.il>
---
 drivers/net/ethernet/mellanox/mlx4/en_tx.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/mellanox/mlx4/en_tx.c b/drivers/net/ethernet/mellanox/mlx4/en_tx.c
index 6e03de0..270da80 100644
--- a/drivers/net/ethernet/mellanox/mlx4/en_tx.c
+++ b/drivers/net/ethernet/mellanox/mlx4/en_tx.c
@@ -811,10 +811,11 @@ netdev_tx_t mlx4_en_xmit(struct sk_buff *skb, struct net_device *dev)
 		* before setting ownership of this descriptor to HW */
 		wmb();
 		tx_desc->ctrl.owner_opcode = op_own;
-		wmb();
-		writel(ring->doorbell_qpn, ring->bf.uar->map + MLX4_SEND_DOORBELL);
 	}
 
+	wmb();
+	writel(ring->doorbell_qpn, ring->bf.uar->map + MLX4_SEND_DOORBELL);
+
 	/* Poll CQ here */
 	mlx4_en_xmit_poll(priv, tx_ind);
 
-- 
1.7.4.4

             reply	other threads:[~2011-09-30 13:23 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-30 13:23 Thadeu Lima de Souza Cascardo [this message]
2011-10-02  8:58 ` [PATCH] mlx4_en: fix transmit of packages when blue frame is enabled Yevgeny Petrilin
2011-10-03 14:37   ` Thadeu Lima de Souza Cascardo
2011-10-03 14:56     ` Yevgeny Petrilin
2011-10-03 20:53       ` Thadeu Lima de Souza Cascardo
2011-10-04  6:02         ` Benjamin Herrenschmidt
2011-10-04 20:26           ` Thadeu Lima de Souza Cascardo
2011-10-05  8:15             ` Eli Cohen
2011-10-06 13:57               ` Eli Cohen
2011-10-06 14:10                 ` [PATCH] mlx4_en: fix transmit of packages when blue frame isenabled David Laight
2011-10-07 22:29                   ` Thadeu Lima de Souza Cascardo
2011-10-09  7:28                   ` Benjamin Herrenschmidt
2011-10-09  7:25                 ` [PATCH] mlx4_en: fix transmit of packages when blue frame is enabled Benjamin Herrenschmidt
2011-10-09  7:35                   ` Eli Cohen
2011-10-09  8:00                     ` Benjamin Herrenschmidt
2011-10-09  8:07                       ` Eli Cohen
2011-10-09  8:38                         ` Benjamin Herrenschmidt
2011-10-09  9:21                           ` Eli Cohen
2011-10-09  9:52                             ` Benjamin Herrenschmidt
2011-10-09 10:30                               ` Eli Cohen
2011-10-10  7:32                                 ` Benjamin Herrenschmidt
2011-10-10 16:42                                   ` [PATCH] mlx4_en: fix endianness with blue frame support Thadeu Lima de Souza Cascardo
2011-10-10 16:46                                     ` Thadeu Lima de Souza Cascardo
2011-10-10 18:10                                       ` David Miller
2011-10-10  8:20                               ` [PATCH] mlx4_en: fix transmit of packages when blue frame is enabled David Laight
2011-10-10  8:29                                 ` Benjamin Herrenschmidt
2011-10-10  8:40                   ` David Laight
2011-10-10  8:47                     ` Eli Cohen
2011-10-10  9:01                       ` Benjamin Herrenschmidt
2011-10-10  9:16                         ` Eli Cohen
2011-10-10  9:24                           ` Benjamin Herrenschmidt
2011-10-10  9:29                             ` Eli Cohen
2011-10-10 10:18                               ` Benjamin Herrenschmidt
2011-10-10  8:53                     ` Benjamin Herrenschmidt
2011-10-09  7:21               ` Benjamin Herrenschmidt
2011-10-09  7:19             ` Benjamin Herrenschmidt

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=1317388995-411-1-git-send-email-cascardo@linux.vnet.ibm.com \
    --to=cascardo@linux.vnet.ibm.com \
    --cc=netdev@vger.kernel.org \
    --cc=yevgenyp@mellanox.co.il \
    /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).