Force master/slave roles at bringup (A master / B slave, IEEE 7.32): the AN role lottery plus per-training DSP convergence moves per-pair SNR up to ~3.6 dB, so sessions are pinned to identical conditions; launch power documented firmware-pinned (1.130), single-training SNR documented as a weak qualification number
This commit is contained in:
@@ -313,6 +313,24 @@ func (b *bcm) forceJumbo() error {
|
||||
return err
|
||||
}
|
||||
|
||||
// Left to AN, master/slave is a per-training lottery and each training's DSP
|
||||
// convergence moves per-pair SNR by up to ~3.6 dB; pinned roles at least keep
|
||||
// every session measured under identical conditions.
|
||||
func (b *bcm) forceRole(master bool) error {
|
||||
defer b.acquire()()
|
||||
v, err := b.mdioRead(7, 32)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
v |= 0x8000
|
||||
if master {
|
||||
v |= 0x4000
|
||||
} else {
|
||||
v &^= 0x4000
|
||||
}
|
||||
return b.mdioWrite(7, 32, v)
|
||||
}
|
||||
|
||||
func (b *bcm) restartAN() error {
|
||||
defer b.acquire()()
|
||||
v, err := b.mdioRead(7, 0)
|
||||
@@ -822,6 +840,15 @@ func moduleChecks(mods []*phyModule, names [2]string) []checkResult {
|
||||
}
|
||||
out = append(out, res)
|
||||
|
||||
res = checkResult{item: names[i] + " role", state: "forced master"}
|
||||
if i > 0 {
|
||||
res.state = "forced slave"
|
||||
}
|
||||
if err := m.bcm.forceRole(i == 0); err != nil {
|
||||
return fail(res.item, err)
|
||||
}
|
||||
out = append(out, res)
|
||||
|
||||
if err := m.bcm.restartAN(); err != nil {
|
||||
return fail(names[i]+" retrain", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user