From: Florian Fainelli <f.fainelli@gmail.com>
To: Michael Walle <michael@walle.cc>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: Andrew Lunn <andrew@lunn.ch>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
"David S . Miller" <davem@davemloft.net>,
Oleksij Rempel <o.rempel@pengutronix.de>
Subject: Re: [PATCH net-next v3] net: phy: at803x: add cable diagnostics support
Date: Wed, 13 May 2020 13:45:29 -0700 [thread overview]
Message-ID: <1b8547f7-4cda-e1d9-f2e4-2d6032fd6fb4@gmail.com> (raw)
In-Reply-To: <20200513203807.366-1-michael@walle.cc>
On 5/13/2020 1:38 PM, Michael Walle wrote:
> The AR8031/AR8033 and the AR8035 support cable diagnostics. Adding
> driver support is straightforward, so lets add it.
>
> The PHY just do one pair at a time, so we have to start the test four
> times. The cable_test_get_status() can block and therefore we can just
> busy poll the test completion and continue with the next pair until we
> are done.
> The time delta counter seems to run at 125MHz which just gives us a
> resolution of about 82.4cm per tick.
>
> 100m cable, A/B/C/D open:
> Cable test started for device eth0.
> Cable test completed for device eth0.
> Pair: Pair A, result: Open Circuit
> Pair: Pair A, fault length: 107.94m
> Pair: Pair B, result: Open Circuit
> Pair: Pair B, fault length: 104.64m
> Pair: Pair C, result: Open Circuit
> Pair: Pair C, fault length: 105.47m
> Pair: Pair D, result: Open Circuit
> Pair: Pair D, fault length: 107.94m
>
> 1m cable, A/B connected, C shorted, D open:
> Cable test started for device eth0.
> Cable test completed for device eth0.
> Pair: Pair A, result: OK
> Pair: Pair B, result: OK
> Pair: Pair C, result: Short within Pair
> Pair: Pair C, fault length: 0.82m
> Pair: Pair D, result: Open Circuit
> Pair: Pair D, fault length: 0.82m
>
> Signed-off-by: Michael Walle <michael@walle.cc>
> Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
--
Florian
next prev parent reply other threads:[~2020-05-13 20:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-13 20:38 [PATCH net-next v3] net: phy: at803x: add cable diagnostics support Michael Walle
2020-05-13 20:45 ` Florian Fainelli [this message]
2020-05-13 20:52 ` David Miller
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=1b8547f7-4cda-e1d9-f2e4-2d6032fd6fb4@gmail.com \
--to=f.fainelli@gmail.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=hkallweit1@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=michael@walle.cc \
--cc=netdev@vger.kernel.org \
--cc=o.rempel@pengutronix.de \
/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