hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/arch/xtensa/include/asm/page.h
....@@ -169,7 +169,18 @@
169169 if (off >= XCHAL_KSEG_SIZE)
170170 off -= XCHAL_KSEG_SIZE;
171171
172
+#ifndef CONFIG_XIP_KERNEL
172173 return off + PHYS_OFFSET;
174
+#else
175
+ if (off < XCHAL_KSEG_SIZE)
176
+ return off + PHYS_OFFSET;
177
+
178
+ off -= XCHAL_KSEG_SIZE;
179
+ if (off >= XCHAL_KIO_SIZE)
180
+ off -= XCHAL_KIO_SIZE;
181
+
182
+ return off + XCHAL_KIO_PADDR;
183
+#endif
173184 }
174185 #define __pa(x) ___pa((unsigned long)(x))
175186 #else
....@@ -191,9 +202,6 @@
191202 #define page_to_phys(page) (page_to_pfn(page) << PAGE_SHIFT)
192203
193204 #endif /* __ASSEMBLY__ */
194
-
195
-#define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \
196
- VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
197205
198206 #include <asm-generic/memory_model.h>
199207 #endif /* _XTENSA_PAGE_H */