mm: LKSM: bug fix for KASAN out-of-bound access error on accessing a filter
authorSung-hun Kim <sfoon.kim@samsung.com>
Wed, 28 Oct 2020 10:26:31 +0000 (19:26 +0900)
committerHoegeun Kwon <hoegeun.kwon@samsung.com>
Thu, 3 Aug 2023 08:46:08 +0000 (17:46 +0900)
commitba9d332ebc38da8c63202c239e39ff08bdb08595
treed11979506638419f395858ebdc264809f3e696a4
parenteb71387eca01b656a197febe2e055c5fbbc70a26
mm: LKSM: bug fix for KASAN out-of-bound access error on accessing a filter

KASAN reports out-of-bound accesses (reported by Jaehoon Chung)
on slab which is performed for obtaining a next filtered
address to find a sharable page.

LKSM exploits bitmap-based filters to find sharable pages in
an efficient way. A buggy code is a kind of miscalculation for
boundary of the allocated bitmap. This patch takes care of it.

Change-Id: If45c5ce175db067523b60f11e69e12d2bc798659
Signed-off-by: Sung-hun Kim <sfoon.kim@samsung.com>
mm/lksm.c