On Thu,  3 Oct 2019 11:49:26 +0200, Jiri Pirko wrote:
> From: Jiri Pirko <j...@mellanox.com>
> 
> Currently, the accounting is done per-namespace. However, devlink
> instance is always in init_net namespace for now, so only the accounting
> related to init_net is used. Limitations set using devlink resources
> are only considered for init_net. nsim_devlink_net() always
> returns init_net always.
> 
> Make the accounting per-device. This brings no functional change.
> Per-device accounting has the same values as per-net.
> For a single netdevsim instance, the behaviour is exactly the same
> as before. When multiple netdevsim instances are created, each
> can have different limits.
> 
> This is in prepare to implement proper devlink netns support. After
> that, the devlink instance which would exist in particular netns would
> account and limit that netns.
> 
> Signed-off-by: Jiri Pirko <j...@mellanox.com>

Acked-by: Jakub Kicinski <jakub.kicin...@netronome.com>

Reply via email to