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: <1287605385.27545.9.camel@wall-e.seibold.net>
Date:	Wed, 20 Oct 2010 22:09:45 +0200
From:	Stefani Seibold <stefani@...bold.net>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	Alan Cox <alan@...rguk.ukuu.org.uk>,
	Randy Dunlap <randy.dunlap@...cle.com>,
	lkml <linux-kernel@...r.kernel.org>
Subject: Re: kfifo must_check warning (+ patch)

The problem should be fixed. I renamed the __kfifo_must_check_helper()
into __kfifo_uint_must_check_helper() and add a new
__kfifo_int_must_check_helper() which is now used for kfifo_alloc().

A kernel linux 2.6.36-rc compiled with gcc 4.4.4 doesn't show the
warning.

There a only two functions which return a int: kfifo_alloc() and
kfifo_init(). The later one does not make use of
__kfifo_int_must_check_helper(), but this could be change if required.

I will send the patch in a separate mail.

Am Mittwoch, den 20.10.2010, 11:56 -0700 schrieb Andrew Morton:
> On Wed, 20 Oct 2010 19:37:02 +0100
> Alan Cox <alan@...rguk.ukuu.org.uk> wrote:
> 
> > > Some versions of gcc mysteriously report:
> > > drivers/char/n_gsm.c:1580: warning: ignoring return value of '__kfifo_must_check_helper', declared with attribute warn_unused_result
> > > 
> > > This warning can be eliminated by using a local variable for the
> > > returned result value, as suggested by Andrew Morton.
> > 
> > But that just hides the bug in the helper surely - the helper has type
> > errors so needs fixing - not this. If you apply this then the underlying
> > bug is just going to get forgotten
> > 
> 
> It won't get forgotten.
> 
> I agree that the warning is probably an artifact of the signedness
> thing.  So for 2.6.36, disabling __kfifo_must_check_helper() will
> suffice.  I'm sure that Stefani will fix up __kfifo_must_check_helper()
> for real for 2.6.37, then we can see if the warning reoccurs.


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ