Bluetooth: Mesh: Disable randomization in DFD model for canceling update
Disable randomization in the access layer when cancelling update in the distribution server model. This is needed because the server sends 2 messages in a row and the gets reordered by the access layer randomization feature making DFU/SR/FD/BV-43-C test to fail. This fixes DFU/SR/FD/BV-43-C test. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
This commit is contained in:
parent
f0fc4c30da
commit
44f86b81a3
1 changed files with 8 additions and 0 deletions
|
@ -1148,6 +1148,14 @@ enum bt_mesh_dfd_status bt_mesh_dfd_srv_cancel(struct bt_mesh_dfd_srv *srv,
|
||||||
return BT_MESH_DFD_ERR_INTERNAL;
|
return BT_MESH_DFD_ERR_INTERNAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (prev_phase == BT_MESH_DFD_PHASE_APPLYING_UPDATE && ctx) {
|
||||||
|
/* Disable randomization for the Firmware Distribution State message to avoid
|
||||||
|
* reordering when Firmware Distribution Server sends 2 messages in a row when
|
||||||
|
* cancelling the update (see section 6.2.3.10 of MshDFUv1.0).
|
||||||
|
*/
|
||||||
|
ctx->rnd_delay = false;
|
||||||
|
}
|
||||||
|
|
||||||
if (ctx != NULL) {
|
if (ctx != NULL) {
|
||||||
status_rsp(srv, ctx, BT_MESH_DFD_SUCCESS);
|
status_rsp(srv, ctx, BT_MESH_DFD_SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue