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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5c59cc11-f6b3-3ac2-d26f-9470f57d7570@intel.com>
Date:   Tue, 19 Sep 2023 13:10:34 +0200
From:   Przemek Kitszel <przemyslaw.kitszel@...el.com>
To:     Anthony Nguyen <anthony.l.nguyen@...el.com>
CC:     <netdev@...r.kernel.org>, Steven Zou <steven.zou@...el.com>,
        <edumazet@...gle.com>, David Laight <David.Laight@...lab.com>,
        <intel-wired-lan@...ts.osuosl.org>,
        <linux-hardening@...r.kernel.org>,
        "Jakub Kicinski" <kuba@...nel.org>, <pabeni@...hat.com>,
        <davem@...emloft.net>, "Kees Cook" <keescook@...omium.org>,
        "Brandeburg, Jesse" <jesse.brandeburg@...el.com>
Subject: Re: [Intel-wired-lan] [PATCH net-next v5 0/7] introduce DEFINE_FLEX()
 macro

On 9/12/23 18:16, Kees Cook wrote:
> On Tue, Sep 12, 2023 at 07:59:30AM -0400, Przemek Kitszel wrote:
>> Add DEFINE_FLEX() macro, that helps on-stack allocation of structures
>> with trailing flex array member.
>> Expose __struct_size() macro which reads size of data allocated
>> by DEFINE_FLEX().
>>
>> Accompany new macros introduction with actual usage,
>> in the ice driver - hence targeting for netdev tree.
>>
>> Obvious benefits include simpler resulting code, less heap usage,
>> less error checking. Less obvious is the fact that compiler has
>> more room to optimize, and as a whole, even with more stuff on the stack,
>> we end up with overall better (smaller) report from bloat-o-meter:
>> add/remove: 8/6 grow/shrink: 7/18 up/down: 2211/-2270 (-59)
>> (individual results in each patch).
>>
>> v5: same as v4, just not RFC
>> v4: _Static_assert() to ensure compiletime const count param
>> v3: tidy up 1st patch
>> v2: Kees: reusing __struct_size() instead of doubling it as a new macro
>>
>> Przemek Kitszel (7):
>>    overflow: add DEFINE_FLEX() for on-stack allocs
>>    ice: ice_sched_remove_elems: replace 1 elem array param by u32
>>    ice: drop two params of ice_aq_move_sched_elems()
>>    ice: make use of DEFINE_FLEX() in ice_ddp.c
>>    ice: make use of DEFINE_FLEX() for struct ice_aqc_add_tx_qgrp
>>    ice: make use of DEFINE_FLEX() for struct ice_aqc_dis_txq_item
>>    ice: make use of DEFINE_FLEX() in ice_switch.c
> 
> Looks good to me! Feel free to pick up via netdev.
> 
> -Kees
> 

Thanks!

Patchwork [1] says it's "Awaiting Upstream", which is the same for most 
of the "to: IWL" patches. That means it's delegated to Tony?

By any means, minimizing "usage examples" to just ice driver makes it 
easy to merge via Tony's tree.

[1] 
https://patchwork.kernel.org/project/netdevbpf/patch/20230912115937.1645707-2-przemyslaw.kitszel@intel.com/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ