drivers: mark internal NXP symbols
[dpdk.git] / drivers / net / dpaa2 / dpaa2_ethdev.h
index 2f14a35..c7fb653 100644 (file)
@@ -1,7 +1,7 @@
 /* SPDX-License-Identifier: BSD-3-Clause
  *
  *   Copyright (c) 2015-2016 Freescale Semiconductor, Inc. All rights reserved.
- *   Copyright 2016 NXP
+ *   Copyright 2016-2019 NXP
  *
  */
 
@@ -22,6 +22,9 @@
 #define MAX_TCS                        DPNI_MAX_TC
 #define MAX_RX_QUEUES          128
 #define MAX_TX_QUEUES          16
+#define MAX_DPNI               8
+
+#define DPAA2_RX_DEFAULT_NBDESC 512
 
 /*default tc to be used for ,congestion, distribution etc configuration. */
 #define DPAA2_DEF_TC           0
@@ -107,8 +110,9 @@ struct dpaa2_dev_priv {
        uint32_t options;
        void *rx_vq[MAX_RX_QUEUES];
        void *tx_vq[MAX_TX_QUEUES];
-
        struct dpaa2_bp_list *bp_list; /**<Attached buffer pool list */
+       void *tx_conf_vq[MAX_TX_QUEUES];
+       uint8_t tx_conf_en;
        uint8_t max_mac_filters;
        uint8_t max_vlan_filters;
        uint8_t num_rx_tc;
@@ -129,6 +133,23 @@ struct dpaa2_dev_priv {
                uint64_t qos_extract_param;
                uint64_t fs_extract_param[MAX_TCS];
        } extract;
+
+       uint16_t ss_offset;
+       uint64_t ss_iova;
+       uint64_t ss_param_iova;
+#if defined(RTE_LIBRTE_IEEE1588)
+       /*stores timestamp of last received packet on dev*/
+       uint64_t rx_timestamp;
+       /*stores timestamp of last received tx confirmation packet on dev*/
+       uint64_t tx_timestamp;
+       /* stores pointer to next tx_conf queue that should be processed,
+        * it corresponds to last packet transmitted
+        */
+       struct dpaa2_queue *next_tx_conf_queue;
+#endif
+
+       struct rte_eth_dev *eth_dev; /**< Pointer back to holding ethdev */
+
        LIST_HEAD(, rte_flow) flows; /**< Configured flow rule handles. */
 };
 
@@ -143,11 +164,13 @@ int dpaa2_remove_flow_dist(struct rte_eth_dev *eth_dev,
 
 int dpaa2_attach_bp_list(struct dpaa2_dev_priv *priv, void *blist);
 
+__rte_internal
 int dpaa2_eth_eventq_attach(const struct rte_eth_dev *dev,
                int eth_rx_queue_id,
-               uint16_t dpcon_id,
+               struct dpaa2_dpcon_dev *dpcon,
                const struct rte_event_eth_rx_adapter_queue_conf *queue_conf);
 
+__rte_internal
 int dpaa2_eth_eventq_detach(const struct rte_eth_dev *dev,
                int eth_rx_queue_id);
 
@@ -179,5 +202,20 @@ uint16_t dpaa2_dev_tx_ordered(void *queue, struct rte_mbuf **bufs,
 uint16_t dummy_dev_tx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts);
 void dpaa2_dev_free_eqresp_buf(uint16_t eqresp_ci);
 void dpaa2_flow_clean(struct rte_eth_dev *dev);
-
+uint16_t dpaa2_dev_tx_conf(void *queue)  __rte_unused;
+
+#if defined(RTE_LIBRTE_IEEE1588)
+int dpaa2_timesync_enable(struct rte_eth_dev *dev);
+int dpaa2_timesync_disable(struct rte_eth_dev *dev);
+int dpaa2_timesync_read_time(struct rte_eth_dev *dev,
+                                       struct timespec *timestamp);
+int dpaa2_timesync_write_time(struct rte_eth_dev *dev,
+                                       const struct timespec *timestamp);
+int dpaa2_timesync_adjust_time(struct rte_eth_dev *dev, int64_t delta);
+int dpaa2_timesync_read_rx_timestamp(struct rte_eth_dev *dev,
+                                               struct timespec *timestamp,
+                                               uint32_t flags __rte_unused);
+int dpaa2_timesync_read_tx_timestamp(struct rte_eth_dev *dev,
+                                         struct timespec *timestamp);
+#endif
 #endif /* _DPAA2_ETHDEV_H */