Browse Source

qcacmn: Fix DHCP indication to FW feature in SAP for HL

In case of HL, send tx completion bit in HTT tx descriptor
to receive tx completion from FW and disable DHCP indication
to FW properly.

Change-Id: I2540a125c84c322507acdc0647ee8839d21067ce
CRs-Fixed: 2506020
Nirav Shah 5 years ago
parent
commit
31435bbef5
2 changed files with 7 additions and 2 deletions
  1. 1 0
      htc/htc_packet.h
  2. 6 2
      htc/htc_send.c

+ 1 - 0
htc/htc_packet.h

@@ -78,6 +78,7 @@ struct htc_tx_packet_info {
 
 
 #define HTC_TX_PACKET_FLAG_FIXUP_NETBUF (1 << 0)
+#define HTC_TX_PACKET_FLAG_HTC_HEADER_IN_NETBUF_DATA (1 << 1)
 
 /**
  * struct htc_rx_packet_info - HTC RX Packet information

+ 6 - 2
htc/htc_send.c

@@ -112,8 +112,10 @@ static inline void restore_tx_packet(HTC_TARGET *target, HTC_PACKET *pPacket)
 		qdf_nbuf_unmap(target->osdev, netbuf, QDF_DMA_TO_DEVICE);
 		pPacket->PktInfo.AsTx.Flags &= ~HTC_TX_PACKET_FLAG_FIXUP_NETBUF;
 	}
-
-	qdf_nbuf_pull_head(netbuf, sizeof(HTC_FRAME_HDR));
+	if (pPacket->PktInfo.AsTx.Flags &
+		HTC_TX_PACKET_FLAG_HTC_HEADER_IN_NETBUF_DATA) {
+		qdf_nbuf_pull_head(netbuf, sizeof(HTC_FRAME_HDR));
+	}
 }
 
 static void send_packet_completion(HTC_TARGET *target, HTC_PACKET *pPacket)
@@ -1484,6 +1486,8 @@ static inline QDF_STATUS __htc_send_pkt(HTC_HANDLE HTCHandle,
 		return QDF_STATUS_E_INVAL;
 
 	qdf_nbuf_push_head(netbuf, sizeof(HTC_FRAME_HDR));
+	pPacket->PktInfo.AsTx.Flags |=
+		HTC_TX_PACKET_FLAG_HTC_HEADER_IN_NETBUF_DATA;
 	/* setup HTC frame header */
 	htc_hdr = (HTC_FRAME_HDR *)qdf_nbuf_get_frag_vaddr(netbuf, 0);
 	AR_DEBUG_ASSERT(htc_hdr);