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:	Wed, 8 Jan 2014 13:55:09 +0800
From:	Ying Xue <ying.xue@...driver.com>
To:	David Miller <davem@...emloft.net>
CC:	<steffen.klassert@...unet.com>, <dborkman@...hat.com>,
	<netdev@...r.kernel.org>
Subject: Re: [PATCH net-next] net: xfrm6: silence sparse warning

On 01/08/2014 11:43 AM, David Miller wrote:
> From: Ying Xue <ying.xue@...driver.com>
> Date: Wed, 8 Jan 2014 10:56:40 +0800
> 
>> Fix below sparse warning:
>>
>> net/ipv6/xfrm6_state.c:66:26: error: cannot size expression
>  ...
>> -	memset(count, 0, sizeof(count));
>> +	memset(count, 0, sizeof(int) * maxclass);
> 
> I think the fix belongs in sparse, making it respect these two expressions
> as equivalent.
> 
> 

Yes, you are right. Actually the fix just eliminates one 'error' warning
complained from sparse, instead its complete sparse warnings like:

  CHECK   net/ipv6/xfrm6_state.c
net/ipv6/xfrm6_state.c:64:19: warning: Variable length array is used.
net/ipv6/xfrm6_state.c:66:26: error: cannot size expression

But the first warning(ie, warning: Variable length array is used) to be
fixed needs a big change made, so I think it seems unnecessary.
Therefore, I just fix the latter in the patch.

Which action below should I take in next step?

1. I just update the fix commit description as below:

-----
Fix below sparse error:

  CHECK   net/ipv6/xfrm6_state.c
net/ipv6/xfrm6_state.c:66:26: error: cannot size expression
-----

2. Fix the former warning as well in the patch by changing the
allocation of count[] array from static mode to dynamical.

3. Just drop the patch

Please tell me.

Thanks,
Ying

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ