search for: ethtool_coalesc

Displaying 20 results from an estimated 35 matches for "ethtool_coalesc".

Did you mean: ethtool_coalesce
2018 Sep 13
5
[PATCH net-next V2] virtio_net: ethtool tx napi configuration
...deletion(-) diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c index 765920905226..6e70864f5899 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c @@ -66,6 +66,8 @@ DECLARE_EWMA(pkt_len, 0, 64) #define VIRTNET_DRIVER_VERSION "1.0.0" +static const u32 ethtool_coalesce_napi_mask = (1UL << 10); + static const unsigned long guest_offloads[] = { VIRTIO_NET_F_GUEST_TSO4, VIRTIO_NET_F_GUEST_TSO6, @@ -1444,7 +1446,10 @@ static int virtnet_poll_tx(struct napi_struct *napi, int budget) virtqueue_napi_complete(napi, sq->vq, 0); - if (sq->vq->num...
2018 Sep 13
5
[PATCH net-next V2] virtio_net: ethtool tx napi configuration
...deletion(-) diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c index 765920905226..6e70864f5899 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c @@ -66,6 +66,8 @@ DECLARE_EWMA(pkt_len, 0, 64) #define VIRTNET_DRIVER_VERSION "1.0.0" +static const u32 ethtool_coalesce_napi_mask = (1UL << 10); + static const unsigned long guest_offloads[] = { VIRTIO_NET_F_GUEST_TSO4, VIRTIO_NET_F_GUEST_TSO6, @@ -1444,7 +1446,10 @@ static int virtnet_poll_tx(struct napi_struct *napi, int budget) virtqueue_napi_complete(napi, sq->vq, 0); - if (sq->vq->num...
2017 Jan 06
2
[PATCH V4 net-next 3/3] tun: rx batching
...n->pcpu_stats = netdev_alloc_pcpu_stats(struct tun_pcpu_stats); > if (!tun->pcpu_stats) { > @@ -2439,6 +2478,29 @@ static void tun_set_msglevel(struct net_device *dev, u32 value) > #endif > } > > +static int tun_get_coalesce(struct net_device *dev, > + struct ethtool_coalesce *ec) > +{ > + struct tun_struct *tun = netdev_priv(dev); > + > + ec->rx_max_coalesced_frames = tun->rx_batched; > + > + return 0; > +} > + > +static int tun_set_coalesce(struct net_device *dev, > + struct ethtool_coalesce *ec) > +{ > + struct tun_str...
2017 Jan 06
2
[PATCH V4 net-next 3/3] tun: rx batching
...n->pcpu_stats = netdev_alloc_pcpu_stats(struct tun_pcpu_stats); > if (!tun->pcpu_stats) { > @@ -2439,6 +2478,29 @@ static void tun_set_msglevel(struct net_device *dev, u32 value) > #endif > } > > +static int tun_get_coalesce(struct net_device *dev, > + struct ethtool_coalesce *ec) > +{ > + struct tun_struct *tun = netdev_priv(dev); > + > + ec->rx_max_coalesced_frames = tun->rx_batched; > + > + return 0; > +} > + > +static int tun_set_coalesce(struct net_device *dev, > + struct ethtool_coalesce *ec) > +{ > + struct tun_str...
2017 Jan 09
1
[PATCH V4 net-next 3/3] tun: rx batching
On Mon, Jan 09, 2017 at 10:39:55AM +0800, Jason Wang wrote: > > > On 2017?01?07? 03:47, Michael S. Tsirkin wrote: > > > +static int tun_get_coalesce(struct net_device *dev, > > > + struct ethtool_coalesce *ec) > > > +{ > > > + struct tun_struct *tun = netdev_priv(dev); > > > + > > > + ec->rx_max_coalesced_frames = tun->rx_batched; > > > + > > > + return 0; > > > +} > > > + > > > +static int tun_set_coalesce(struc...
2017 Jan 09
1
[PATCH V4 net-next 3/3] tun: rx batching
On Mon, Jan 09, 2017 at 10:39:55AM +0800, Jason Wang wrote: > > > On 2017?01?07? 03:47, Michael S. Tsirkin wrote: > > > +static int tun_get_coalesce(struct net_device *dev, > > > + struct ethtool_coalesce *ec) > > > +{ > > > + struct tun_struct *tun = netdev_priv(dev); > > > + > > > + ec->rx_max_coalesced_frames = tun->rx_batched; > > > + > > > + return 0; > > > +} > > > + > > > +static int tun_set_coalesce(struc...
2018 Sep 13
0
[PATCH net-next V2] virtio_net: ethtool tx napi configuration
...et/virtio_net.c b/drivers/net/virtio_net.c > index 765920905226..6e70864f5899 100644 > --- a/drivers/net/virtio_net.c > +++ b/drivers/net/virtio_net.c > @@ -66,6 +66,8 @@ DECLARE_EWMA(pkt_len, 0, 64) > > #define VIRTNET_DRIVER_VERSION "1.0.0" > > +static const u32 ethtool_coalesce_napi_mask = (1UL << 10); > + This is no longer needed > static const unsigned long guest_offloads[] = { > VIRTIO_NET_F_GUEST_TSO4, > VIRTIO_NET_F_GUEST_TSO6, > @@ -1444,7 +1446,10 @@ static int virtnet_poll_tx(struct napi_struct *napi, int budget) > >...
2018 Oct 09
2
[PATCH net-next V3] virtio_net: ethtool tx napi configuration
...b/drivers/net/virtio_net.c index 765920905226..751f385f4e0a 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c @@ -2181,6 +2181,54 @@ static int virtnet_get_link_ksettings(struct net_device *dev, return 0; } +static int virtnet_set_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct ethtool_coalesce ec_default = { + .cmd = ETHTOOL_SCOALESCE, + .rx_max_coalesced_frames = 1, + }; + struct virtnet_info *vi = netdev_priv(dev); + int i, napi_weight; + bool running = netif_running(dev); + + if (ec->tx_max_coalesced_frames > 1) + return -EINVAL; + + ec_defa...
2018 Oct 09
2
[PATCH net-next V3] virtio_net: ethtool tx napi configuration
...b/drivers/net/virtio_net.c index 765920905226..751f385f4e0a 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c @@ -2181,6 +2181,54 @@ static int virtnet_get_link_ksettings(struct net_device *dev, return 0; } +static int virtnet_set_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct ethtool_coalesce ec_default = { + .cmd = ETHTOOL_SCOALESCE, + .rx_max_coalesced_frames = 1, + }; + struct virtnet_info *vi = netdev_priv(dev); + int i, napi_weight; + bool running = netif_running(dev); + + if (ec->tx_max_coalesced_frames > 1) + return -EINVAL; + + ec_defa...
2015 Feb 10
4
[PATCH RFC v5 net-next 4/6] virtio-net: add basic interrupt coalescing support
...t; + __u32 tx_max_coalesced_frames; > }; > > struct padded_vnet_hdr { > @@ -1404,12 +1409,73 @@ static void virtnet_get_channels(struct net_device *dev, > channels->other_count = 0; > } > > +static int virtnet_set_coalesce(struct net_device *dev, > + struct ethtool_coalesce *ec) > +{ > + struct virtnet_info *vi = netdev_priv(dev); > + struct scatterlist sg; > + struct virtio_net_ctrl_coalesce c; > + > + if (!vi->has_cvq || > + !virtio_has_feature(vi->vdev, VIRTIO_NET_F_CTRL_COALESCE)) > + return -EOPNOTSUPP; > + if (vi->rx_coa...
2015 Feb 10
4
[PATCH RFC v5 net-next 4/6] virtio-net: add basic interrupt coalescing support
...t; + __u32 tx_max_coalesced_frames; > }; > > struct padded_vnet_hdr { > @@ -1404,12 +1409,73 @@ static void virtnet_get_channels(struct net_device *dev, > channels->other_count = 0; > } > > +static int virtnet_set_coalesce(struct net_device *dev, > + struct ethtool_coalesce *ec) > +{ > + struct virtnet_info *vi = netdev_priv(dev); > + struct scatterlist sg; > + struct virtio_net_ctrl_coalesce c; > + > + if (!vi->has_cvq || > + !virtio_has_feature(vi->vdev, VIRTIO_NET_F_CTRL_COALESCE)) > + return -EOPNOTSUPP; > + if (vi->rx_coa...
2023 Jul 27
2
[PATCH net-next V4 2/3] virtio_net: support per queue interrupt coalesce command
...gt; > Acked-by: Michael S. Tsirkin <mst at redhat.com> FTR, this patch is significantly different from the version previously acked/reviewed, I'm unsure if all the reviewers are ok with the new one. [...] > static int virtnet_set_coalesce(struct net_device *dev, > struct ethtool_coalesce *ec, > struct kernel_ethtool_coalesce *kernel_coal, > struct netlink_ext_ack *extack) > { > struct virtnet_info *vi = netdev_priv(dev); > - int ret, i, napi_weight; > + int ret, queue_number, napi_weight; > bool update_napi = false; > > /* Can't ch...
2017 Jan 09
0
[PATCH V4 net-next 3/3] tun: rx batching
On 2017?01?07? 03:47, Michael S. Tsirkin wrote: >> +static int tun_get_coalesce(struct net_device *dev, >> + struct ethtool_coalesce *ec) >> +{ >> + struct tun_struct *tun = netdev_priv(dev); >> + >> + ec->rx_max_coalesced_frames = tun->rx_batched; >> + >> + return 0; >> +} >> + >> +static int tun_set_coalesce(struct net_device *dev, >> + struct ethtool_coa...
2015 Feb 09
0
[PATCH RFC v5 net-next 4/6] virtio-net: add basic interrupt coalescing support
...ax_coalesced_frames; + __u32 tx_coalesce_usecs; + __u32 tx_max_coalesced_frames; }; struct padded_vnet_hdr { @@ -1404,12 +1409,73 @@ static void virtnet_get_channels(struct net_device *dev, channels->other_count = 0; } +static int virtnet_set_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct virtnet_info *vi = netdev_priv(dev); + struct scatterlist sg; + struct virtio_net_ctrl_coalesce c; + + if (!vi->has_cvq || + !virtio_has_feature(vi->vdev, VIRTIO_NET_F_CTRL_COALESCE)) + return -EOPNOTSUPP; + if (vi->rx_coalesce_usecs != ec->rx_coalesce_usecs || +...
2015 Feb 09
0
[PATCH RFC v5 net-next 4/6] virtio-net: add basic interrupt coalescing support
...ax_coalesced_frames; + __u32 tx_coalesce_usecs; + __u32 tx_max_coalesced_frames; }; struct padded_vnet_hdr { @@ -1404,12 +1409,73 @@ static void virtnet_get_channels(struct net_device *dev, channels->other_count = 0; } +static int virtnet_set_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct virtnet_info *vi = netdev_priv(dev); + struct scatterlist sg; + struct virtio_net_ctrl_coalesce c; + + if (!vi->has_cvq || + !virtio_has_feature(vi->vdev, VIRTIO_NET_F_CTRL_COALESCE)) + return -EOPNOTSUPP; + if (vi->rx_coalesce_usecs != ec->rx_coalesce_usecs || +...
2023 Jul 28
1
[PATCH net-next V4 2/3] virtio_net: support per queue interrupt coalesce command
...ly > acked/reviewed, I'm unsure if all the reviewers are ok with the new > one. > > [...] still ok by me Acked-by: Michael S. Tsirkin <mst at redhat.com> let's wait for Jason too. > > static int virtnet_set_coalesce(struct net_device *dev, > > struct ethtool_coalesce *ec, > > struct kernel_ethtool_coalesce *kernel_coal, > > struct netlink_ext_ack *extack) > > { > > struct virtnet_info *vi = netdev_priv(dev); > > - int ret, i, napi_weight; > > + int ret, queue_number, napi_weight; > > bool update_napi = f...
2017 Jan 18
0
[PATCH net-next V5 3/3] tun: rx batching
...+ tun->rx_batched = 0; tun->pcpu_stats = netdev_alloc_pcpu_stats(struct tun_pcpu_stats); if (!tun->pcpu_stats) { @@ -2438,6 +2477,29 @@ static void tun_set_msglevel(struct net_device *dev, u32 value) #endif } +static int tun_get_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct tun_struct *tun = netdev_priv(dev); + + ec->rx_max_coalesced_frames = tun->rx_batched; + + return 0; +} + +static int tun_set_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct tun_struct *tun = netdev_priv(dev); + + if (ec->rx_max_coalesced...
2017 Jan 06
0
[PATCH V4 net-next 3/3] tun: rx batching
...+ tun->rx_batched = 0; tun->pcpu_stats = netdev_alloc_pcpu_stats(struct tun_pcpu_stats); if (!tun->pcpu_stats) { @@ -2439,6 +2478,29 @@ static void tun_set_msglevel(struct net_device *dev, u32 value) #endif } +static int tun_get_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct tun_struct *tun = netdev_priv(dev); + + ec->rx_max_coalesced_frames = tun->rx_batched; + + return 0; +} + +static int tun_set_coalesce(struct net_device *dev, + struct ethtool_coalesce *ec) +{ + struct tun_struct *tun = netdev_priv(dev); + + if (ec->rx_max_coalesced...
2015 Feb 10
0
[PATCH RFC v5 net-next 4/6] virtio-net: add basic interrupt coalescing support
...}; > > > > struct padded_vnet_hdr { > > @@ -1404,12 +1409,73 @@ static void virtnet_get_channels(struct net_device *dev, > > channels->other_count = 0; > > } > > > > +static int virtnet_set_coalesce(struct net_device *dev, > > + struct ethtool_coalesce *ec) > > +{ > > + struct virtnet_info *vi = netdev_priv(dev); > > + struct scatterlist sg; > > + struct virtio_net_ctrl_coalesce c; > > + > > + if (!vi->has_cvq || > > + !virtio_has_feature(vi->vdev, VIRTIO_NET_F_CTRL_COALESCE)) > > + retu...
2015 Feb 10
0
[PATCH RFC v5 net-next 4/6] virtio-net: add basic interrupt coalescing support
...}; > > > > struct padded_vnet_hdr { > > @@ -1404,12 +1409,73 @@ static void virtnet_get_channels(struct net_device *dev, > > channels->other_count = 0; > > } > > > > +static int virtnet_set_coalesce(struct net_device *dev, > > + struct ethtool_coalesce *ec) > > +{ > > + struct virtnet_info *vi = netdev_priv(dev); > > + struct scatterlist sg; > > + struct virtio_net_ctrl_coalesce c; > > + > > + if (!vi->has_cvq || > > + !virtio_has_feature(vi->vdev, VIRTIO_NET_F_CTRL_COALESCE)) > > + retu...