[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230801194949.GC53714@unreal>
Date: Tue, 1 Aug 2023 22:49:49 +0300
From: Leon Romanovsky <leon@...nel.org>
To: Jakub Kicinski <kuba@...nel.org>
Cc: Lin Ma <linma@....edu.cn>, davem@...emloft.net, edumazet@...gle.com,
pabeni@...hat.com, fw@...len.de, yang.lee@...ux.alibaba.com,
jgg@...pe.ca, markzhang@...dia.com, phaddad@...dia.com,
yuancan@...wei.com, ohartoov@...dia.com, chenzhongjin@...wei.com,
aharonl@...dia.com, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-rdma@...r.kernel.org
Subject: Re: [PATCH net v1 1/2] netlink: let len field used to parse
type-not-care nested attrs
On Tue, Aug 01, 2023 at 10:57:26AM -0700, Jakub Kicinski wrote:
> On Tue, 1 Aug 2023 11:11:17 +0300 Leon Romanovsky wrote:
> > IMHO, you are lowering too much the separation line between simple vs.
> > advanced use cases.
> >
> > I had no idea that my use-case of passing nested netlink array is counted
> > as advanced usage.
>
> Agreed, that's a fair point. I'm guessing it was inspired by the
> ethtool stats? (Which in hindsight were a mistake on my part.)
I don't remember which part of kernel can be blamed for it. :)
>
> For the longest time there was no docs or best practices for netlink.
> We have the documentation and more infrastructure in place now.
> I hope if you wrote the code today the distinction would have been
> clearer.
>
> If we start adding APIs for various one-(two?)-offs from the past
> we'll never dig ourselves out of the "no idea what's the normal use
> of these APIs" hole..
I agree with this sentence, just afraid that it is unrealistic goal, due
to extensive flexibility in netlink UAPI toward user-space, which allows
you to shoot yourself in the foot without even noticing it.
Thanks
Powered by blists - more mailing lists