netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* ynl - mutiple policies for one nested attr used in multiple cmds
@ 2023-08-04 17:29 Jiri Pirko
  2023-08-04 19:58 ` Jakub Kicinski
  0 siblings, 1 reply; 12+ messages in thread
From: Jiri Pirko @ 2023-08-04 17:29 UTC (permalink / raw)
  To: kuba; +Cc: netdev

Hi Kuba.

I need to have one nested attribute but according to what cmd it is used
with, there will be different nested policy.

If I'm looking at the codes correctly, that is not currenly supported,
correct?

If not, why idea how to format this in yaml file?
Pehaps something like:

      -
        name: dump-selector
        type: nest
        nested-attributes: dl-dump-selector

  -
    name: dl-dev-dump-selector
    subset-of: devlink
    attributes:
      -
        name: bus-name
        type: string
      -
        name: dev-name
        type: string

  -
    name: dl-port-dump-selector
    subset-of: devlink
    attributes:
      -
        name: bus-name
        type: string
      -
        name: dev-name
        type: string
      -
        name: port-index
	type: u32

And then:
      dump:
        pre: devlink-nl-start
        post: devlink-nl-done
        request:
          attributes:
            - dump-selector@dl-dev-dump-selector
...
      dump:
        pre: devlink-nl-start
        post: devlink-nl-done
        request:
          attributes:
            - dump-selector@dl-port-dump-selector

Idk, looks a bit odd though to parse the attr strings.

Any idea?

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2023-08-21 11:16 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-04 17:29 ynl - mutiple policies for one nested attr used in multiple cmds Jiri Pirko
2023-08-04 19:58 ` Jakub Kicinski
2023-08-05  6:33   ` Jiri Pirko
2023-08-07 17:03     ` Jakub Kicinski
2023-08-07 17:12       ` Jiri Pirko
2023-08-07 17:24         ` Jakub Kicinski
2023-08-08  7:38           ` Jiri Pirko
2023-08-18  8:37   ` Jiri Pirko
2023-08-18 15:55     ` Jakub Kicinski
2023-08-18 18:11       ` Jiri Pirko
2023-08-18 20:24         ` Jakub Kicinski
2023-08-21 11:16           ` Jiri Pirko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).