7fhc8d60gv-65ad...@mail.gmail.com/
Signed-off-by: Daniel Jurgens
---
v3:
- Changed to promisc_allmulti alloc to GPF_KERNEL
v2:
- Added fixes tag.
---
drivers/net/virtio_net.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/net/virtio_net.c b/d
ned-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index 19a9b50646c7..e2b7488f375e 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers/net/virtio_net.c
@@ -2902,14 +2902,14
The rtnl_lock would stay locked if allocating promisc_allmulti failed.
Reported-by: Eric Dumazet
Link:
https://lore.kernel.org/netdev/cann89ilazvaucvhpm6rpjj0owra_ofnx7fhc8d60gv-65ad...@mail.gmail.com/
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 4 ++--
1 file changed, 2
x',
'tx-bytes': 14756682850,
'tx-packets': 226465,
'tx-stop': 113208,
'tx-wake': 113208},
{'ifindex': 13,
'queue-id': 1,
'queue-type': 'tx',
'tx-bytes': 1816767
TX queue stop and wake are counted by some drivers.
Support reporting these via netdev-genl queue stats.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
Documentation/netlink/specs/netdev.yaml | 14 ++
include/net/netdev_queues.h | 3 +++
include/uapi/linux
Several drivers provide TX stop and wake counters via ethtool stats. Add
those to the netdev queue stats, and use them in virtio_net.
v2:
- Fixed an accidental line deletion
- Enhanced documentation
Daniel Jurgens (2):
netdev: Add queue stats for TX stop and wake
virtio_net
The pointer delcaration was missing the __free(kfree).
Fixes: ff7c7d9f5261 ("virtio_net: Remove command data from control_buf")
Reported-by: Jens Axboe
Closes:
https://lore.kernel.org/netdev/0674ca1b-020f-4f93-94d0-104964566...@kernel.dk/
Signed-off-by: Daniel Jurgens
---
d
TX queue stop and wake are counted by some drivers.
Support reporting these via netdev-genl queue stats.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
Documentation/netlink/specs/netdev.yaml | 10 ++
include/net/netdev_queues.h | 3 +++
include/uapi/linux
x',
'tx-bytes': 14756682850,
'tx-packets': 226465,
'tx-stop': 113208,
'tx-wake': 113208},
{'ifindex': 13,
'queue-id': 1,
'queue-type': 'tx',
'tx-bytes': 1816767
Several drivers provide TX stop and wake counters via ethtool stats. Add
those to the netdev queue stats, and use them in virtio_net.
Daniel Jurgens (2):
netdev: Add queue stats for TX stop and wake
virtio_net: Add TX stopped and wake counters
Documentation/netlink/specs/netdev.yaml | 10
The rtnl lock is no longer needed to protect the control buffer and
command VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 24
1 file changed, 4 insertions(+), 20 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers
Once the RTNL locking around the control buffer is removed there can be
contention on the per queue RX interrupt coalescing data. Use a mutex
per queue. A mutex is required because virtnet_send_command can sleep.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 53
Since we no longer have to hold the RTNL lock here just do updates for
the specified queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 40 +++-
1 file changed, 15 insertions(+), 25 deletions(-)
diff --git a/drivers/net/virtio_net.c b
The command VQ will no longer be protected by the RTNL lock. Use a
mutex to protect the control buffer header and the VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 11 ++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/drivers
analysis warning.
- Moved a misplaced hunk to the correct patch.
v2:
- New patch to only process the provided queue in
virtnet_dim_work
- New patch to lock per queue rx coalescing structure.
Daniel Jurgens (6):
virtio_net: Store RSS setting in virtnet_in
Allocate memory for the data when it's used. Ideally the struct could
be on the stack, but we can't DMA stack memory. With this change only
the header and status memory are shared between commands, which will
allow using a tighter lock than RTNL.
Signed-off-by: Daniel Jurgens
Reviewe
Stop storing RSS setting in the control buffer. This is prep work for
removing RTNL lock protection of the control buffer.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 40
1 file changed, 20 insertions(+), 20
Once the RTNL locking around the control buffer is removed there can be
contention on the per queue RX interrupt coalescing data. Use a mutex
per queue. A mutex is required because virtnet_send_command can sleep.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 53
The rtnl lock is no longer needed to protect the control buffer and
command VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 24
1 file changed, 4 insertions(+), 20 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers
Since we no longer have to hold the RTNL lock here just do updates for
the specified queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 40 +++-
1 file changed, 15 insertions(+), 25 deletions(-)
diff --git a/drivers/net/virtio_net.c b
The command VQ will no longer be protected by the RTNL lock. Use a
mutex to protect the control buffer header and the VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 12 ++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/drivers
Stop storing RSS setting in the control buffer. This is prep work for
removing RTNL lock protection of the control buffer.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 40
1 file changed, 20 insertions(+), 20
Allocate memory for the data when it's used. Ideally the could be on the
stack, but we can't DMA stack memory. With this change only the header
and status memory are shared between commands, which will allow using a
tighter lock than RTNL.
Signed-off-by: Daniel Jurgens
Reviewed-by:
of _offloads to __virtio16 to fix static
analysis warning.
- Moved a misplaced hunk to the correct patch.
v2:
- New patch to only process the provided queue in
virtnet_dim_work
- New patch to lock per queue rx coalescing structure.
Daniel Jurgens (6):
virtio
The rtnl lock is no longer needed to protect the control buffer and
command VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 27 +--
1 file changed, 5 insertions(+), 22 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers
Since we no longer have to hold the RTNL lock here just do updates for
the specified queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 40 +++-
1 file changed, 15 insertions(+), 25 deletions(-)
diff --git a/drivers/net/virtio_net.c b
Allocate memory for the data when it's used. Ideally the could be on the
stack, but we can't DMA stack memory. With this change only the header
and status memory are shared between commands, which will allow using a
tighter lock than RTNL.
Signed-off-by: Daniel Jurgens
Reviewed-by:
The command VQ will no longer be protected by the RTNL lock. Use a
spinlock to protect the control buffer header and the VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/net
Once the RTNL locking around the control buffer is removed there can be
contention on the per queue RX interrupt coalescing data. Use a spin
lock per queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 40 +---
1 file changed, 33 insertions
Stop storing RSS setting in the control buffer. This is prep work for
removing RTNL lock protection of the control buffer.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 40
1 file changed, 20 insertions(+), 20
d queue in
virtnet_dim_work
- New patch to lock per queue rx coalescing structure.
Daniel Jurgens (6):
virtio_net: Store RSS setting in virtnet_info
virtio_net: Remove command data from control_buf
virtio_net: Add a lock for the command VQ.
virtio_net: Do DIM update for specified
The rtnl lock is no longer needed to protect the control buffer and
command VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 27 +--
1 file changed, 5 insertions(+), 22 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers
Once the RTNL locking around the control buffer is removed there can be
contention on the per queue RX interrupt coalescing data. Use a spin
lock per queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 23 ---
1 file changed, 16 insertions(+), 7 deletions
Since we no longer have to hold the RTNL lock here just do updates for
the specified queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 40 +++-
1 file changed, 15 insertions(+), 25 deletions(-)
diff --git a/drivers/net/virtio_net.c b
Allocate memory for the data when it's used. Ideally the could be on the
stack, but we can't DMA stack memory. With this change only the header
and status memory are shared between commands, which will allow using a
tighter lock than RTNL.
Signed-off-by: Daniel Jurgens
Reviewed-by:
The command VQ will no longer be protected by the RTNL lock. Use a
spinlock to protect the control buffer header and the VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/net
o the correct patch.
v2:
- New patch to only process the provided queue in
virtnet_dim_work
- New patch to lock per queue rx coalescing structure.
Daniel Jurgens (6):
virtio_net: Store RSS setting in virtnet_info
virtio_net: Remove command data from control_buf
virtio_net
Stop storing RSS setting in the control buffer. This is prep work for
removing RTNL lock protection of the control buffer.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 40
1 file changed, 20 insertions(+), 20
The rtnl lock is no longer needed to protect the control buffer and
command VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 27 +--
1 file changed, 5 insertions(+), 22 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers
Since we no longer have to hold the RTNL lock here just do updates for
the specified queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 38 ++
1 file changed, 14 insertions(+), 24 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers
Allocate memory for the data when it's used. Ideally the could be on the
stack, but we can't DMA stack memory. With this change only the header
and status memory are shared between commands, which will allow using a
tighter lock than RTNL.
Signed-off-by: Daniel Jurgens
Reviewed-by:
Once the RTNL locking around the control buffer is removed there can be
contention on the per queue RX interrupt coalescing data. Use a spin
lock per queue.
Signed-off-by: Daniel Jurgens
---
drivers/net/virtio_net.c | 27 ++-
1 file changed, 18 insertions(+), 9 deletions
scing structure.
Daniel Jurgens (6):
virtio_net: Store RSS setting in virtnet_info
virtio_net: Remove command data from control_buf
virtio_net: Add a lock for the command VQ.
virtio_net: Do DIM update for specified queue only
virtio_net: Add a lock for per queue RX coalesce
virti
The command VQ will no longer be protected by the RTNL lock. Use a
spinlock to protect the control buffer header and the VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/net
Stop storing RSS setting in the control buffer. This is prep work for
removing RTNL lock protection of the control buffer.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 40
1 file changed, 20 insertions(+), 20
The rtnl lock is no longer needed to protect the control buffer and
command VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 27 +--
1 file changed, 5 insertions(+), 22 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers
The command VQ will no longer be protected by the RTNL lock. Use a
spinlock to protect the control buffer header and the VQ.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/net
Allocate memory for the data when it's used. Ideally the could be on the
stack, but we can't DMA stack memory. With this change only the header
and status memory are shared between commands, which will allow using a
tighter lock than RTNL.
Signed-off-by: Daniel Jurgens
Reviewed-by:
Stop storing RSS setting in the control buffer. This is prep work for
removing RTNL lock protection of the control buffer.
Signed-off-by: Daniel Jurgens
Reviewed-by: Jiri Pirko
---
drivers/net/virtio_net.c | 40
1 file changed, 20 insertions(+), 20
ently during normal operation.
This series removes the RNTL lock dependancy by introducing a spin lock
to protect the control buffer and writing SGs to the control VQ.
Daniel Jurgens (4):
virtio_net: Store RSS setting in virtnet_info
virtio_net: Remove command data from control_buf
virtio_net:
> From: Michael S. Tsirkin
> Sent: Wednesday, February 7, 2024 2:19 PM
> To: Daniel Jurgens
> Subject: Re: [PATCH net-next] virtio_net: Add TX stop and wake counters
>
> On Wed, Feb 07, 2024 at 07:38:16PM +0000, Daniel Jurgens wrote:
> > > From: Michael S. Tsirkin
&
> From: Michael S. Tsirkin
> Sent: Sunday, February 4, 2024 6:40 AM
> To: Jason Wang
> Cc: Jakub Kicinski ; Jason Xing
> ; Daniel Jurgens ;
> netdev@vger.kernel.org; xuanz...@linux.alibaba.com;
> virtualizat...@lists.linux.dev; da...@davemloft.net;
> eduma...@google.com;
> From: Jakub Kicinski
> Sent: Friday, February 2, 2024 10:01 AM
> Subject: Re: [PATCH net-next] virtio_net: Add TX stop and wake counters
>
> On Fri, 2 Feb 2024 14:52:59 +0800 Jason Xing wrote:
> > > Can you say more? I'm curious what's your use case.
> >
> > I'm not working at Nvidia, so my poi
> From: Michael S. Tsirkin
> Sent: Tuesday, January 30, 2024 9:53 AM
> On Tue, Jan 30, 2024 at 03:50:29PM +0000, Daniel Jurgens wrote:
> > > From: Michael S. Tsirkin
> > > Sent: Tuesday, January 30, 2024 9:42 AM On Tue, Jan 30, 2024 at
> > > 03:40:21PM +,
> From: Michael S. Tsirkin
> Sent: Tuesday, January 30, 2024 9:42 AM
> On Tue, Jan 30, 2024 at 03:40:21PM +0000, Daniel Jurgens wrote:
> > > From: Michael S. Tsirkin
> > > Sent: Tuesday, January 30, 2024 8:58 AM
> > >
> > > On Tue, Jan 30, 2
> From: Heng Qi
> Sent: Tuesday, January 30, 2024 9:17 AM
> 在 2024/1/30 下午10:25, Daniel Jurgens 写道:
> > Add a tx queue stop and wake counters, they are useful for debugging.
> >
> > $ ethtool -S ens5f2 | grep 'tx_stop\|tx_wake'
> >
> From: Michael S. Tsirkin
> Sent: Tuesday, January 30, 2024 8:58 AM
>
> On Tue, Jan 30, 2024 at 08:25:21AM -0600, Daniel Jurgens wrote:
> > Add a tx queue stop and wake counters, they are useful for debugging.
> >
> > $ ethtool -S e
10
Signed-off-by: Daniel Jurgens
Reviewed-by: Parav Pandit
---
drivers/net/virtio_net.c | 26 --
1 file changed, 24 insertions(+), 2 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index 3cb8aa193884..7e3c31ceaf7e 100644
--- a/drivers/net/vi
On 3/28/2017 4:11 AM, Saeed Mahameed wrote:
> On Tue, Mar 28, 2017 at 2:45 AM, Goel, Sameer wrote:
>> Stack frame:
>> [ 1744.418958] [] get_nic_state+0x24/0x40 [mlx5_core]
>> [ 1744.425273] [] health_recover+0x28/0x80 [mlx5_core]
>> [ 1744.431496] [] process_one_work+0x150/0x460
>> [ 1744.437218]
On 2/1/2017 5:12 AM, David Laight wrote:
> From: Saeed Mahameed
>> Sent: 31 January 2017 20:59
>> From: Daniel Jurgens
>>
>> There is a hardware feature that will pad the start or end of a DMA to
>> be cache line aligned to avoid RMWs on the last cache line. The d
On 1/16/2017 3:59 PM, Or Gerlitz wrote:
> On Mon, Jan 16, 2017 at 11:54 PM, Daniel Jurgens wrote:
>> On 1/16/2017 3:44 PM, Or Gerlitz wrote:
>>> On Mon, Jan 16, 2017 at 7:29 PM, Tariq Toukan wrote:
>>>> From: Daniel Jurgens
>>>>
>>>> Use CPU
On 1/16/2017 3:44 PM, Or Gerlitz wrote:
> On Mon, Jan 16, 2017 at 7:29 PM, Tariq Toukan wrote:
>> From: Daniel Jurgens
>>
>> Use CPUs on the close NUMA when setting the EQ affinity hints.
> Dan, are we sure there are no down-sides for always doing this? this
> code
62 matches
Mail list logo