[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZN+0RCxWBL74Ff+C@nanopsycho>
Date: Fri, 18 Aug 2023 20:11:16 +0200
From: Jiri Pirko <jiri@...nulli.us>
To: Jakub Kicinski <kuba@...nel.org>
Cc: netdev@...r.kernel.org
Subject: Re: ynl - mutiple policies for one nested attr used in multiple cmds
Fri, Aug 18, 2023 at 05:55:35PM CEST, kuba@...nel.org wrote:
>On Fri, 18 Aug 2023 10:37:19 +0200 Jiri Pirko wrote:
>> >I'm not sure if you'll like it but my first choice would be to skip
>> >the selector attribute. Put the attributes directly into the message.
>> >There is no functional purpose the wrapping serves, right?
>>
>> I have another variation of a similar problem.
>> There might be a different policy for nested attribute for get and set.
>> Example nest: DEVLINK_ATTR_PORT_FUNCTION
>>
>> Any suggestion how to resolve this?
>
>You mean something like:
>
>GET:
> [NEST_X]
> [ATTR_A]
> [ATTR_B]
>
>GET:
> [NEST_X]
> [ATTR_A]
> [ATTR_C]
>
>Where ATTR_A, ATTR_B and ATTR_C are from the same set but depending
>on the command the nest can either contain A,C or A,B?
>
>That can happen in legit ways :( I don't have a good solution for it.
More precisely, it is:
GET:
[NEST_X]
[ATTR_A]
[ATTR_B]
[ATTR_C]
[ATTR_D]
SET:
[NEST_X]
[ATTR_A]
[ATTR_C]
Okay, you don't have good solution, do you have at least the least bad
one? :)
Powered by blists - more mailing lists