nimble/ll: Use RPA regardless of address resolution state when scanning
When scanning and local IRK is present we should use RPA regardless
of address resolution state (as this controls peer's address resolution
not local RPA generation).
@@ -353,10 +353,12 @@ ble_ll_scan_req_pdu_prepare(struct ble_ll_scan_sm *scansm, uint8_t *adv_addr,
rl = &g_ble_ll_resolv_list[rpa_index];
}
} else {
- if (ble_ll_resolv_enabled()) {
+ /* we look for RL entry to generate local RPA regardless if
+ * resolving is enabled or not (as this is is for local RPA
+ * not peer RPA)
+ */
rl = ble_ll_resolv_list_find(adv_addr, adv_addr_type);
}
- }
/*
* If advertising device is on our resolving list, we use RPA generated
