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: <Y9y/rfqIZg3oaBnq@nanopsycho>
Date:   Fri, 3 Feb 2023 09:02:53 +0100
From:   Jiri Pirko <jiri@...nulli.us>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     Moshe Shemesh <moshe@...dia.com>,
        "David S. Miller" <davem@...emloft.net>,
        Jiri Pirko <jiri@...dia.com>, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next 7/7] devlink: Move devlink dev selftest code to
 dev

Thu, Feb 02, 2023 at 08:46:21PM CET, kuba@...nel.org wrote:
>On Thu, 2 Feb 2023 21:33:52 +0200 Moshe Shemesh wrote:
>> On 02/02/2023 20:17, Jakub Kicinski wrote:
>> > On Thu, 2 Feb 2023 16:47:06 +0200 Moshe Shemesh wrote:  
>> >> Move devlink dev selftest callbacks and related code from leftover.c to
>> >> file dev.c. No functional change in this patch.  
>> > selftest I'd put in its own file. We don't want every command which
>> > doesn't have a specific sub-object to end up in dev.c, right?
>> > At least that was my initial thinking. I don't see any dependencies
>> > between the selftest code and the rest of the dev code either.
>> > WDYT?  
>> 
>> I thought as it is devlink dev selftest, the sub-object is dev. 
>> Otherwise, what should be the rule here ?
>> 
>> How do we decide if it should get its own file ?
>
>My thinking was that it should be much easier for newcomers to grok
>"what does it take to implement a devlink command" if most of the
>subcommands where in their own files, like in ethtool.
>
>The implementation could have as well made selftest a subobject.
>But I don't feel strongly, if noone agrees we can apply as is and 
>see if dev.c does indeed start to grow out of proportion.

I think that per-object separation is good for now. I see no point of
having per-cmd files of sometimes 50 lines. IDK. No strong opinion.
I would start with per-object.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ