# Re: \[PATCH net-next v7 0/5\] veth: add Byte Queue Limits (BQL) support

- From: Simon Schippers \<hidden\>
- Date: 2026-09-15 14:31:24 
- List: netdev
- Page: https://ratatoskr.run/netdev/2026/09/17580216
- Thread: https://ratatoskr.run/netdev/2026/06/17124126/t.md

```text
On 8/10/26 15:25, Simon Schippers wrote:
> On 6/12/26 10:35, hawk@kernel.org wrote:
>> From: Jesper Dangaard Brouer <hawk@kernel.org>
>>
>> This series adds BQL (Byte Queue Limits) to the veth driver, reducing
>> latency by dynamically limiting in-flight packets in the ptr_ring and
>> moving buffering into the qdisc where AQM algorithms can act on it.
> 
> Hi :)
> 
> I worked on my implementation of DQL coalescing that lives in
> dynamic_queue_limits.{h,c} and wanted to share it so we can consider it
> for the next cycle. This is because in the next cycle I would
> like to add BQL support for tun/tap as well, in addition to veth.
> Is that fine for you?
> 
> I think it is in good shape. It uses the same logic as the v7, but
> every new field fits inside the existing dql struct, and drivers only
> need to call the usual netdev_tx_sent_queue() and
> netdev_tx_completed_queue() to use it. Patch 3, 5 and 6 are the same
> as before, only 1, 2 and 4 are new. Benchmarks looked fine for me.
> 
> There should be no regressions for other DQL/BQL users. I paid close
> attention not to break the dql cache lines or other logic.
> coal_usecs is now configurable per queue via sysfs and also via ethtool
> as usual.
> 
> While working on this, I found a missing barrier in v7:
> There was no smp_rmb() pairing the smp_wmb() in __ptr_ring_produce()
> before dql_completed() reads dql->num_queued. This happens to be safe
> on x86, but on other platforms the read of dql->num_queued could be
> reordered before __ptr_ring_consume(), triggering a BUG_ON() in
> dql_completed(). Fixed by adding the missing smp_rmb() in veth_xdp_rcv()
> before completing.
> 
> Would love to hear your thoughts on the implementation!
> 
> Thanks,
> Simon

Hi! Any thoughts on this? Do you want to continue this series?

Thanks!

```
