git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
remove extra parentheses in return statement
[dpdk.git]
/
drivers
/
net
/
mpipe
/
mpipe_tilegx.c
diff --git
a/drivers/net/mpipe/mpipe_tilegx.c
b/drivers/net/mpipe/mpipe_tilegx.c
index
6e3e304
..
04f3c9f
100644
(file)
--- a/
drivers/net/mpipe/mpipe_tilegx.c
+++ b/
drivers/net/mpipe/mpipe_tilegx.c
@@
-80,6
+80,7
@@
struct mpipe_context {
static struct mpipe_context mpipe_contexts[GXIO_MPIPE_INSTANCE_MAX];
static int mpipe_instances;
static struct mpipe_context mpipe_contexts[GXIO_MPIPE_INSTANCE_MAX];
static int mpipe_instances;
+static const char *drivername = "MPIPE PMD";
/* Per queue statistics. */
struct mpipe_queue_stats {
/* Per queue statistics. */
struct mpipe_queue_stats {
@@
-122,7
+123,6
@@
struct mpipe_dev_priv {
int channel; /* Device channel. */
int port_id; /* DPDK port index. */
struct rte_eth_dev *eth_dev; /* DPDK device. */
int channel; /* Device channel. */
int port_id; /* DPDK port index. */
struct rte_eth_dev *eth_dev; /* DPDK device. */
- struct rte_pci_device pci_dev; /* PCI device data. */
struct rte_mbuf **tx_comps; /* TX completion array. */
struct rte_mempool *rx_mpool; /* mpool used by the rx queues. */
unsigned rx_offset; /* Receive head room. */
struct rte_mbuf **tx_comps; /* TX completion array. */
struct rte_mempool *rx_mpool; /* mpool used by the rx queues. */
unsigned rx_offset; /* Receive head room. */
@@
-361,8
+361,8
@@
static inline int
mpipe_link_compare(struct rte_eth_link *link1,
struct rte_eth_link *link2)
{
mpipe_link_compare(struct rte_eth_link *link1,
struct rte_eth_link *link2)
{
- return (
(
*(uint64_t *)link1 == *(uint64_t *)link2)
- ? -1 : 0
)
;
+ return (*(uint64_t *)link1 == *(uint64_t *)link2)
+ ? -1 : 0;
}
static int
}
static int
@@
-1567,7
+1567,6
@@
rte_pmd_mpipe_devinit(const char *ifname,
priv->context = context;
priv->instance = instance;
priv->is_xaui = (strncmp(ifname, "xgbe", 4) == 0);
priv->context = context;
priv->instance = instance;
priv->is_xaui = (strncmp(ifname, "xgbe", 4) == 0);
- priv->pci_dev.numa_node = instance;
priv->channel = -1;
mac = priv->mac_addr.addr_bytes;
priv->channel = -1;
mac = priv->mac_addr.addr_bytes;
@@
-1592,9
+1591,14
@@
rte_pmd_mpipe_devinit(const char *ifname,
priv->eth_dev = eth_dev;
priv->port_id = eth_dev->data->port_id;
eth_dev->data->dev_private = priv;
priv->eth_dev = eth_dev;
priv->port_id = eth_dev->data->port_id;
eth_dev->data->dev_private = priv;
- eth_dev->pci_dev = &priv->pci_dev;
eth_dev->data->mac_addrs = &priv->mac_addr;
eth_dev->data->mac_addrs = &priv->mac_addr;
+ eth_dev->data->dev_flags = 0;
+ eth_dev->data->kdrv = RTE_KDRV_NONE;
+ eth_dev->driver = NULL;
+ eth_dev->data->drv_name = drivername;
+ eth_dev->data->numa_node = instance;
+
eth_dev->dev_ops = &mpipe_dev_ops;
eth_dev->rx_pkt_burst = &mpipe_recv_pkts;
eth_dev->tx_pkt_burst = &mpipe_xmit_pkts;
eth_dev->dev_ops = &mpipe_dev_ops;
eth_dev->rx_pkt_burst = &mpipe_recv_pkts;
eth_dev->tx_pkt_burst = &mpipe_xmit_pkts;