All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleksij Rempel <o.rempel@pengutronix.de>
To: Andrew Lunn <andrew@lunn.ch>
Cc: "David S. Miller" <davem@davemloft.net>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Heiner Kallweit <hkallweit1@gmail.com>,
	Jakub Kicinski <kuba@kernel.org>,
	Jonathan Corbet <corbet@lwn.net>,
	Michal Kubecek <mkubecek@suse.cz>,
	David Jander <david@protonic.nl>,
	kernel@pengutronix.de, linux-kernel@vger.kernel.org,
	netdev@vger.kernel.org, Russell King <linux@armlinux.org.uk>,
	mkl@pengutronix.de, Marek Vasut <marex@denx.de>,
	Christian Herber <christian.herber@nxp.com>
Subject: Re: [PATCH net-next v1 1/2] ethtool: provide UAPI for PHY Signal Quality Index (SQI)
Date: Wed, 20 May 2020 06:55:36 +0200	[thread overview]
Message-ID: <20200520045536.vgeg2p5qt6goqek6@pengutronix.de> (raw)
In-Reply-To: <20200519132630.GH610998@lunn.ch>

[-- Attachment #1: Type: text/plain, Size: 1344 bytes --]

On Tue, May 19, 2020 at 03:26:30PM +0200, Andrew Lunn wrote:
> On Tue, May 19, 2020 at 09:51:59AM +0200, Oleksij Rempel wrote:
> > Signal Quality Index is a mandatory value required by "OPEN Alliance
> > SIG" for the 100Base-T1 PHYs [1]. This indicator can be used for cable
> > integrity diagnostic and investigating other noise sources and
> > implement by at least two vendors: NXP[2] and TI[3].
> 
> Hi Oleksij
> 
> With a multi part patch set, please always include a cover note,
> describing what the patchset as a whole does.

ok

> > +int __ethtool_get_sqi(struct net_device *dev)
> > +{
> > +	struct phy_device *phydev = dev->phydev;
> > +
> > +	if (!phydev->drv->get_sqi)
> > +		return -EOPNOTSUPP;
> > +
> > +	return phydev->drv->get_sqi(phydev);
> > +}
> 
> You are not doing any locking here, which you should. Due to modules
> vs built in, it can be a bit tricky getting this right. Take a look at
> how ethtool ioctl.c uses phy_ethtool_get_stats() and that inline
> function itself.

ok.

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2020-05-20  4:55 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-19  7:51 [PATCH net-next v1 1/2] ethtool: provide UAPI for PHY Signal Quality Index (SQI) Oleksij Rempel
2020-05-19  7:52 ` [PATCH net-next v1 2/2] net: phy: tja11xx: add SQI support Oleksij Rempel
2020-05-19  8:55 ` [PATCH net-next v1 1/2] ethtool: provide UAPI for PHY Signal Quality Index (SQI) Michal Kubecek
2020-05-19 10:58   ` Oleksij Rempel
2020-05-19 11:18     ` Michal Kubecek
2020-05-19 13:26 ` Andrew Lunn
2020-05-20  4:55   ` Oleksij Rempel [this message]
2020-05-19 14:03 ` Andrew Lunn
2020-05-20  4:56   ` Oleksij Rempel
2020-05-19 11:21 Christian Herber

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=20200520045536.vgeg2p5qt6goqek6@pengutronix.de \
    --to=o.rempel@pengutronix.de \
    --cc=andrew@lunn.ch \
    --cc=christian.herber@nxp.com \
    --cc=corbet@lwn.net \
    --cc=davem@davemloft.net \
    --cc=david@protonic.nl \
    --cc=f.fainelli@gmail.com \
    --cc=hkallweit1@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=marex@denx.de \
    --cc=mkl@pengutronix.de \
    --cc=mkubecek@suse.cz \
    --cc=netdev@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.