Re: [PATCH 2/4] tools: ynl-gen-c: optionally emit structs and helpers
From: Christoph Böhmwalder <christoph.boehmwalder@linbit.com>
Date: 2026-05-04 09:06:01
Also in:
linux-block, lkml
From: Christoph Böhmwalder <christoph.boehmwalder@linbit.com>
Date: 2026-05-04 09:06:01
Also in:
linux-block, lkml
On Tue, Apr 14, 2026 at 08:35:48AM -0700, Jakub Kicinski wrote:
On Tue, 14 Apr 2026 14:08:58 +0200 Christoph Böhmwalder wrote:quoted
But we still need to support the current family via a compat path, and I would much rather have two YNL-based families than one genl_magic and one YNL-based. Carrying both sounds like a nightmare. So the spec proposed in this series would never actually be used to generate a userspace client, if that's what you're asking. We would continue to use the current libgenl-based approach, with some userspace compat shims to make it work with YNL. Then, when "drbd2" comes along, we could "do things properly".Let's jump to the drbd2 work.
We have a bit of a chicken-egg situation there. The drbd2 work depends on the DRBD 9 upstreaming series, since the drbd2 netlink family will use the new DRBD 9 semantics. However, the DRBD 9 series depends on the current DRBD module already using YNL (or rather, *not* using genl_magic anymore). Our plan is to convert the current family to YNL in-place first, then incrementally add the new modern drbd2 family with DRBD 9 semantics in another series. How would you prefer to handle the YNL switch? If it makes it easier for you, just committing the YNL-generated code without the generator is fine for me. The old family is effectively frozen, so that would work. Thanks, Christoph