Re: [PATCH] Silence 'ignoring return value' warnings indrivers/video/aty/radeon_base.c
From: Benjamin Herrenschmidt
Date: Wed May 07 2008 - 17:45:54 EST
On Wed, 2008-05-07 at 10:23 +0200, Cornelia Huck wrote:
>
> 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.
You prefer a crippled ABI or a machine that doesn't boot with no console
at all to see what happened because the console driver refused to
initialize due to such a sysfs file conflict ?
Now, again, that's only part of what I'm talking about anyway.
What I'm saying is basically that rather than have a test & printk in
every bloody driver, we are better off having it once in the function
itself (bloat ?)
In addition, in most cases, failure of initializing the driver is -not-
the right solution, so the driver should probably just warn, which can
as well be done by ... having sysfs_create_file() itself do the warning.
> 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?
sysfs_create_file is a good candidate imho :-)
Ben.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/