Thread (285 messages) 285 messages, 6 authors, 2021-11-25
STALE1682d REVIEWED: 4 (2M)

[PATCH 5.15 109/279] net/ipa: ipa_resource: Fix wrong for loop range

From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Date: 2021-11-24 13:53:42
Also in: lkml
Subsystem: networking drivers, qcom ipa driver, the rest · Maintainers: Andrew Lunn, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Alex Elder, Linus Torvalds

From: Konrad Dybcio <redacted>

[ Upstream commit 27df68d579c67ef6c39a5047559b6a7c08c96219 ]

The source group count was mistakenly assigned to both dst and src loops.
Fix it to make IPA probe and work again.

Fixes: 4fd704b3608a ("net: ipa: record number of groups in data")
Acked-by: AngeloGioacchino Del Regno <redacted>
Reviewed-by: Marijn Suijten <marijn.suijten@somainline.org>
Signed-off-by: Konrad Dybcio <redacted>
Reviewed-by: Alex Elder <redacted>
Link: https://lore.kernel.org/r/20211111183724.593478-1-konrad.dybcio@somainline.org (local)
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 drivers/net/ipa/ipa_resource.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ipa/ipa_resource.c b/drivers/net/ipa/ipa_resource.c
index e3da95d694099..06cec71993823 100644
--- a/drivers/net/ipa/ipa_resource.c
+++ b/drivers/net/ipa/ipa_resource.c
@@ -52,7 +52,7 @@ static bool ipa_resource_limits_valid(struct ipa *ipa,
 				return false;
 	}
 
-	group_count = data->rsrc_group_src_count;
+	group_count = data->rsrc_group_dst_count;
 	if (!group_count || group_count > IPA_RESOURCE_GROUP_MAX)
 		return false;
 
-- 
2.33.0


Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help