Browse Source

qcacmn: fix crash during monitor link desc ring replenish

Currently number of elements per page info is used from the
soc->link_desc_pages for both wbm idle link ring and monitor
desc ring replenish.

Chipsets uses SOFTUMAC architecture does not have WBM component.
So, there is no memory allocation for wbm idle links and
soc->link_desc_pages will not get initialized which results in
crash during monitor link desc ring replenish.

Fix this issue by using the number of elements per page info
from the soc->link_desc_pages for the wbm idle link ring replenish
and from the monitor_soc->mon_link_desc_pages for the monitor
link desc ring replenish.

Change-Id: Ie75561b8e2dd2c926b971c133e9bb704b5901bf5
CRs-Fixed: 3494948
Venkateswara Naralasetty 2 years ago
parent
commit
2011633890
1 changed files with 0 additions and 2 deletions
  1. 0 2
      dp/wifi3.0/dp_rings_main.c

+ 0 - 2
dp/wifi3.0/dp_rings_main.c

@@ -2312,7 +2312,6 @@ void dp_link_desc_ring_replenish(struct dp_soc *soc, uint32_t mac_id)
 		page_idx = 0;
 		count = 0;
 		offset = 0;
-		pages = &soc->link_desc_pages;
 		while ((desc = hal_srng_src_get_next(soc->hal_soc,
 						     desc_srng)) &&
 			(count < total_link_descs)) {
@@ -2344,7 +2343,6 @@ void dp_link_desc_ring_replenish(struct dp_soc *soc, uint32_t mac_id)
 		scatter_buf_ptr = (uint8_t *)(
 			soc->wbm_idle_scatter_buf_base_vaddr[scatter_buf_num]);
 		rem_entries = num_entries_per_buf;
-		pages = &soc->link_desc_pages;
 		page_idx = 0; count = 0;
 		offset = 0;
 		num_descs_per_page = pages->num_element_per_page;