On Wed, Mar 27, 2019 at 1:11 PM Marc Kleine-Budde <mkl@xxxxxxxxxxxxxx> wrote: > Doubts aside, how should an arbitrary default qdisc per netdevice look > like? Add a string "default_qdisc" to the netdev? Lookup qdisc by string > during DOWN->UP transition? What do if that qdisc is not compiled into > the kernel? Or rather use an array of qdiscs with one of sch_generic > defaults? I think you can just save a Qdisc_ops pointer in netdevice, like how we install the default qdisc: 38 const struct Qdisc_ops *default_qdisc_ops = &pfifo_fast_ops; 39 EXPORT_SYMBOL(default_qdisc_ops); And hard-code whatever default into your netdevice init code. At least for pfifo_fast, you don't need to worry about module loading. If you really do, you can call qdisc_lookup_default() and request_module() like what qdisc_set_default() does. Of course, you can refactor qdisc_set_default() and call it too. Thanks.