Subject: Re: [RFC net-next v2 5/5] net:openvswitch: add psample support

From: Jakub Kicinski <[email-masked]>
Date: Tue, 9 Apr 2024 14:49:47 -0700

On Tue, 9 Apr 2024 11:35:04 +0200 Ilya Maximets wrote:
> > If we try to implement all our actions following this way, and we keep just 
> > copying the incoming actions into the internal representation, we incur in 
> > unnecessary memory overhead (e.g: storing 2x struct nlaattr + padding of extra 
> > memory to store 2 integers).
> > 
> > I don't want to derail the discussion into historical or futuristic changes, 
> > just saying that the approach taken in the SAMPLE action (not including this 
> > patch) of exposing arguments as attributes but having a kernel-only struct to 
> > store them seems to me a good compromise.  
> 
> Sure.  As I said, it's fine to have internal structures.  My comment
> was mainly about uAPI part.  We should avoid structures in uAPI if
> possible, as they are very hard to maintain and keep compatible with
> older userspace in case some changes will be needed in the future.

FWIW there are some YAML specs for ovs under
Documentation/netlink/specs/ovs_*
perhaps they should also be updated?