[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <m2ldqwn7oe.fsf@gmail.com>
Date: Fri, 16 May 2025 11:58:41 +0100
From: Donald Hunter <donald.hunter@...il.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: davem@...emloft.net, netdev@...r.kernel.org, edumazet@...gle.com,
pabeni@...hat.com, andrew+netdev@...n.ch, horms@...nel.org,
daniel@...earbox.net, nicolas.dichtel@...nd.com,
jacob.e.keller@...el.com
Subject: Re: [PATCH net-next 7/9] tools: ynl: submsg: reverse parse / error
reporting
Jakub Kicinski <kuba@...nel.org> writes:
> Reverse parsing lets YNL convert bad and missing attr pointers
> from extack into a string like "missing attribute nest1.nest2.attr_name".
> It's a feature that's unique to YNL C AFAIU (even the Python YNL
> can't do nested reverse parsing). Add support for reverse-parsing
> of sub-messages.
>
> To simplify the logic and the code annotate the type policies
> with extra metadata. Mark the selectors and the messages with
> the information we need. We assume that key / selector always
> precedes the sub-message while parsing (and also if there are
> multiple sub-messages like in rt-link they are interleaved
> selector 1 ... submsg 1 ... selector 2 .. submsg 2, not
> selector 1 ... selector 2 ... submsg 1 ... submsg 2).
>
> The rt-link sample in a subsequent changes shows reverse parsing
> of sub-messages in action.
>
> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
Reviewed-by: Donald Hunter <donald.hunter@...il.com>
Powered by blists - more mailing lists