From: amit.salecha@qlogic.com
To: davem@davemloft.net
Cc: netdev@vger.kernel.org, ameen.rahman@qlogic.com,
Rajesh Borundia <rajesh.borundia@qlogic.com>,
Amit Kumar Salecha <amit.salecha@qlogic.com>
Subject: [PATCH NEXT 1/5] qlcnic: fix pause params setting
Date: Tue, 13 Jul 2010 02:46:56 -0700 [thread overview]
Message-ID: <1279014420-8829-2-git-send-email-amit.salecha@qlogic.com> (raw)
In-Reply-To: <1279014420-8829-1-git-send-email-amit.salecha@qlogic.com>
From: Rajesh Borundia <rajesh.borundia@qlogic.com>
Turning off rx pause param and autoneg param is not supported so
return error in that case.
Signed-off-by: Rajesh Borundia <rajesh.borundia@qlogic.com>
Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com>
---
drivers/net/qlcnic/qlcnic_ethtool.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/drivers/net/qlcnic/qlcnic_ethtool.c b/drivers/net/qlcnic/qlcnic_ethtool.c
index baf5a52..8599993 100644
--- a/drivers/net/qlcnic/qlcnic_ethtool.c
+++ b/drivers/net/qlcnic/qlcnic_ethtool.c
@@ -578,8 +578,13 @@ qlcnic_set_pauseparam(struct net_device *netdev,
}
QLCWR32(adapter, QLCNIC_NIU_GB_PAUSE_CTL, val);
} else if (adapter->ahw.port_type == QLCNIC_XGBE) {
+
+ if (!pause->rx_pause || pause->autoneg)
+ return -EOPNOTSUPP;
+
if ((port < 0) || (port > QLCNIC_NIU_MAX_XG_PORTS))
return -EIO;
+
val = QLCRD32(adapter, QLCNIC_NIU_XG_PAUSE_CTL);
if (port == 0) {
if (pause->tx_pause)
--
1.6.0.2
next prev parent reply other threads:[~2010-07-13 9:47 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-13 9:46 [PATCH NEXT 0/5]qlcnic: aer support amit.salecha
2010-07-13 9:46 ` amit.salecha [this message]
2010-07-13 9:46 ` [PATCH NEXT 2/5] qlcnic: disable tx timeout recovery amit.salecha
2010-07-13 9:46 ` [PATCH NEXT 3/5] qlcnic: fix netdev notifier in error path amit.salecha
2010-07-13 9:46 ` [PATCH NEXT 4/5] qlcnic: aer support amit.salecha
2010-07-13 9:47 ` [PATCH NEXT 5/5] qlcnic: restore NPAR config data after recovery amit.salecha
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=1279014420-8829-2-git-send-email-amit.salecha@qlogic.com \
--to=amit.salecha@qlogic.com \
--cc=ameen.rahman@qlogic.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=rajesh.borundia@qlogic.com \
/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).