search for: virtnet_bypass_xmit_ready

Displaying 8 results from an estimated 8 matches for "virtnet_bypass_xmit_ready".

2018 Feb 16
0
[RFC PATCH v3 2/3] virtio_net: Extend virtio to use VF datapath when available
...signed long guest_offloads; + + /* upper netdev created when BACKUP feature enabled */ + struct net_device *bypass_netdev; }; struct padded_vnet_hdr { @@ -2255,6 +2280,11 @@ static const struct net_device_ops virtnet_netdev = { .ndo_features_check = passthru_features_check, }; +static bool virtnet_bypass_xmit_ready(struct net_device *dev) +{ + return netif_running(dev) && netif_carrier_ok(dev); +} + static void virtnet_config_changed_work(struct work_struct *work) { struct virtnet_info *vi = @@ -2647,6 +2677,601 @@ static int virtnet_validate(struct virtio_device *vdev) return 0; } +static vo...
2018 Feb 16
8
[RFC PATCH v3 0/3] Enable virtio_net to act as a backup for a passthru device
Patch 1 introduces a new feature bit VIRTIO_NET_F_BACKUP that can be used by hypervisor to indicate that virtio_net interface should act as a backup for another device with the same MAC address. Ppatch 2 is in response to the community request for a 3 netdev solution. However, it creates some issues we'll get into in a moment. It extends virtio_net to use alternate datapath when available
2018 Feb 16
8
[RFC PATCH v3 0/3] Enable virtio_net to act as a backup for a passthru device
Patch 1 introduces a new feature bit VIRTIO_NET_F_BACKUP that can be used by hypervisor to indicate that virtio_net interface should act as a backup for another device with the same MAC address. Ppatch 2 is in response to the community request for a 3 netdev solution. However, it creates some issues we'll get into in a moment. It extends virtio_net to use alternate datapath when available
2018 Apr 05
0
[RFC PATCH net-next v5 3/4] virtio_net: Extend virtio to use VF datapath when available
...gt;backup_netdev); + if (child_netdev) + dev_close(child_netdev); + + return 0; +} + +static netdev_tx_t virtnet_bypass_drop_xmit(struct sk_buff *skb, + struct net_device *dev) +{ + atomic_long_inc(&dev->tx_dropped); + dev_kfree_skb_any(skb); + return NETDEV_TX_OK; +} + +static bool virtnet_bypass_xmit_ready(struct net_device *dev) +{ + return netif_running(dev) && netif_carrier_ok(dev); +} + +static netdev_tx_t virtnet_bypass_start_xmit(struct sk_buff *skb, + struct net_device *dev) +{ + struct virtnet_bypass_info *vbi = netdev_priv(dev); + struct net_device *xmit_dev; + + /* Try xmit...
2018 Apr 06
2
[RFC PATCH net-next v5 3/4] virtio_net: Extend virtio to use VF datapath when available
...ypass module. >+ >+ return 0; >+} >+ >+static netdev_tx_t virtnet_bypass_drop_xmit(struct sk_buff *skb, >+ struct net_device *dev) >+{ >+ atomic_long_inc(&dev->tx_dropped); >+ dev_kfree_skb_any(skb); >+ return NETDEV_TX_OK; >+} >+ >+static bool virtnet_bypass_xmit_ready(struct net_device *dev) >+{ >+ return netif_running(dev) && netif_carrier_ok(dev); >+} >+ >+static netdev_tx_t virtnet_bypass_start_xmit(struct sk_buff *skb, >+ struct net_device *dev) >+{ >+ struct virtnet_bypass_info *vbi = netdev_priv(dev); >+ struct n...
2018 Apr 06
2
[RFC PATCH net-next v5 3/4] virtio_net: Extend virtio to use VF datapath when available
...ypass module. >+ >+ return 0; >+} >+ >+static netdev_tx_t virtnet_bypass_drop_xmit(struct sk_buff *skb, >+ struct net_device *dev) >+{ >+ atomic_long_inc(&dev->tx_dropped); >+ dev_kfree_skb_any(skb); >+ return NETDEV_TX_OK; >+} >+ >+static bool virtnet_bypass_xmit_ready(struct net_device *dev) >+{ >+ return netif_running(dev) && netif_carrier_ok(dev); >+} >+ >+static netdev_tx_t virtnet_bypass_start_xmit(struct sk_buff *skb, >+ struct net_device *dev) >+{ >+ struct virtnet_bypass_info *vbi = netdev_priv(dev); >+ struct n...
2018 Apr 06
0
[RFC PATCH net-next v5 3/4] virtio_net: Extend virtio to use VF datapath when available
...net_device *dev, >> + struct ethtool_link_ksettings *cmd) >> +{ >> + struct virtnet_bypass_info *vbi = netdev_priv(dev); >> + struct net_device *child_netdev; >> + >> + child_netdev = rtnl_dereference(vbi->active_netdev); >> + if (!child_netdev || !virtnet_bypass_xmit_ready(child_netdev)) { >> + child_netdev = rtnl_dereference(vbi->backup_netdev); >> + if (!child_netdev || !virtnet_bypass_xmit_ready(child_netdev)) { >> + cmd->base.duplex = DUPLEX_UNKNOWN; >> + cmd->base.port = PORT_OTHER; >> + cmd->base.speed = SPEED_U...
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