diff options
author | qctecmdr <qctecmdr@localhost> | 2023-04-04 23:32:47 -0700 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2023-04-04 23:32:47 -0700 |
commit | 3e952918169b89a3e7a64d6814c3757105278ccc (patch) | |
tree | e0b81c2739f4cc195d095f33836f27215d5a7df2 | |
parent | 612dc30f9ca32e97cd2ddd34d1756627768fd4c3 (diff) | |
parent | ca3b9c8325b8e2cf082770e5ae92cb06901e859e (diff) | |
download | dataipa-3e952918169b89a3e7a64d6814c3757105278ccc.tar.gz |
Merge "msm: ipa3: fix pointer arithmetic to avoid out-of-bound"
-rw-r--r-- | drivers/platform/msm/ipa/ipa_v3/ipa_utils.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c b/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c index cf95db4..90a06da 100644 --- a/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c +++ b/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c @@ -10293,7 +10293,7 @@ void ipa3_counter_remove_hdl(int hdl) offset = counter->hw_counter.start_id - 1; if (offset >= 0 && (offset + counter->hw_counter.num_counters) < IPA_FLT_RT_HW_COUNTER) { - memset(&ipa3_ctx->flt_rt_counters.used_hw + offset, + memset(&ipa3_ctx->flt_rt_counters.used_hw[offset], 0, counter->hw_counter.num_counters * sizeof(bool)); } else { IPAERR_RL("unexpected hdl %d\n", hdl); @@ -10302,7 +10302,7 @@ void ipa3_counter_remove_hdl(int hdl) offset = counter->sw_counter.start_id - 1 - IPA_FLT_RT_HW_COUNTER; if (offset >= 0 && (offset + counter->sw_counter.num_counters) < IPA_FLT_RT_SW_COUNTER) { - memset(&ipa3_ctx->flt_rt_counters.used_sw + offset, + memset(&ipa3_ctx->flt_rt_counters.used_sw[offset], 0, counter->sw_counter.num_counters * sizeof(bool)); } else { IPAERR_RL("unexpected hdl %d\n", hdl); |