[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YMeS780YarlA30E0@zeniv-ca.linux.org.uk>
Date: Mon, 14 Jun 2021 17:33:35 +0000
From: Al Viro <viro@...iv.linux.org.uk>
To: Christoph Hellwig <hch@....de>
Cc: Kees Cook <keescook@...omium.org>, axboe@...nel.dk,
anton@...msg.org, ccross@...roid.com, tony.luck@...el.com,
gmpy.liaowx@...il.com, linux-block@...r.kernel.org,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] mark pstore-blk as broken
On Mon, Jun 14, 2021 at 09:07:12AM +0200, Christoph Hellwig wrote:
> On Tue, Jun 08, 2021 at 10:34:29AM -0700, Kees Cook wrote:
> > NAK, please answer my concerns about your patches instead:
> > https://lore.kernel.org/lkml/202012011149.5650B9796@keescook/
>
> No. This code pokes into block layer internals with all kinds of issues
> and without any signoff from the relevant parties. We just can't keep it
> around.
There's a much more interesting question about that code: seeing that
psblk_generic_blk_write() contains this
/* Console/Ftrace backend may handle buffer until flush dirty zones */
if (in_interrupt() || irqs_disabled())
return -EBUSY;
just what are the locking conditions guaranteed to that thing?
Because if it's ever called with one of the destination pages
held locked by the caller, we are fucked. It won't get caught
by that test.
That really should've been discussed back when the entire thing
got merged; at the absolute least we need the locking environment
documented.
Powered by blists - more mailing lists