[COMMON] mm: gup: fix invalid comparison for CMA
authorCho KyongHo <pullip.cho@samsung.com>
Tue, 27 Dec 2016 11:33:02 +0000 (20:33 +0900)
committerhskang <hs1218.kang@samsung.com>
Mon, 27 Aug 2018 07:21:35 +0000 (16:21 +0900)
commitcd830d7370b16f394782413770385736e0b31e5f
treecb2ac54bcceb902edb8402de7cc4209d4fb27bdd
parent8f9be7e0afe7c3d74da1701c5745e29bc58e7032
[COMMON] mm: gup: fix invalid comparison for CMA

CMA pages should not be pinned for a long time because they should be
always ready for reclamation by the user's request. If a user of gup
wants to pin a series of pages for a long time he/she should give
FOLL_CMA to let gup migrate the CMA pages that are in pinning to
non-CMA pages.

In order to determine if a pinning page is in a CMA page, gpu should
compare if the migrate type of the pageblock of the page is
MIGRATE_CMA. But the comparison is not correct and the migration
never happens.

SVACE #82317

Change-Id: Id4ef40957365bdbe586f29c4ba0e6318e232719a
Signed-off-by: Cho KyongHo <pullip.cho@samsung.com>
mm/gup.c