1d30ea906Sjfb8856606 /* SPDX-License-Identifier: BSD-3-Clause 2d30ea906Sjfb8856606 * Copyright (c) 2015-2018 Atomic Rules LLC 32bfe3f2eSlogwang */ 42bfe3f2eSlogwang 52bfe3f2eSlogwang #ifndef _ARK_ETHDEV_RX_H_ 62bfe3f2eSlogwang #define _ARK_ETHDEV_RX_H_ 72bfe3f2eSlogwang 82bfe3f2eSlogwang #include <stdint.h> 92bfe3f2eSlogwang 102bfe3f2eSlogwang #include <rte_mbuf.h> 112bfe3f2eSlogwang #include <rte_mempool.h> 12d30ea906Sjfb8856606 #include <rte_ethdev_driver.h> 132bfe3f2eSlogwang 14*2d9fd380Sjfb8856606 extern uint64_t ark_timestamp_rx_dynflag; 15*2d9fd380Sjfb8856606 extern int ark_timestamp_dynfield_offset; 162bfe3f2eSlogwang 172bfe3f2eSlogwang int eth_ark_dev_rx_queue_setup(struct rte_eth_dev *dev, 182bfe3f2eSlogwang uint16_t queue_idx, 192bfe3f2eSlogwang uint16_t nb_desc, 202bfe3f2eSlogwang unsigned int socket_id, 212bfe3f2eSlogwang const struct rte_eth_rxconf *rx_conf, 222bfe3f2eSlogwang struct rte_mempool *mp); 232bfe3f2eSlogwang uint32_t eth_ark_dev_rx_queue_count(struct rte_eth_dev *dev, 242bfe3f2eSlogwang uint16_t rx_queue_id); 252bfe3f2eSlogwang int eth_ark_rx_stop_queue(struct rte_eth_dev *dev, uint16_t queue_id); 262bfe3f2eSlogwang int eth_ark_rx_start_queue(struct rte_eth_dev *dev, uint16_t queue_id); 272bfe3f2eSlogwang uint16_t eth_ark_recv_pkts_noop(void *rx_queue, struct rte_mbuf **rx_pkts, 282bfe3f2eSlogwang uint16_t nb_pkts); 292bfe3f2eSlogwang uint16_t eth_ark_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, 302bfe3f2eSlogwang uint16_t nb_pkts); 312bfe3f2eSlogwang void eth_ark_dev_rx_queue_release(void *rx_queue); 322bfe3f2eSlogwang void eth_rx_queue_stats_get(void *vqueue, struct rte_eth_stats *stats); 332bfe3f2eSlogwang void eth_rx_queue_stats_reset(void *vqueue); 342bfe3f2eSlogwang void eth_ark_rx_dump_queue(struct rte_eth_dev *dev, uint16_t queue_id, 352bfe3f2eSlogwang const char *msg); 362bfe3f2eSlogwang void eth_ark_udm_force_close(struct rte_eth_dev *dev); 372bfe3f2eSlogwang 382bfe3f2eSlogwang #endif 39