From 28ef474a074eddd8eaffba154a811d7ec403caad Mon Sep 17 00:00:00 2001 From: Karthik Kantamneni Date: Thu, 6 May 2021 22:57:01 +0530 Subject: [PATCH] qcacmn: Fix compilation error for modulo operator In some of the targets modulo operator assembly API's are not defined causing compilation error. To avoid this use qdf based API's for modulo operations. Change-Id: Ibc69b69aa38cadff5daa8dee8b65ceaacfe997b7 CRs-Fixed: 2940281 --- dp/wifi3.0/dp_tx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dp/wifi3.0/dp_tx.c b/dp/wifi3.0/dp_tx.c index 6ecbb2a470..f14bf14325 100644 --- a/dp/wifi3.0/dp_tx.c +++ b/dp/wifi3.0/dp_tx.c @@ -1526,7 +1526,7 @@ dp_tx_hw_desc_update_evt(uint8_t *hal_tx_desc_cached, idx = ++soc->tx_hw_desc_history->index; if (idx == DP_TX_HW_DESC_HIST_MAX) soc->tx_hw_desc_history->index = 0; - idx = (idx % DP_TX_HW_DESC_HIST_MAX); + idx = qdf_do_div_rem(idx, DP_TX_HW_DESC_HIST_MAX); evt = &soc->tx_hw_desc_history->entry[idx]; qdf_mem_copy(evt->tcl_desc, hal_tx_desc_cached, HAL_TX_DESC_LEN_BYTES);