Commit 724ce5a3 authored by Jean-Claude BAU's avatar Jean-Claude BAU

Fix issue selecting ErBest

Issue detected by IOL test in ICALEPS2019
The selection of the ErBest was not taking account all the time of the
qualification.
parent 04f722fe
......@@ -1201,19 +1201,21 @@ static void bmc_update_erbest_inst(struct pp_instance *ppi) {
) < 0)
best = j;
}
pp_diag(ppi, bmc, 1, "Best foreign master is "
"at index %i/%i\n", best,
ppi->frgn_rec_num);
frgn_master_pid = &frgn_master[best].sourcePortIdentity;
pp_diag(ppi, bmc, 3, fmt_clock_identity_id,
"SourcePortId",
frgn_master_pid->clockIdentity.id[0], frgn_master_pid->clockIdentity.id[1],
frgn_master_pid->clockIdentity.id[2], frgn_master_pid->clockIdentity.id[3],
frgn_master_pid->clockIdentity.id[4], frgn_master_pid->clockIdentity.id[5],
frgn_master_pid->clockIdentity.id[6], frgn_master_pid->clockIdentity.id[7],
frgn_master_pid->portNumber);
if ( is_qualified(ppi,&frgn_master[best]) ) {
pp_diag(ppi, bmc, 1, "Best foreign master is "
"at index %i/%i\n", best,
ppi->frgn_rec_num);
frgn_master_pid = &frgn_master[best].sourcePortIdentity;
pp_diag(ppi, bmc, 3, fmt_clock_identity_id,
"SourcePortId",
frgn_master_pid->clockIdentity.id[0], frgn_master_pid->clockIdentity.id[1],
frgn_master_pid->clockIdentity.id[2], frgn_master_pid->clockIdentity.id[3],
frgn_master_pid->clockIdentity.id[4], frgn_master_pid->clockIdentity.id[5],
frgn_master_pid->clockIdentity.id[6], frgn_master_pid->clockIdentity.id[7],
frgn_master_pid->portNumber);
} else
best=-1;
}
ppi->frgn_rec_best = best;
} else { //if ((ppi->state != ...
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment