From: Andrew Lunn <andrew@lunn.ch>
To: Justin Lai <justinlai0215@realtek.com>
Cc: kuba@kernel.org, davem@davemloft.net, edumazet@google.com,
pabeni@redhat.com, linux-kernel@vger.kernel.org,
netdev@vger.kernel.org, jiri@resnulli.us
Subject: Re: [PATCH net-next v6 1/2] net/ethernet/realtek: Add Realtek automotive PCIe driver code
Date: Tue, 22 Aug 2023 19:51:29 +0200 [thread overview]
Message-ID: <c9bbd802-27da-4775-8176-fa73e6ec4381@lunn.ch> (raw)
In-Reply-To: <20230822031805.4752-2-justinlai0215@realtek.com>
> +static int rtase_set_pauseparam(struct net_device *dev, struct ethtool_pauseparam *pause)
> +{
> + const struct rtase_private *tp = netdev_priv(dev);
> + u16 value = RTL_R16(tp, CPLUS_CMD);
> +
> + value &= ~(FORCE_TXFLOW_EN | FORCE_RXFLOW_EN);
> +
> + if (pause->tx_pause)
> + value |= FORCE_TXFLOW_EN;
> +
> + if (pause->rx_pause)
> + value |= FORCE_RXFLOW_EN;
> +
> + RTL_W16(tp, CPLUS_CMD, value);
> + return 0;
> +}
I'm pretty sure i said if pause->autoneg is true, you should return
-EOPNOTUSPP.
Andrew
next prev parent reply other threads:[~2023-08-22 17:51 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-22 3:18 [PATCH net-next v6 0/2] Add Realtek automotive PCIe driver Justin Lai
2023-08-22 3:18 ` [PATCH net-next v6 1/2] net/ethernet/realtek: Add Realtek automotive PCIe driver code Justin Lai
2023-08-22 17:37 ` Jakub Kicinski
2023-08-23 14:20 ` Justin Lai
2023-08-22 17:51 ` Andrew Lunn [this message]
2023-08-23 14:25 ` Justin Lai
2023-08-22 17:59 ` Andrew Lunn
2023-08-23 14:28 ` Justin Lai
2023-08-22 3:18 ` [PATCH net-next v6 2/2] MAINTAINERS: Add the rtase ethernet driver entry Justin Lai
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=c9bbd802-27da-4775-8176-fa73e6ec4381@lunn.ch \
--to=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=jiri@resnulli.us \
--cc=justinlai0215@realtek.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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
all inboxes | Powered by JetHome®