]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - drivers/net/ethernet/amazon/ena/ena_eth_com.c
net: ena: add detection and recovery mechanism for handling missed/misrouted MSI-X
[mirror_ubuntu-bionic-kernel.git] / drivers / net / ethernet / amazon / ena / ena_eth_com.c
index b11e573ad57a9a1d37f6e1f96b493e3795080d1a..ea149c134e1538d6c888db712d9b6cdc2b01412f 100644 (file)
@@ -504,3 +504,14 @@ int ena_com_tx_comp_req_id_get(struct ena_com_io_cq *io_cq, u16 *req_id)
 
        return 0;
 }
+
+bool ena_com_cq_empty(struct ena_com_io_cq *io_cq)
+{
+       struct ena_eth_io_rx_cdesc_base *cdesc;
+
+       cdesc = ena_com_get_next_rx_cdesc(io_cq);
+       if (cdesc)
+               return false;
+       else
+               return true;
+}