mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 21:59:12 -04:00
qcacld-3.0: Do not cache connection info for non sta interface
Currently driver does not check the mode of the current interface whether it is STA of CLI and it caches the connection info, in this process it allocates the memory to cache he operation, this memory get freed only for station type adapter because of which there is a possibility of memleak for CLI interface. To avoid above issue, add a change to only cache the information STA interface. Change-Id: Ic68d71dfd9887600fe1a287de66d735c2c802491 CRs-Fixed: 3028583
This commit is contained in:
parent
5dd57b125a
commit
d1f305eccf
1 changed files with 13 additions and 6 deletions
|
|
@ -1139,14 +1139,21 @@ static void hdd_save_bss_info(struct hdd_adapter *adapter,
|
|||
hdd_sta_ctx->conn_info.conn_flag.vht_op_present = false;
|
||||
}
|
||||
|
||||
/* Cleanup already existing he info */
|
||||
hdd_cleanup_conn_info(adapter);
|
||||
/*
|
||||
* Cache connection info only in case of station
|
||||
*/
|
||||
|
||||
/* Cache last connection info */
|
||||
qdf_mem_copy(&hdd_sta_ctx->cache_conn_info, &hdd_sta_ctx->conn_info,
|
||||
sizeof(hdd_sta_ctx->cache_conn_info));
|
||||
if (adapter->device_mode == QDF_STA_MODE) {
|
||||
/* Cleanup already existing he info */
|
||||
hdd_cleanup_conn_info(adapter);
|
||||
|
||||
hdd_copy_he_operation(hdd_sta_ctx, roam_info);
|
||||
/* Cache last connection info */
|
||||
qdf_mem_copy(&hdd_sta_ctx->cache_conn_info,
|
||||
&hdd_sta_ctx->conn_info,
|
||||
sizeof(hdd_sta_ctx->cache_conn_info));
|
||||
|
||||
hdd_copy_he_operation(hdd_sta_ctx, roam_info);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue