On Thu, 22 Sep 2022 18:13:33 +0800 Hangbin Liu wrote:
quoted
In general I still don't think NLM_F_ECHO makes for a reasonable API.
It may seem okay to those who are willing to write manual netlink
parsers but for a normal programmer the ability to receive directly
notifications resulting from a API call they made is going to mean..
nothing they can have prior experience with. NEWLINK should have
reported the allocated handle / ifindex from the start :(
The "give me back the notifications" semantics match well your use
case to log what the command has done, in that case there is no need
to "return" all the notifications from the API call.
I didn't get what you mean about "no need to return all the notifications from
the API call"? Do you ask for some update of the patch, or just talking about
your propose of NEWLINK?
I'm talking about building "normal programmer" facing libraries on top
of netlink. The concept of ECHO fits very poorly into the normal
request-response semantics.