Re: [patch net-next v2 10/11] devlink: introduce dump selector attr and use it for per-instance dumps
From: Jiri Pirko <jiri@resnulli.us>
Date: 2023-08-02 07:02:35
From: Jiri Pirko <jiri@resnulli.us>
Date: 2023-08-02 07:02:35
Tue, Aug 01, 2023 at 05:53:01PM CEST, kuba@kernel.org wrote:
On Tue, 1 Aug 2023 08:42:09 +0200 Jiri Pirko wrote:quoted
quoted
quoted
quoted
Also - do you know of any userspace which would pass garbage attrs to the dumps? Do we really need to accept all attributes, or can we trim the dump policies to what's actually supported?That's what this patch is doing. It only accepts what the kernel understands. It gives the object types (as for example health reporter) option to extend the attr set to accept them into selectors as well, if they know how to handle them.I'm talking about the "outer" policy, the level at which DEVLINK_ATTR_DUMP_SELECTOR is defined.I don't follow :/ Could you please describe what exactly do you mean and want to see? Thanks!It's a bit obscured by the macros, but AFAICT you pass devlink_nl_policy for the dumps, while the _only_ attribute the kernel will interpret is DEVLINK_ATTR_DUMP_SELECTOR and its insides.
True, you are correct. Anyway with the split ops generation, this is going to be narrowed down, so possiblem garbage is ignored. Thanks!