qcacld-3.0: IPA uC: Return EPERM for RM CONS REQ only during unloading

qcacld-2.0 to qcacld-3.0 propagation

Change to return -EINPROGRESS if WLAN unable to grant IPA CONS resource
due to IPA resource loading is in progress.
Return -EPERM only if WLAN unable to grant IPA CONS resource due to
IPA resource unloading is in progress.

Change-Id: Iea4d804d3f81b086e723230fb8eddc7d9561d7d1
CRs-Fixed: 926880
This commit is contained in:
Yun Park 2015-10-22 13:59:32 -07:00 • committed by Prakash Dhavali
commit 4d8b60a777

View file

@ -2100,14 +2100,23 @@ static int hdd_ipa_rm_cons_release(void)
*/
static int hdd_ipa_rm_cons_request(void)
{
if ((ghdd_ipa->resource_loading) || (ghdd_ipa->resource_unloading)) {
int ret = 0;
if (ghdd_ipa->resource_loading) {
HDD_IPA_LOG(CDF_TRACE_LEVEL_FATAL,
"%s: ipa resource loading/unloading in progress",
"%s: IPA resource loading in progress",
__func__);
ghdd_ipa->pending_cons_req = true;
return -EPERM;
ret = -EINPROGRESS;
} else if (ghdd_ipa->resource_unloading) {
HDD_IPA_LOG(CDF_TRACE_LEVEL_FATAL,
"%s: IPA resource unloading in progress",
__func__);
ghdd_ipa->pending_cons_req = true;
ret = -EPERM;
}
return 0;
return ret;
}
/**