Re: [PATCH net-next v2] tap: report IFF_DETACH_QUEUE in TUNGETIFF

From: Umang Pokhriyal

Date: Mon Oct 05 2026 - 02:15:20 EST


Willem de Bruijn wrote:
> I suppose we want tap to expose this state through TUNGETIFF, like tun,
> because applications already use that?

Yes. CRIU reads IFF_DETACH_QUEUE from TUNGETIFF when it dumps a tun
file, and Cloud Hypervisor did the same until it found that macvtap
reports every queue as attached. Code written for tun's queue API gets
the wrong answer on macvtap, even though macvtap accepts the same
TUNSETQUEUE.

> Else cleaner than working around bits would be a whole new TUNGETQUEUE
> call to match TUNSETQUEUE. Rather than to squish this into TUNGETIFF,
> while that has no equivalent in TUNSETIFF.
>
> But, that approach does not help existing applications.

Right, those applications would have to be changed to use a new
TUNGETQUEUE.

Thanks for taking another look.