lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YwiChaPfZKkAK/c4@nanopsycho>
Date:   Fri, 26 Aug 2022 10:21:25 +0200
From:   Jiri Pirko <jiri@...nulli.us>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     netdev@...r.kernel.org, davem@...emloft.net, pabeni@...hat.com,
        edumazet@...gle.com, andrew@...n.ch, vivien.didelot@...il.com,
        f.fainelli@...il.com, olteanv@...il.com, tariqt@...dia.com,
        moshe@...dia.com, saeedm@...dia.com
Subject: Re: [patch net-next 0/7] devlink: sanitize per-port region
 creation/destruction

Fri, Aug 26, 2022 at 12:01:32AM CEST, kuba@...nel.org wrote:
>On Thu, 25 Aug 2022 12:33:53 +0200 Jiri Pirko wrote:
>> Currently the only user of per-port devlink regions is DSA. All drivers
>> that use regions register them before devlink registration. For DSA,
>> this was not possible as the internals of struct devlink_port needed for
>> region creation are initialized during port registration.
>> 
>> This introduced a mismatch in creation flow of devlink and devlink port
>> regions. As you can see, it causes the DSA driver to make the port
>> init/exit flow a bit cumbersome.
>> 
>> Fix this by introducing port_init/fini() which could be optionally
>> called by drivers like DSA, to prepare struct devlink_port to be used
>> for region creation purposes before devlink port register is called.
>> 
>> Force similar limitation as for devlink params and disallow to create
>> regions after devlink or devlink port are registered. That allows to
>> simplify the devlink region internal API to not to rely on
>> devlink->lock.
>
>The point of exposing the devlink lock was to avoid forcing drivers 
>to order object registration in a specific way. I don't like.

Well for params, we are also forcing them in a specific way. The
regions, with the DSA exception which is not voluntary, don't need to be
created/destroyed during devlink/port being registered.

I try to bring some order to the a bit messy devlink world. The
intention is to make everyone's live happier :)

>
>Please provide some solid motivation here 'cause if it's you like vs 
>I like...
>
>Also the patches don't apply.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ