lkml.org 
[lkml]   [2022]   [Jun]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH net-next v3 2/3] net: phy: dp83td510: add cable testing support
> +	} else {
> + /* Most probably we have active link partner */
> + stat = ETHTOOL_A_CABLE_RESULT_CODE_UNSPEC;
> + }

So drivers will make a few attempts to get a valid result. Have you
tried that?

> +
> + *finished = true;
> +
> + ethnl_cable_test_result(phydev, ETHTOOL_A_CABLE_PAIR_A, stat);
> +
> + /* Reset state machine, otherwise at least other TDR attempts may
> + * provide not reliable results.
> + */
> + return phy_set_bits(phydev, MII_BMCR, BMCR_RESET);

I thought i made the comment that you should use the helper? The
helper will wait around for the bit to clear indicating the PHY is
ready for further configuration.

Andrew

\
 
 \ /
  Last update: 2022-06-11 17:13    [W:0.128 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site