From cc46006b7db0fde08edaebcbf749762649c22472 Mon Sep 17 00:00:00 2001 From: Himanshu Batra Date: Sun, 9 Jan 2022 11:02:50 +0530 Subject: [PATCH] qcacmn: Use correct variable to iterate reo dest rings Currently the MAX_REO_DEST_RINGS is used to iterate reo dst ring. If the MAX_REO_DEST_RINGS is more that no. of reo dest ring initialize, the print is seen on console as hal_ring_hdl will be null for extra iterations. Add fix to use correct variable to iterate reo dest rings Change-Id: Ibcb44dda49696a7bb029b49ce3d50acd8741590a --- dp/wifi3.0/dp_ipa.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dp/wifi3.0/dp_ipa.c b/dp/wifi3.0/dp_ipa.c index 34eedd9c31..ef8af9081c 100644 --- a/dp/wifi3.0/dp_ipa.c +++ b/dp/wifi3.0/dp_ipa.c @@ -1,6 +1,6 @@ /* * Copyright (c) 2017-2021, The Linux Foundation. All rights reserved. - * Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved. + * Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above @@ -215,7 +215,7 @@ static void dp_ipa_set_reo_ctx_mapping_lock_required(struct dp_soc *soc, hal_ring_handle_t hal_ring_hdl; int ring; - for (ring = 0; ring < MAX_REO_DEST_RINGS; ring++) { + for (ring = 0; ring < soc->num_reo_dest_rings; ring++) { hal_ring_hdl = soc->reo_dest_ring[ring].hal_srng; hal_srng_lock(hal_ring_hdl); soc->ipa_reo_ctx_lock_required[ring] = lock_required;