DPDK patches and discussions
 help / color / mirror / Atom feed
From: John Daley <johndale@cisco.com>
To: dev@dpdk.org
Cc: John Daley <johndale@cisco.com>
Subject: [dpdk-dev] [PATCH] enic: state change from link-down to link-up not recognized
Date: Fri, 25 Mar 2016 17:45:17 -0700	[thread overview]
Message-ID: <1458953117-13817-1-git-send-email-johndale@cisco.com> (raw)

When the enic was disabled, link notification was correctly disabled
in the NIC but the software indicator that it was disabled was not
updated (vdev->notify_pa not set to 0). When the link came back up,
enic did not re-enable notification in the NIC.

This affected bonding when a enic slave device link bounced.

The fix is to unconditionally enable notification when the enic is
enabled.

Fixes: 9913fbb91df0 ("enic/base: common code")

Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
---
 drivers/net/enic/base/vnic_dev.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/net/enic/base/vnic_dev.c b/drivers/net/enic/base/vnic_dev.c
index 6153864..e8a5028 100644
--- a/drivers/net/enic/base/vnic_dev.c
+++ b/drivers/net/enic/base/vnic_dev.c
@@ -768,11 +768,9 @@ int vnic_dev_notify_set(struct vnic_dev *vdev, u16 intr)
 	static u32 instance;
 
 	if (vdev->notify || vdev->notify_pa) {
-		pr_warn("notify block %p still allocated.\n" \
-			"Ignore if restarting port\n", vdev->notify);
-		return -EINVAL;
+		return vnic_dev_notify_setcmd(vdev, vdev->notify,
+					      vdev->notify_pa, intr);
 	}
-
 	if (!vnic_dev_in_reset(vdev)) {
 		snprintf((char *)name, sizeof(name),
 			"vnic_notify-%d", instance++);
-- 
2.7.0

             reply	other threads:[~2016-03-26  0:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-26  0:45 John Daley [this message]
2016-03-30 17:35 ` Thomas Monjalon

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=1458953117-13817-1-git-send-email-johndale@cisco.com \
    --to=johndale@cisco.com \
    --cc=dev@dpdk.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).