Found a crash in the FM10k vector driver when it tries to send a packet with a
VLAN header priority (PCP) field value >= 4. This results in the FM10k
returning the following error.
testpmd> PMD: fm10k_dev_interrupt_handler_pf(): INT: find fault!
PMD: fm10k_dev_handle_fault(): THI_MAL_DIS_Q_FAULT: PF(0) Addr:0x0 Spec: 0x0
The reason is the (pkt->vlan_tci << 16) value gets sign extended and causes
illegal values to be written into the TX descriptor. The following is a patch
to fix the issue. I don’t know what the procedure is for getting this into the
fix stream.
--- ./drivers/net/fm10k/fm10k_rxtx_vec.c 2016-11-13 09:28:12.000000000
-0500
+++ ./drivers/net/fm10k/fm10k_rxtx_vec.c.new 2017-02-09 06:37:00.362960064
-0500
@@ -718,7 +718,7 @@ vtx1(volatile struct fm10k_tx_desc *txdp
struct rte_mbuf *pkt, uint64_t flags)
{
__m128i descriptor = _mm_set_epi64x(flags << 56 |
- pkt->vlan_tci << 16 | pkt->data_len,
+ (uint64_t)(pkt->vlan_tci) << 16 |
(uint64_t)pkt->data_len,
MBUF_DMA_ADDR(pkt));
_mm_store_si128((__m128i *)txdp, descriptor);
}