소스 검색

qcacld-3.0: Fix incorrect condition for TSO frags in pkt capture

The number of fragments in TSO packet are assembled incorrectly
due to wrong loop condition in packet capture mode.
Fix the condition to assemble all segments of TSO packet
correctly in packet capture mode.

Change-Id: Ifd7be13e56c12b2cb4e6a5000b355c9fa972962d
CRs-Fixed: 2877021
Surabhi Vishnoi 4 년 전
부모
커밋
5fd71222a8
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      core/dp/txrx/ol_tx_send.c

+ 2 - 2
core/dp/txrx/ol_tx_send.c

@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011-2020 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2011-2021 The Linux Foundation. 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
@@ -707,7 +707,7 @@ ol_tx_pkt_capture_tx_completion_process(
 		ip_len = tso_seg->seg.tso_flags.ip_len;
 		ip_len = qdf_cpu_to_be16(ip_len);
 
-		for (frag_cnt = 0; frag_cnt < num_frags; frag_cnt++) {
+		for (frag_cnt = 0; frag_cnt <= num_frags; frag_cnt++) {
 			qdf_mem_copy(qdf_nbuf_data(netbuf) + frag_len,
 				     tso_seg->seg.tso_frags[frag_cnt].vaddr,
 				     tso_seg->seg.tso_frags[frag_cnt].length);