[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YGT60zQuo1XW85wb@lunn.ch>
Date: Thu, 1 Apr 2021 00:42:27 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Grant Grundler <grundler@...omium.org>
Cc: Oliver Neukum <oneukum@...e.com>, Jakub Kicinski <kuba@...nel.org>,
Roland Dreier <roland@...nel.org>,
nic_swsd <nic_swsd@...ltek.com>, netdev <netdev@...r.kernel.org>,
"David S . Miller" <davem@...emloft.net>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCHv4 3/4] net: cdc_ncm: record speed in status method
On Mon, Mar 29, 2021 at 07:16:50PM -0700, Grant Grundler wrote:
> From: Oliver Neukum <oneukum@...e.com>
>
> Until very recently, the usbnet framework only had support functions
> for devices which reported the link speed by explicitly querying the
> PHY over a MDIO interface. However, the cdc_ncm devices send
> notifications when the link state or link speeds change and do not
> expose the PHY (or modem) directly.
>
> Support funtions (e.g. usbnet_get_link_ksettings_internal()) to directly
> query state recorded by the cdc_ncm driver were added in a previous patch.
>
> So instead of cdc_ncm spewing the link speed into the dmesg buffer,
> record the link speed encoded in these notifications and tell the
> usbnet framework to use the new functions to get link speed/state.
> Link speed/state is now available via ethtool.
>
> This is especially useful given all current RTL8156 devices emit
> a connection/speed status notification every 32ms and this would
> fill the dmesg buffer. This implementation replaces the one
> recently submitted in de658a195ee23ca6aaffe197d1d2ea040beea0a2 :
> "net: usb: cdc_ncm: don't spew notifications"
>
> v2: rebased on upstream
> v3: changed variable names
> v4: rewrote commit message
>
> Signed-off-by: Oliver Neukum <oneukum@...e.com>
> Tested-by: Roland Dreier <roland@...nel.org>
> Signed-off-by: Grant Grundler <grundler@...omium.org>
Reviewed-by: Andrew Lunn <andrew@...n.ch>
Andrew
Powered by blists - more mailing lists