lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <6eb6b171-31f5-4c30-aab6-277f32d48678@fiberby.net>
Date: Thu, 20 Nov 2025 19:49:08 +0000
From: Asbjørn Sloth Tønnesen <ast@...erby.net>
To: "Jason A. Donenfeld" <Jason@...c4.com>, Jakub Kicinski <kuba@...nel.org>
Cc: Donald Hunter <donald.hunter@...il.com>,
 "David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
 Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>,
 Jacob Keller <jacob.e.keller@...el.com>, Andrew Lunn
 <andrew+netdev@...n.ch>, wireguard@...ts.zx2c4.com, netdev@...r.kernel.org,
 linux-kernel@...r.kernel.org, Jordan Rife <jordan@...fe.io>
Subject: Re: [PATCH net-next v3 11/11] wireguard: netlink: generate netlink
 code

On 11/20/25 12:54 AM, Jason A. Donenfeld wrote:
> On Tue, Nov 18, 2025 at 05:00:45PM -0800, Jakub Kicinski wrote:
>> On Tue, 18 Nov 2025 23:51:37 +0100 Jason A. Donenfeld wrote:
>>> I mean, there is *tons* of generated code in the kernel. This is how it
>>> works. And you *want the output to change when the tool changes*. That's
>>> literally the point. It would be like if you wanted to check in all the
>>> .o files, in case the compiler started generating different output, or
>>> if you wanted the objtool output or anything else to be checked in. And
>>> sheerly from a git perspective, it seems outrageous to touch a zillion
>>> files every time the ynl code changes. Rather, the fact that it's
>>> generated on the fly ensures that the ynl generator stays correctly
>>> implemented. It's the best way to keep that code from rotting.
>>
>> CI checks validate that the files are up to date.
>> There has been no churn to the kernel side of the generated code.
>> Let's be practical.
> 
> Okay, it sounds like neither of you want to do this. Darn. I really hate
> having generated artifacts laying around that can be created efficiently
> at compile time. But okay, so it goes. I guess we'll do that.

I generally agree, but given this generates code across the tree, then I
prefer this, as side-effects are more obvious.

To complete Jakub's earlier argument of not complicating everyone's life,
then this code generator is Python-based and depends on yaml and jsonschema.
Even doing compile-time generation for a single family, would elevate those
packages from developer-dependencies to build-dependencies.

> I would like to ask two things, then, which may or may not be possible:
> 
> 1) Can we put this in drivers/net/wireguard/generated/netlink.{c.h}
>     And then in the Makefile, do `wireguard-y += netlink.o generated/netlink.o`
>     on one line like that. I prefer this to keeping it in the same
>     directory with the awkward -gen suffix.

Sure, there isn't much consistency across families anyway.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ