From 1001d58cca554ec3a4f52fe0e78427aa640b2d18 Mon Sep 17 00:00:00 2001 From: "Padma, Santhosh Kumar" Date: Wed, 11 Oct 2017 17:29:09 +0530 Subject: [PATCH] qcacld-3.0: Remove check against WMI_SVC_MSG_MAX_SIZE Structure roam_offload_synch_ind has element hlp_data which is of size FILS_MAX_HLP_DATA_LEN is greater than WMI_SVC_MSG_MAX_SIZE. Hence, remove check for size of roam_offload_synch_ind against WMI_SVC_MSG_MAX_SIZE to avoid roam failure. Also, modify check for validity of vdev id. Change-Id: I1b9cef08e1d847f27b7057abf7189ef0f867b92f CRs-Fixed: 2124786 --- core/wma/src/wma_scan_roam.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/core/wma/src/wma_scan_roam.c b/core/wma/src/wma_scan_roam.c index 78b16f49d6a8..826f147662e3 100644 --- a/core/wma/src/wma_scan_roam.c +++ b/core/wma/src/wma_scan_roam.c @@ -2430,7 +2430,7 @@ int wma_roam_synch_event_handler(void *handle, uint8_t *event, goto cleanup_label; } - if (synch_event->vdev_id > wma->max_bssid) { + if (synch_event->vdev_id >= wma->max_bssid) { WMA_LOGE("%s: received invalid vdev_id %d", __func__, synch_event->vdev_id); goto cleanup_label; @@ -2475,9 +2475,6 @@ int wma_roam_synch_event_handler(void *handle, uint8_t *event, (sizeof(*synch_event) + sizeof(wmi_channel) + sizeof(wmi_key_material) + sizeof(uint32_t))) goto cleanup_label; - if (sizeof(roam_offload_synch_ind) > - (WMI_SVC_MSG_MAX_SIZE - roam_synch_data_len)) - goto cleanup_label; roam_synch_data_len += sizeof(roam_offload_synch_ind); cds_host_diag_log_work(&wma->roam_ho_wl,