summaryrefslogtreecommitdiff
path: root/include/linux/pfn_t.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/pfn_t.h')
-rw-r--r--include/linux/pfn_t.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/pfn_t.h b/include/linux/pfn_t.h
index 7bb77850c65a..3c202a11a79e 100644
--- a/include/linux/pfn_t.h
+++ b/include/linux/pfn_t.h
@@ -68,7 +68,7 @@ static inline phys_addr_t pfn_t_to_phys(pfn_t pfn)
static inline void *pfn_t_to_virt(pfn_t pfn)
{
- if (pfn_t_has_page(pfn))
+ if (pfn_t_has_page(pfn) && !is_device_private_page(pfn_t_to_page(pfn)))
return __va(pfn_t_to_phys(pfn));
return NULL;
}