Always copy the latest BSS information from the firmware's results to
the driver's BSS table to ensure that everything is up-to-date (IEs,
supported rates, encryption status, etc).
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
/* Read the entries one by one */
for (; offset + atom_len <= len; offset += atom_len) {
int found = 0;
/* Read the entries one by one */
for (; offset + atom_len <= len; offset += atom_len) {
int found = 0;
+ bss_element *bss = NULL;
/* Get next atom */
atom = (union hermes_scan_info *) (buf + offset);
/* Get next atom */
atom = (union hermes_scan_info *) (buf + offset);
if (memcmp(bss->bss.a.essid, atom->a.essid,
le16_to_cpu(atom->a.essid_len)))
continue;
if (memcmp(bss->bss.a.essid, atom->a.essid,
le16_to_cpu(atom->a.essid_len)))
continue;
- bss->last_scanned = jiffies;
bss_element, list);
list_del(priv->bss_free_list.next);
bss_element, list);
list_del(priv->bss_free_list.next);
- memcpy(bss, atom, sizeof(bss->bss));
- bss->last_scanned = jiffies;
list_add_tail(&bss->list, &priv->bss_list);
}
list_add_tail(&bss->list, &priv->bss_list);
}
+
+ if (bss) {
+ /* Always update the BSS to get latest beacon info */
+ memcpy(&bss->bss, atom, sizeof(bss->bss));
+ bss->last_scanned = jiffies;
+ }