diff options
author | Catalin Marinas <catalin.marinas@arm.com> | 2016-05-05 10:44:02 +0100 |
---|---|---|
committer | Will Deacon <will.deacon@arm.com> | 2016-05-06 12:46:53 +0100 |
commit | 5bb1cc0ff9a6b68871970737e6c4c16919928d8b (patch) | |
tree | df67d3dfc14d9efd21c5f0abc1a91093f6fd800c /drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | |
parent | ab4db1f2244dfc5ecd7adf9927c29cd654cc14c6 (diff) |
arm64: Ensure pmd_present() returns false after pmd_mknotpresent()
Currently, pmd_present() only checks for a non-zero value, returning
true even after pmd_mknotpresent() (which only clears the type bits).
This patch converts pmd_present() to using pte_present(), similar to the
other pmd_*() checks. As a side effect, it will return true for
PROT_NONE mappings, though they are not yet used by the kernel with
transparent huge pages.
For consistency, also change pmd_mknotpresent() to only clear the
PMD_SECT_VALID bit, even though the PMD_TABLE_BIT is already 0 for block
mappings (no functional change). The unused PMD_SECT_PROT_NONE
definition is removed as transparent huge pages use the pte page prot
values.
Fixes: 9c7e535fcc17 ("arm64: mm: Route pmd thp functions through pte equivalents")
Cc: <stable@vger.kernel.org> # 3.15+
Reviewed-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c')
0 files changed, 0 insertions, 0 deletions