Parcourir la source

qcacmn: Modify check to ensure consecutive PN for frags

Modify check to ensure packet number is consecutive for
fragments and drop the fragments if the check fails.

Change-Id: I2ca0ef6211594ba35aae894e6a385d3d5778bff6
CRs-Fixed: 2874369
Yeshwanth Sriram Guntuka il y a 4 ans
Parent
commit
81c70ce74b
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      dp/wifi3.0/dp_rx_defrag.c

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

@@ -877,9 +877,9 @@ static int dp_rx_defrag_pn_check(qdf_nbuf_t msdu,
 		((uint64_t)rx_mpdu_info_details->pn_127_96 << 32);
 
 	if (cur_pn128[1] == prev_pn128[1])
-		out_of_order = (cur_pn128[0] <= prev_pn128[0]);
+		out_of_order = (cur_pn128[0] - prev_pn128[0] != 1);
 	else
-		out_of_order = (cur_pn128[1] < prev_pn128[1]);
+		out_of_order = (cur_pn128[1] - prev_pn128[1] != 1);
 
 	return out_of_order;
 }