[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <202002211627.33D858AA@keescook>
Date: Fri, 21 Feb 2020 16:29:29 -0800
From: Kees Cook <keescook@...omium.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Andy Lutomirski <luto@...capital.net>,
Peter Zijlstra <peterz@...radead.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Jens Axboe <axboe@...nel.dk>, Jann Horn <jannh@...gle.com>,
Will Deacon <will@...nel.org>
Subject: Re: [PATCH] mm/tlb: Fix use_mm() vs TLB invalidate
On Fri, Feb 21, 2020 at 03:57:21PM -0800, Linus Torvalds wrote:
> On Fri, Feb 21, 2020 at 3:10 PM Kees Cook <keescook@...omium.org> wrote:
> > Why not just fail after the WARN -- I wrote the patch for the (very few)
> > callers to handle the errors, clean up, and carry on.
>
> Can it actually fail? Or is this all just "let's add new error
> conditions that make the code harder to read because they make no
> actual sense"?
I was just trying to see if there was a reasonable "do not continue and
do stuff we just tested for". If this should just be WARN_ON_ONCE() and
continue anyway, so be it. My general guideline is to avoid continuing a
known-bad path.
--
Kees Cook
Powered by blists - more mailing lists