qcacmn: Add support to acquire wake lock during user scan
Acquire wakelock to handle the case where APP's send scan to connect. If suspend is received during scan, scan will be aborted and APP will not get scan result and will not connect. eg if PNO is implemented in framework. Fix is to avoid the system suspend by taking the wake-lock during scan. Added INI wake_lock_in_user_scan to control this. The INI is disabled by default. Change-Id: I62fdbbcbc6f049cb4e36e774d5a417600a2dfa86 CRs-Fixed: 2381622
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017-2018 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2017-2019 The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for
|
||||
* any purpose with or without fee is hereby granted, provided that the
|
||||
@@ -45,6 +45,8 @@
|
||||
#define QCOM_VENDOR_IE_AGE_TYPE 0x100
|
||||
#define QCOM_VENDOR_IE_AGE_LEN (sizeof(qcom_ie_age) - 2)
|
||||
#define SCAN_DONE_EVENT_BUF_SIZE 4096
|
||||
#define SCAN_WAKE_LOCK_CONNECT_DURATION (1 * 1000) /* in msec */
|
||||
#define SCAN_WAKE_LOCK_SCAN_DURATION (5 * 1000) /* in msec */
|
||||
|
||||
/**
|
||||
* typedef struct qcom_ie_age - age ie
|
||||
@@ -79,12 +81,14 @@ typedef struct {
|
||||
* scan_req_q_lock: Protect scan request queue
|
||||
* req_id: Scan request Id
|
||||
* runtime_pm_lock: Runtime suspend lock
|
||||
* scan_wake_lock: Scan wake lock
|
||||
*/
|
||||
struct osif_scan_pdev{
|
||||
qdf_list_t scan_req_q;
|
||||
qdf_mutex_t scan_req_q_lock;
|
||||
wlan_scan_requester req_id;
|
||||
qdf_runtime_lock_t runtime_pm_lock;
|
||||
qdf_wake_lock_t scan_wake_lock;
|
||||
};
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user