aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/io-mapping.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/io-mapping.h b/include/linux/io-mapping.h
index 8cdcc2a199ad..1feeb5263565 100644
--- a/include/linux/io-mapping.h
+++ b/include/linux/io-mapping.h
@@ -117,6 +117,8 @@ io_mapping_unmap(void __iomem *vaddr)
117 117
118#else 118#else
119 119
120#include <linux/uaccess.h>
121
120/* this struct isn't actually defined anywhere */ 122/* this struct isn't actually defined anywhere */
121struct io_mapping; 123struct io_mapping;
122 124
@@ -138,12 +140,14 @@ static inline void __iomem *
138io_mapping_map_atomic_wc(struct io_mapping *mapping, 140io_mapping_map_atomic_wc(struct io_mapping *mapping,
139 unsigned long offset) 141 unsigned long offset)
140{ 142{
143 pagefault_disable();
141 return ((char __force __iomem *) mapping) + offset; 144 return ((char __force __iomem *) mapping) + offset;
142} 145}
143 146
144static inline void 147static inline void
145io_mapping_unmap_atomic(void __iomem *vaddr) 148io_mapping_unmap_atomic(void __iomem *vaddr)
146{ 149{
150 pagefault_enable();
147} 151}
148 152
149/* Non-atomic map/unmap */ 153/* Non-atomic map/unmap */