Re: [PATCH, RFC] Remove fasync() BKL usage, take 3325

From: Andrew Morton
Date: Fri Jan 23 2009 - 01:58:19 EST


> On Fri, 23 Jan 2009 06:54:04 +0100 Andi Kleen <andi@xxxxxxxxxxxxxx> wrote:
> > I don't know what "the fasync() problem" is?
>
> The state needs to be protected while the per driver ->fasync callback
> runs, otherwise the bit can get out of sync with what the driver
> thinks it is.

That's the sort of gem which one thinks might have merited a code comment
and some changelog discussion.

> Mind you imho the best way would be to move the bit manipulation for
> that into the drivers, but that would require to change them all.

Do these mystery drivers do the ->f_flags changes under lock_kernel()? If
so, they all should be changed to take lock_file_flgs()?

--
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/