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, 7 May 2008 10:23:10 +0200
From:	Cornelia Huck <cornelia.huck@...ibm.com>
To:	benh@...nel.crashing.org
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	David Miller <davem@...emloft.net>, tony@...eyournoodle.com,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Silence 'ignoring return value' warnings in
 drivers/video/aty/radeon_base.c

On Wed, 07 May 2008 14:33:24 +1000,
Benjamin Herrenschmidt <benh@...nel.crashing.org> wrote:

> You haven't read me properly. I'm not advocating completely ignoring
> those errors. In fact, I'm all about keeping must check on things like
> allocations. However, in cases like sysfs_create_file() like many
> similar things where failure will -not- prevent proper operations of the
> driver or subsystem, 

But they are often an indication that we messed up earlier (e. g. try
to add something twice)...

> mostly only compromise the user ABI, 

Which is bad enough in itself. Most people will want to avoid a
crippled ABI.

> I believe it's
> a _LOT_ more efficient to put -one- printk in the function itself,
> rather than all callers
> 
> > Now you come along and cherrypick a few callsites where you'd rather not
> > bother checking and assert that the entire effort was wrong-headed.  Well
> > sorry, no, it wasn't.  Sure, there's a little bit of undesirable fallout
> > but the whole thing had.  to.  be.  done.
> 
> Of course the whole effort was not wrong headed. I'm really only
> complaining about all those stupid sysfs_create_file() and maybe a
> handful of similar ones.

Hm, just took a look at the code:

- for "entry already exists", sysfs will already spit a warning.
- for "argh, we can't get a dirent", sysfs won't say anything.

The first one is the one we really want to yell about, since we've
messed up somewhere. The second one is not as likely, maybe we want to
warn about it when we activate debug options?

Which of the current __must_check functions do you think should have
the __must_check removed?
--
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