qcacmn: Add API to check if scan entry is from hidden AP

Add API to check if scan entry is for a hidden AP.

Change-Id: I51115eb1601754d3d920029687ab6211b351c48a
CRs-Fixed: 2106447
This commit is contained in:
Om Prakash Tripathi 2017-09-08 13:59:34 +05:30 • committed by snandini
commit 1d1525db36
4 changed files with 29 additions and 4 deletions

View file

@ -33,9 +33,6 @@
#define SCAN_GET_HASH(addr) \
(((const uint8_t *)(addr))[QDF_MAC_ADDR_SIZE - 1] % SCAN_HASH_SIZE)
/* Hidden ssid age time in millisec */
#define HIDDEN_SSID_TIME (1*60*1000)
/**
* struct scan_dbs - scan cache data base definition
* @num_entries: number of scan entries

View file

@ -74,6 +74,7 @@
#define SCAN_MAX_SCAN_TIME 30000
#define SCAN_NUM_PROBES 2
#define SCAN_NETWORK_IDLE_TIMEOUT 0
#define HIDDEN_SSID_TIME (1*60*1000)
#else
#define MAX_SCAN_CACHE_SIZE 1024
#define SCAN_ACTIVE_DWELL_TIME 105
@ -92,6 +93,7 @@
#define SCAN_MAX_SCAN_TIME 50000
#define SCAN_NUM_PROBES 0
#define SCAN_NETWORK_IDLE_TIMEOUT 200
#define HIDDEN_SSID_TIME (0xFFFFFFFF)
#endif
#define SCAN_TIMEOUT_GRACE_PERIOD 10

View file

@ -1327,4 +1327,30 @@ util_get_last_scan_time(struct wlan_objmgr_vdev *vdev);
QDF_STATUS
util_scan_entry_update_mlme_info(struct wlan_objmgr_pdev *pdev,
struct scan_cache_entry *scan_entry);
/**
* util_scan_is_hidden_ssid() - function to check if ssid is hidden
* @ssid: struct ie_ssid object
*
* API, function to check if ssid is hidden
*
* Return: true if ap is hidden, false otherwise
*/
bool
util_scan_is_hidden_ssid(struct ie_ssid *ssid);
/**
* util_scan_entry_is_hidden_ap() - function to check if ap is hidden
* @scan_entry: scan entry
*
* API, function to check if ap is hidden
*
* Return: true if ap is hidden, false otherwise
*/
static inline bool
util_scan_entry_is_hidden_ap(struct scan_cache_entry *scan_entry)
{
return util_scan_is_hidden_ssid(
(struct ie_ssid *)scan_entry->ie_list.ssid);
}
#endif

View file

@ -321,7 +321,7 @@ util_scan_parse_chan_switch_wrapper_ie(struct scan_cache_entry *scan_params,
return QDF_STATUS_SUCCESS;
}
static bool
bool
util_scan_is_hidden_ssid(struct ie_ssid *ssid)
{
uint8_t i;