search for: select_queue_fallback_t

Displaying 20 results from an estimated 29 matches for "select_queue_fallback_t".

2015 Apr 03
0
[PATCH net-next] netdevice: document NETDEV_TX_BUSY deprecation.
...<davem at davemloft.net> Signed-off-by: Rusty Russell <rusty at rustcorp.com.au> diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index dcf6ec27739b..a2cad44b8630 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h @@ -795,7 +795,10 @@ typedef u16 (*select_queue_fallback_t)(struct net_device *dev, * netdev_tx_t (*ndo_start_xmit)(struct sk_buff *skb, * struct net_device *dev); * Called when a packet needs to be transmitted. - * Must return NETDEV_TX_OK , NETDEV_TX_BUSY. + * Returns NETDEV_TX_OK. Can return NETDEV_TX_BUSY, but you s...
2015 Apr 02
3
[PATCH net-next] virtio: document queue state logic
commit d631b94e7a15277858ec5f88d674d93080506999 virtio: change comment in transmit started clarifying the logic behind queue state management, but introduced an inaccuracy: TX_BUSY does not cause a BUG message. Clean this up some more, explaining the tradeoffs in detail. Signed-off-by: Michael S. Tsirkin <mst at redhat.com> --- diff --git a/drivers/net/virtio_net.c
2015 Apr 02
3
[PATCH net-next] virtio: document queue state logic
commit d631b94e7a15277858ec5f88d674d93080506999 virtio: change comment in transmit started clarifying the logic behind queue state management, but introduced an inaccuracy: TX_BUSY does not cause a BUG message. Clean this up some more, explaining the tradeoffs in detail. Signed-off-by: Michael S. Tsirkin <mst at redhat.com> --- diff --git a/drivers/net/virtio_net.c
2019 Dec 23
0
[RHEL7]virtio-net: switch to use XPS to choose txq
...et_channels = virtnet_get_channels, > }; > > -/* To avoid contending a lock hold by a vcpu who would exit to host, select the > - * txq based on the processor id. > - */ > -static u16 virtnet_select_queue(struct net_device *dev, struct sk_buff *skb, > - void *accel_priv, select_queue_fallback_t fallback) > -{ > - int txq; > - struct virtnet_info *vi = netdev_priv(dev); > - > - if (skb_rx_queue_recorded(skb)) { > - txq = skb_get_rx_queue(skb); > - } else { > - txq = *__this_cpu_ptr(vi->vq_index); > - if (txq == -1) > - txq = 0; > - } > - > - w...
2018 Feb 16
0
[RFC PATCH v3 2/3] virtio_net: Extend virtio to use VF datapath when available
...return virtnet_bypass_drop_xmit(skb, dev); + } + + skb->dev = xmit_dev; + skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; + + return dev_queue_xmit(skb); +} + +static u16 +virtnet_bypass_select_queue(struct net_device *dev, struct sk_buff *skb, + void *accel_priv, select_queue_fallback_t fallback) +{ + /* This helper function exists to help dev_pick_tx get the correct + * destination queue. Using a helper function skips a call to + * skb_tx_hash and will put the skbs in the queue we expect on their + * way down to the bonding driver. + */ + u16 txq = skb_rx_queue_recorded(skb)...
2018 Apr 05
0
[RFC PATCH net-next v5 3/4] virtio_net: Extend virtio to use VF datapath when available
...et_bypass_drop_xmit(skb, dev); + } + + skb->dev = xmit_dev; + skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; + + return dev_queue_xmit(skb); +} + +static u16 virtnet_bypass_select_queue(struct net_device *dev, + struct sk_buff *skb, void *accel_priv, + select_queue_fallback_t fallback) +{ + /* This helper function exists to help dev_pick_tx get the correct + * destination queue. Using a helper function skips a call to + * skb_tx_hash and will put the skbs in the queue we expect on their + * way down to the bonding driver. + */ + u16 txq = skb_rx_queue_recorded(skb)...
2018 Apr 20
2
[PATCH v7 net-next 2/4] net: Introduce generic failover module
...cb(skb)->slave_dev_queue_mapping; > + > + return dev_queue_xmit(skb); > +} Is this going through qdisc twice? Won't this hurt performance measureably? > + > +static u16 failover_select_queue(struct net_device *dev, struct sk_buff *skb, > + void *accel_priv, > + select_queue_fallback_t fallback) > +{ > + struct failover_info *finfo = netdev_priv(dev); > + struct net_device *primary_dev; > + u16 txq; > + > + rcu_read_lock(); > + primary_dev = rcu_dereference(finfo->primary_dev); > + if (primary_dev) { > + const struct net_device_ops *ops = primary_de...
2018 Apr 20
2
[PATCH v7 net-next 2/4] net: Introduce generic failover module
...cb(skb)->slave_dev_queue_mapping; > + > + return dev_queue_xmit(skb); > +} Is this going through qdisc twice? Won't this hurt performance measureably? > + > +static u16 failover_select_queue(struct net_device *dev, struct sk_buff *skb, > + void *accel_priv, > + select_queue_fallback_t fallback) > +{ > + struct failover_info *finfo = netdev_priv(dev); > + struct net_device *primary_dev; > + u16 txq; > + > + rcu_read_lock(); > + primary_dev = rcu_dereference(finfo->primary_dev); > + if (primary_dev) { > + const struct net_device_ops *ops = primary_de...
2018 Apr 11
2
[RFC PATCH net-next v6 2/4] net: Introduce generic bypass module
...;+ skb->dev = xmit_dev; >+ skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; >+ >+ return dev_queue_xmit(skb); >+} >+EXPORT_SYMBOL_GPL(bypass_start_xmit); >+ >+u16 bypass_select_queue(struct net_device *dev, struct sk_buff *skb, >+ void *accel_priv, select_queue_fallback_t fallback) >+{ >+ /* This helper function exists to help dev_pick_tx get the correct >+ * destination queue. Using a helper function skips a call to >+ * skb_tx_hash and will put the skbs in the queue we expect on their >+ * way down to the bonding driver. >+ */ >+ u16 txq...
2018 Apr 11
2
[RFC PATCH net-next v6 2/4] net: Introduce generic bypass module
...;+ skb->dev = xmit_dev; >+ skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; >+ >+ return dev_queue_xmit(skb); >+} >+EXPORT_SYMBOL_GPL(bypass_start_xmit); >+ >+u16 bypass_select_queue(struct net_device *dev, struct sk_buff *skb, >+ void *accel_priv, select_queue_fallback_t fallback) >+{ >+ /* This helper function exists to help dev_pick_tx get the correct >+ * destination queue. Using a helper function skips a call to >+ * skb_tx_hash and will put the skbs in the queue we expect on their >+ * way down to the bonding driver. >+ */ >+ u16 txq...
2018 Apr 10
0
[RFC PATCH net-next v6 2/4] net: Introduce generic bypass module
...ypass_drop_xmit(skb, dev); + } + + skb->dev = xmit_dev; + skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; + + return dev_queue_xmit(skb); +} +EXPORT_SYMBOL_GPL(bypass_start_xmit); + +u16 bypass_select_queue(struct net_device *dev, struct sk_buff *skb, + void *accel_priv, select_queue_fallback_t fallback) +{ + /* This helper function exists to help dev_pick_tx get the correct + * destination queue. Using a helper function skips a call to + * skb_tx_hash and will put the skbs in the queue we expect on their + * way down to the bonding driver. + */ + u16 txq = skb_rx_queue_recorded(skb)...
2018 Apr 20
0
[PATCH v7 net-next 2/4] net: Introduce generic failover module
...t_dev)) + return failover_drop_xmit(skb, dev); + } + + skb->dev = xmit_dev; + skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; + + return dev_queue_xmit(skb); +} + +static u16 failover_select_queue(struct net_device *dev, struct sk_buff *skb, + void *accel_priv, + select_queue_fallback_t fallback) +{ + struct failover_info *finfo = netdev_priv(dev); + struct net_device *primary_dev; + u16 txq; + + rcu_read_lock(); + primary_dev = rcu_dereference(finfo->primary_dev); + if (primary_dev) { + const struct net_device_ops *ops = primary_dev->netdev_ops; + + if (ops->ndo_select...
2018 May 22
0
[PATCH net-next v11 3/5] net: Introduce net_failover driver
...rn net_failover_drop_xmit(skb, dev); + } + + skb->dev = xmit_dev; + skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; + + return dev_queue_xmit(skb); +} + +static u16 net_failover_select_queue(struct net_device *dev, + struct sk_buff *skb, void *accel_priv, + select_queue_fallback_t fallback) +{ + struct net_failover_info *nfo_info = netdev_priv(dev); + struct net_device *primary_dev; + u16 txq; + + primary_dev = rcu_dereference(nfo_info->primary_dev); + if (primary_dev) { + const struct net_device_ops *ops = primary_dev->netdev_ops; + + if (ops->ndo_select_queue) +...
2018 Apr 20
0
[PATCH v7 net-next 2/4] net: Introduce generic failover module
...sc twice? Won't this hurt performance > measureably? The failover dev has no queue (IFF_NO_QUEUE) , so doesn't go through qdisc twice. > >> + >> +static u16 failover_select_queue(struct net_device *dev, struct sk_buff *skb, >> + void *accel_priv, >> + select_queue_fallback_t fallback) >> +{ >> + struct failover_info *finfo = netdev_priv(dev); >> + struct net_device *primary_dev; >> + u16 txq; >> + >> + rcu_read_lock(); >> + primary_dev = rcu_dereference(finfo->primary_dev); >> + if (primary_dev) { >> + const str...
2018 Apr 11
0
[RFC PATCH net-next v6 2/4] net: Introduce generic bypass module
...b->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; >> + >> + return dev_queue_xmit(skb); >> +} >> +EXPORT_SYMBOL_GPL(bypass_start_xmit); >> + >> +u16 bypass_select_queue(struct net_device *dev, struct sk_buff *skb, >> + void *accel_priv, select_queue_fallback_t fallback) >> +{ >> + /* This helper function exists to help dev_pick_tx get the correct >> + * destination queue. Using a helper function skips a call to >> + * skb_tx_hash and will put the skbs in the queue we expect on their >> + * way down to the bonding driver....
2018 May 07
0
[PATCH net-next v10 2/4] net: Introduce generic failover module
...rn net_failover_drop_xmit(skb, dev); + } + + skb->dev = xmit_dev; + skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; + + return dev_queue_xmit(skb); +} + +static u16 net_failover_select_queue(struct net_device *dev, + struct sk_buff *skb, void *accel_priv, + select_queue_fallback_t fallback) +{ + struct net_failover_info *nfo_info = netdev_priv(dev); + struct net_device *primary_dev; + u16 txq; + + rcu_read_lock(); + primary_dev = rcu_dereference(nfo_info->primary_dev); + if (primary_dev) { + const struct net_device_ops *ops = primary_dev->netdev_ops; + + if (ops->...
2018 Apr 10
6
[RFC PATCH net-next v6 0/4] Enable virtio_net to act as a backup for a passthru device
The main motivation for this patch is to enable cloud service providers to provide an accelerated datapath to virtio-net enabled VMs in a transparent manner with no/minimal guest userspace changes. This also enables hypervisor controlled live migration to be supported with VMs that have direct attached SR-IOV VF devices. Patch 1 introduces a new feature bit VIRTIO_NET_F_BACKUP that can be used
2018 Apr 06
2
[RFC PATCH net-next v5 3/4] virtio_net: Extend virtio to use VF datapath when available
...>+ skb->dev = xmit_dev; >+ skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; >+ >+ return dev_queue_xmit(skb); >+} >+ >+static u16 virtnet_bypass_select_queue(struct net_device *dev, >+ struct sk_buff *skb, void *accel_priv, >+ select_queue_fallback_t fallback) >+{ >+ /* This helper function exists to help dev_pick_tx get the correct >+ * destination queue. Using a helper function skips a call to >+ * skb_tx_hash and will put the skbs in the queue we expect on their >+ * way down to the bonding driver. >+ */ >+ u16 txq...
2018 Apr 06
2
[RFC PATCH net-next v5 3/4] virtio_net: Extend virtio to use VF datapath when available
...>+ skb->dev = xmit_dev; >+ skb->queue_mapping = qdisc_skb_cb(skb)->slave_dev_queue_mapping; >+ >+ return dev_queue_xmit(skb); >+} >+ >+static u16 virtnet_bypass_select_queue(struct net_device *dev, >+ struct sk_buff *skb, void *accel_priv, >+ select_queue_fallback_t fallback) >+{ >+ /* This helper function exists to help dev_pick_tx get the correct >+ * destination queue. Using a helper function skips a call to >+ * skb_tx_hash and will put the skbs in the queue we expect on their >+ * way down to the bonding driver. >+ */ >+ u16 txq...
2018 Apr 05
6
[RFC PATCH net-next v5 0/4] Enable virtio_net to act as a backup for a passthru device
The main motivation for this patch is to enable cloud service providers to provide an accelerated datapath to virtio-net enabled VMs in a transparent manner with no/minimal guest userspace changes. This also enables hypervisor controlled live migration to be supported with VMs that have direct attached SR-IOV VF devices. Patch 1 introduces a new feature bit VIRTIO_NET_F_BACKUP that can be used