net/nfp: fix assigning port id in mbuf
[dpdk.git] / drivers / net / nfp / nfp_nspu.h
index 7734b4f..8c33835 100644 (file)
@@ -57,6 +57,9 @@
  * the fast path.
  */
 
+#include <rte_spinlock.h>
+#include "nfp_net_eth.h"
+
 typedef struct {
        int nfp;        /* NFP device */
        int pcie_bar;   /* PF PCI BAR to work with */
@@ -67,13 +70,14 @@ typedef struct {
        uint64_t windowsz; /* NSPU BAR window size */
        void *cfg_base; /* Expansion BARs address */
        void *mem_base; /* NSP interface */
+       rte_spinlock_t nsp_lock;
 } nspu_desc_t;
 
 int nfp_nspu_init(nspu_desc_t *desc, int nfp, int pcie_bar, size_t pcie_barsz,
                  int exp_bar, void *exp_bar_cfg_base, void *exp_bar_mmap);
 int nfp_nsp_get_abi_version(nspu_desc_t *desc, int *major, int *minor);
-int nfp_fw_reset(nspu_desc_t *nspu_desc);
-int nfp_fw_upload(nspu_desc_t *nspu_desc);
-int nfp_nspu_set_bar_from_symbl(nspu_desc_t *desc, const char *symbl,
-                               uint32_t expbar, uint64_t *pcie_offset,
-                               ssize_t *size);
+int nfp_nsp_fw_setup(nspu_desc_t *desc, const char *sym, uint64_t *pcie_offset);
+int nfp_nsp_map_ctrl_bar(nspu_desc_t *desc, uint64_t *pcie_offset);
+void nfp_nsp_map_queues_bar(nspu_desc_t *desc, uint64_t *pcie_offset);
+int nfp_nsp_eth_config(nspu_desc_t *desc, int port, int up);
+int nfp_nsp_eth_read_table(nspu_desc_t *desc, union eth_table_entry **table);