mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 14:53:58 -04:00
amd-xgbe: Improve KR auto-negotiation and training
Update xgbe-phy-v2.c to make use of the auto-negotiation (AN) phy hooks to improve the ability to successfully complete Clause 73 AN when running at 10gbps. Hardware can sometimes have issues with CDR lock when the AN DME page exchange is being performed. The AN and KR training hooks are used as follows: - The pre AN hook is used to disable CDR tracking in the PHY so that the DME page exchange can be successfully and consistently completed. - The post KR training hook is used to re-enable the CDR tracking so that KR training can successfully complete. - The post AN hook is used to check for an unsuccessful AN which will increase a CDR tracking enablement delay (up to a maximum value). Add two debugfs entries to allow control over use of the CDR tracking workaround. The debugfs entries allow the CDR tracking workaround to be disabled and determine whether to re-enable CDR tracking before or after link training has been initiated. Also, with these changes the receiver reset cycle that is performed during the link status check can be performed less often. Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
4d945663a6
commit
96f4d430c5
@@ -519,6 +519,22 @@ void xgbe_debugfs_init(struct xgbe_prv_data *pdata)
|
||||
"debugfs_create_file failed\n");
|
||||
}
|
||||
|
||||
if (pdata->vdata->an_cdr_workaround) {
|
||||
pfile = debugfs_create_bool("an_cdr_workaround", 0600,
|
||||
pdata->xgbe_debugfs,
|
||||
&pdata->debugfs_an_cdr_workaround);
|
||||
if (!pfile)
|
||||
netdev_err(pdata->netdev,
|
||||
"debugfs_create_bool failed\n");
|
||||
|
||||
pfile = debugfs_create_bool("an_cdr_track_early", 0600,
|
||||
pdata->xgbe_debugfs,
|
||||
&pdata->debugfs_an_cdr_track_early);
|
||||
if (!pfile)
|
||||
netdev_err(pdata->netdev,
|
||||
"debugfs_create_bool failed\n");
|
||||
}
|
||||
|
||||
kfree(buf);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user