[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250620172949.1525075a@sal.lan>
Date: Fri, 20 Jun 2025 17:31:29 +0200
From: Mauro Carvalho Chehab <mchehab+huawei@...nel.org>
To: Jonathan Corbet <corbet@....net>
Cc: Jakub Kicinski <kuba@...nel.org>, Donald Hunter
<donald.hunter@...il.com>, Linux Doc Mailing List
<linux-doc@...r.kernel.org>, Akira Yokosawa <akiyks@...il.com>, Breno
Leitao <leitao@...ian.org>, "David S. Miller" <davem@...emloft.net>, Eric
Dumazet <edumazet@...gle.com>, Jan Stancek <jstancek@...hat.com>, Marco
Elver <elver@...gle.com>, Paolo Abeni <pabeni@...hat.com>, Ruben Wauters
<rubenru09@....com>, Shuah Khan <skhan@...uxfoundation.org>,
joel@...lfernandes.org, linux-kernel-mentees@...ts.linux.dev,
linux-kernel@...r.kernel.org, lkmm@...ts.linux.dev, netdev@...r.kernel.org,
peterz@...radead.org, stern@...land.harvard.edu
Subject: Re: [PATCH v4 12/14] MAINTAINERS: add maintainers for
netlink_yml_parser.py
Em Thu, 19 Jun 2025 14:06:58 -0600
Jonathan Corbet <corbet@....net> escreveu:
> Jakub Kicinski <kuba@...nel.org> writes:
>
> > On Sat, 14 Jun 2025 20:56:09 +0200 Mauro Carvalho Chehab wrote:
>
> >> I'm more interested on having a single place where python libraries
> >> could be placed.
> >
> > Me too, especially for selftests. But it's not clear to me that
> > scripts/ is the right location. I thought purely user space code
> > should live in tools/ and bulk of YNL is for user space.
>
> I've been out wandering the woods and canyons with no connectivity for a
> bit, so missed this whole discussion, sorry.
Sounds fun!
> Mauro and I had talked about the proper home for Python libraries when
> he reworked kernel-doc; we ended up with them under scripts/, which I
> didn't find entirely pleasing. If you were to ask me today, I'd say
> they should be under lib/python, but tomorrow I might say something
> else...
Yeah, I guess you proposed lib/python before... I could be wrong though.
Anyway, at least for me lib/python sounds a better alternative than
scripts. I won't mind tools/lib/python or some other place.
> In truth, I don't think it matters much, but I *do* think we should have
> a single location from which to import kernel-specific Python code.
> Spreading it throughout the tree just isn't going to lead to joy.
We're aligned with that regards: IMO, we need a single store within
the Kernel for classes that might be shared.
As I commented on one of PRs, maybe the series could be merged
with Donald proposed (tools/net/ynl/pyynl/lib/doc_generator.py),
while we're still discussing. So, let's focus on get it reviewed
and merged without needing to wait for a broader discussion
about its permanent location.
We can later shift the code once we reach an agreement.
-
To start the discussions about a permanent location, in the specific
case of YNL, we currently have there:
$ tree -d tools/net/ynl/ -I __pycache__
tools/net/ynl/
├── generated
├── lib
├── pyynl
│ └── lib
└── samples
where pyynl have executables and pyynl the python libraries.
what I would suggest is to move what it is under "pyynl/lib"
to "{prefix}/ynl", where "{prefix}" can be "lib/python",
"tools/lib/python", "scripts/lib" or whatever other location
we reach an agreement.
For now, I placed the latest version of my doc patch series
under:
https://github.com/mchehab/linux/tree/netlink_v8
to have a central place to have them on one of my scratch
trees.
I sent today for review to linux-doc ML an initial patch series
with some non-YAML related patches. I have another set of
patches after it, which I'm planning to send on Monday. At the
end, there are the YAML parser submission.
Regards,
Mauro
Powered by blists - more mailing lists