wlan: CSR should only indicate lostlink once

The WLAN driver was failing a particular test case.  A Device Under
Test (DUT) is connected to an Access Point (AP) using one form of
security (i.e. WEP).  While still connected, the security mode on The
AP is changed (i.e. changed to WPA2).

The expected result is that the DUT will disconnect from the AP, and
the AP with its new security settings will be present in the DUT's
scan window.  This behavior was not observed.  Instead sometimes the
DUT would indicate it was still connected to the AP using the original
security mode (even though in reality a connection wasn't
established).

The root cause of the problem is that the CSR module is sending two
disconnect notifications to the HDD.  When HDD receives the first
notification it in turn notifies wpa_supplicant that a disconnect has
occurred, and wpa_supplicant attempts to reconnect.  Simultaneously
HDD receives the second disconnect.  During processing of the second
disconnect the roam profile is put in an inconsistent state.  Modify
the logic in CSR so that it only sends a single disconnect
notification to HDD, thereby preventing the race condition.

Change-Id: I4f947c6d6464615b1f8b747206ef44b35d69c000
CRs-fixed: 450265
1 file changed
tree: a21f7cd07df8d1acd0a970534ebd1cebb0eddf3b
  1. CORE/
  2. firmware_bin/
  3. riva/
  4. Android.mk
  5. Kbuild
  6. Kconfig