David Ahern <dsahern@xxxxxxxxxx> writes: > On 4/7/25 3:15 AM, Toke Høiland-Jørgensen wrote: >>> +static inline bool txq_has_qdisc(struct netdev_queue *txq) >>> +{ >>> + struct Qdisc *q; >>> + >>> + q = rcu_dereference(txq->qdisc); >>> + if (q->enqueue) >>> + return true; >>> + else >>> + return false; >>> +} >> >> This seems like a pretty ugly layering violation, inspecting the qdisc >> like this in the driver? > > vrf driver has something very similar - been there since March 2017. Doesn't make it any less ugly, though ;) And AFAICT, vrf is doing more with the information; basically picking a whole different TX path? Can you elaborate on the reasoning for this (do people actually install qdiscs on VRF devices in practice)? -Toke