adiv5: Abort scanning APs after 8 void APs.
This commit is contained in:
parent
6d01c3c55b
commit
1bef51e145
|
@ -489,11 +489,13 @@ void adiv5_dp_init(ADIv5_DP_t *dp)
|
||||||
}
|
}
|
||||||
/* Probe for APs on this DP */
|
/* Probe for APs on this DP */
|
||||||
uint32_t last_base = 0;
|
uint32_t last_base = 0;
|
||||||
for(int i = 0; i < 256; i++) {
|
int void_aps = 0;
|
||||||
|
for(int i = 0; (i < 256) && (void_aps < 8); i++) {
|
||||||
ADIv5_AP_t *ap = NULL;
|
ADIv5_AP_t *ap = NULL;
|
||||||
if (adiv5_ap_setup(i))
|
if (adiv5_ap_setup(i))
|
||||||
ap = adiv5_new_ap(dp, i);
|
ap = adiv5_new_ap(dp, i);
|
||||||
if (ap == NULL) {
|
if (ap == NULL) {
|
||||||
|
void_aps++;
|
||||||
adiv5_ap_cleanup(i);
|
adiv5_ap_cleanup(i);
|
||||||
if (i == 0)
|
if (i == 0)
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue