mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-25 14:13:01 -04:00
qcacld-3.0: Check for upper bound in P2P NOA event
Check for the upper bounds for number of NOA descriptors
received in the P2P NOA event.
Change-Id: Id7ecf064f2c25f378f76d795902713da8520507f
CRs-Fixed: 2113072
This commit is contained in:
parent
e37a5f8681
commit
74c87c915f
1 changed files with 6 additions and 1 deletions
|
|
@ -1524,7 +1524,12 @@ int wma_p2p_noa_event_handler(void *handle, uint8_t *event,
|
|||
descriptors = WMI_UNIFIED_NOA_ATTR_NUM_DESC_GET(p2p_noa_info);
|
||||
noa_ie.num_descriptors = (uint8_t) descriptors;
|
||||
|
||||
WMA_LOGI("%s: index %u, oppPs %u, ctwindow %u, num_descriptors = %u",
|
||||
if (noa_ie.num_descriptors > WMA_MAX_NOA_DESCRIPTORS) {
|
||||
WMA_LOGD("Sizing down the no of desc %d to max",
|
||||
noa_ie.num_descriptors);
|
||||
noa_ie.num_descriptors = WMA_MAX_NOA_DESCRIPTORS;
|
||||
}
|
||||
WMA_LOGD("%s: index %u, oppPs %u, ctwindow %u, num_desc = %u",
|
||||
__func__, noa_ie.index,
|
||||
noa_ie.oppPS, noa_ie.ctwindow, noa_ie.num_descriptors);
|
||||
for (i = 0; i < noa_ie.num_descriptors; i++) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue