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: <1648322401.84640.1764751241037.JavaMail.zimbra@couthit.local>
Date: Wed, 3 Dec 2025 14:10:41 +0530 (IST)
From: Parvathi Pudi <parvathi@...thit.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: Parvathi Pudi <parvathi@...thit.com>, andrew+netdev <andrew+netdev@...n.ch>, 
	davem <davem@...emloft.net>, edumazet <edumazet@...gle.com>, 
	pabeni <pabeni@...hat.com>, danishanwar <danishanwar@...com>, 
	rogerq <rogerq@...nel.org>, pmohan <pmohan@...thit.com>, 
	basharath <basharath@...thit.com>, afd <afd@...com>, 
	linux-kernel <linux-kernel@...r.kernel.org>, 
	netdev <netdev@...r.kernel.org>, 
	linux-arm-kernel <linux-arm-kernel@...ts.infradead.org>, 
	ALOK TIWARI <alok.a.tiwari@...cle.com>, horms <horms@...nel.org>, 
	pratheesh <pratheesh@...com>, j-rameshbabu <j-rameshbabu@...com>, 
	Vignesh Raghavendra <vigneshr@...com>, praneeth <praneeth@...com>, 
	srk <srk@...com>, rogerq <rogerq@...com>, 
	krishna <krishna@...thit.com>, mohan <mohan@...thit.com>
Subject: Re: [PATCH net-next v8 1/3] net: ti: icssm-prueth: Add helper
 functions to configure and maintain FDB

Hi,

> On Wed, 26 Nov 2025 21:57:12 +0530 Parvathi Pudi wrote:
>> +	u8 hash_val, mac_tbl_idx;
> 
> Using narrow types is generally quite counter productive.
> It can easily mask out-of-range accesses and subtle errors,
> given that max is outside of the range of the u8 type:
> 
> +#define FDB_INDEX_TBL_MAX_ENTRIES     256
> +#define FDB_MAC_TBL_MAX_ENTRIES       256
> 
> You should consider changing all the local variables to unsigned int.

OK, we will update the code to use unsigned int for relevant local
variables to avoid any silent errors.

Thanks and Regards,
Parvathi.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ