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] [day] [month] [year] [list]
Message-ID: <CY8PR11MB7195A879FEDD0AA7BF0566FB9794A@CY8PR11MB7195.namprd11.prod.outlook.com>
Date: Fri, 22 Dec 2023 18:32:06 +0000
From: "Register, Scott" <scott.register@...el.com>
To: "Linga, Pavan Kumar" <pavan.kumar.linga@...el.com>,
	"intel-wired-lan@...ts.osuosl.org" <intel-wired-lan@...ts.osuosl.org>
CC: "netdev@...r.kernel.org" <netdev@...r.kernel.org>, "Lobakin, Aleksander"
	<aleksander.lobakin@...el.com>, "Linga, Pavan Kumar"
	<pavan.kumar.linga@...el.com>, "Kitszel, Przemyslaw"
	<przemyslaw.kitszel@...el.com>, "Zaremba, Larysa" <larysa.zaremba@...el.com>
Subject: RE: [Intel-wired-lan] [PATCH iwl-net] idpf: avoid compiler introduced
 padding in virtchnl2_rss_key struct

> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf Of
> Pavan Kumar Linga
> Sent: Friday, December 15, 2023 3:48 PM
> To: intel-wired-lan@...ts.osuosl.org
> Cc: netdev@...r.kernel.org; Lobakin, Aleksander
> <aleksander.lobakin@...el.com>; Linga, Pavan Kumar
> <pavan.kumar.linga@...el.com>; Kitszel, Przemyslaw
> <przemyslaw.kitszel@...el.com>; Zaremba, Larysa
> <larysa.zaremba@...el.com>
> Subject: [Intel-wired-lan] [PATCH iwl-net] idpf: avoid compiler introduced
> padding in virtchnl2_rss_key struct
> 
> Size of the virtchnl2_rss_key struct should be 7 bytes but the
> compiler introduces a padding byte for the structure alignment.
> This results in idpf sending an additional byte of memory to the device
> control plane than the expected buffer size. As the control plane
> enforces virtchnl message size checks to validate the message,
> set RSS key message fails resulting in the driver load failure.
> 
> Remove implicit compiler padding by using "__packed" structure
> attribute for the virtchnl2_rss_key struct.
> 
> Also there is no need to use __DECLARE_FLEX_ARRAY macro for the
> 'key_flex' struct field. So drop it.
> 
> Fixes: 0d7502a9b4a7 ("virtchnl: add virtchnl version 2 ops")
> Reviewed-by: Larysa Zaremba <larysa.zaremba@...el.com>
> Signed-off-by: Pavan Kumar Linga <pavan.kumar.linga@...el.com>
> ---
>  drivers/net/ethernet/intel/idpf/virtchnl2.h | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

Tested-by: Scott Register <scott.register@...el.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ