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]
Date: Thu, 14 Dec 2023 13:08:49 +0000
From: "Romanowski, Rafal" <rafal.romanowski@...el.com>
To: "Brandeburg, Jesse" <jesse.brandeburg@...el.com>,
	"intel-wired-lan@...ts.osuosl.org" <intel-wired-lan@...ts.osuosl.org>
CC: "Kitszel, Przemyslaw" <przemyslaw.kitszel@...el.com>, "Brandeburg, Jesse"
	<jesse.brandeburg@...el.com>, "Zaki, Ahmed" <ahmed.zaki@...el.com>, "Julia
 Lawall" <Julia.Lawall@...ia.fr>, "Lobakin, Aleksander"
	<aleksander.lobakin@...el.com>, "marcin.szycik@...ux.intel.com"
	<marcin.szycik@...ux.intel.com>, "horms@...nel.org" <horms@...nel.org>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: RE: [Intel-wired-lan] [PATCH iwl-next v2 05/15] iavf: field prep
 conversion

> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf Of
> Jesse Brandeburg
> Sent: Wednesday, December 6, 2023 2:01 AM
> To: intel-wired-lan@...ts.osuosl.org
> Cc: Kitszel, Przemyslaw <przemyslaw.kitszel@...el.com>; Brandeburg, Jesse
> <jesse.brandeburg@...el.com>; Zaki, Ahmed <ahmed.zaki@...el.com>; Julia
> Lawall <Julia.Lawall@...ia.fr>; Lobakin, Aleksander
> <aleksander.lobakin@...el.com>; marcin.szycik@...ux.intel.com;
> horms@...nel.org; netdev@...r.kernel.org
> Subject: [Intel-wired-lan] [PATCH iwl-next v2 05/15] iavf: field prep
> conversion
> 
> Refactor iavf driver to use FIELD_PREP(), which reduces lines of code and adds
> clarity of intent.
> 
> This code was generated by the following coccinelle/spatch script and then
> manually repaired.
> 
> Clean up a couple spots in the code that had repetitive y = cpu_to_*((blah <<
> blah_blah) & blat) y |= cpu_to_*((blahs << blahs_blahs) & blats) to x =
> FIELD_PREP(blat blah) x |= FIELD_PREP(blats, blahs) y = cpu_to_*(x);
> 
> @prep2@
> constant shift,mask;
> type T;
> expression a;
> @@
> -(((T)(a) << shift) & mask)
> +FIELD_PREP(mask, a)
> 
> @prep@
> constant shift,mask;
> type T;
> expression a;
> @@
> -((T)((a) << shift) & mask)
> +FIELD_PREP(mask, a)
> 
> Cc: Julia Lawall <Julia.Lawall@...ia.fr>
> Cc: Ahmed Zaki <ahmed.zaki@...el.com>
> Reviewed-by: Marcin Szycik <marcin.szycik@...ux.intel.com>
> Reviewed-by: Simon Horman <horms@...nel.org>
> Signed-off-by: Jesse Brandeburg <jesse.brandeburg@...el.com>
> ---
> v2: updated commit message
> ---
>  drivers/net/ethernet/intel/iavf/iavf_common.c | 31 ++++++++-----------
>  drivers/net/ethernet/intel/iavf/iavf_fdir.c   |  2 +-
>  2 files changed, 14 insertions(+), 19 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/iavf/iavf_common.c
> b/drivers/net/ethernet/intel/iavf/iavf_common.c
> index af5cc69f26e3..5a25233a89d5 100644
> --- a/drivers/net/ethernet/intel/iavf/iavf_common.c
> +++ b/drivers/net/ethernet/intel/iavf/iavf_common.c
> @@ -331,6 +331,7 @@ static enum iavf_status


Tested-by: Rafal Romanowski <rafal.romanowski@...el.com>



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ