[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210122144958.GF8567@gaia>
Date: Fri, 22 Jan 2021 14:49:58 +0000
From: Catalin Marinas <catalin.marinas@....com>
To: Vincenzo Frascino <vincenzo.frascino@....com>
Cc: linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
kasan-dev@...glegroups.com,
Andrey Ryabinin <aryabinin@...tuozzo.com>,
Alexander Potapenko <glider@...gle.com>,
Dmitry Vyukov <dvyukov@...gle.com>,
Leon Romanovsky <leonro@...lanox.com>,
Andrey Konovalov <andreyknvl@...gle.com>,
Will Deacon <will@...nel.org>,
Mark Rutland <mark.rutland@....com>,
"Paul E . McKenney" <paulmck@...nel.org>,
Naresh Kamboju <naresh.kamboju@...aro.org>
Subject: Re: [PATCH v3 1/2] arm64: Improve kernel address detection of
__is_lm_address()
On Fri, Jan 22, 2021 at 02:37:47PM +0000, Vincenzo Frascino wrote:
> Currently, the __is_lm_address() check just masks out the top 12 bits
> of the address, but if they are 0, it still yields a true result.
> This has as a side effect that virt_addr_valid() returns true even for
> invalid virtual addresses (e.g. 0x0).
>
> Improve the detection checking that it's actually a kernel address
> starting at PAGE_OFFSET.
>
> Cc: Catalin Marinas <catalin.marinas@....com>
> Cc: Will Deacon <will@...nel.org>
> Suggested-by: Catalin Marinas <catalin.marinas@....com>
> Signed-off-by: Vincenzo Frascino <vincenzo.frascino@....com>
Reviewed-by: Catalin Marinas <catalin.marinas@....com>
The question is whether we leave this for 5.12 or we merge it earlier.
--
Catalin
Powered by blists - more mailing lists