Results 1 to 2 of 2
Thread: 'PAGE_OFFSET' undeclared
Enjoy an ad free experience by logging in. Not a member yet? Register.
- Join Date
- Jul 2008
I am trying to compile MIPS kernel, i am getting an error.
/include/stt_mem.h: In function 'stt_virt_to_phys':
/include/stt_mem.h:31: error: 'PAGE_OFFSET' undeclared (first use in this function)
/include/stt_mem.h: In function 'stt_phys_to_virt':
include/stt_mem.h:39: error: 'PAGE_OFFSET' undeclared (first use in this function)
In stt_mem.h file,
static inline unsigned long stt_virt_to_phys(void *virt)
return __pa(virt); ------> Line 31
static inline void *stt_phys_to_virt(unsigned long phys)
return (void *)__va(phys); ------------> line 39
i am getting no idea, how to solve this error.
Please help me out of this problem
Thanks in advance.
- Join Date
- Apr 2009
- I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
PAGE_OFFSET is defined in <kernel-source-dir>/include/asm-generic/page.h asCode:
#ifdef CONFIG_KERNEL_RAM_BASE_ADDRESS #define PAGE_OFFSET (CONFIG_KERNEL_RAM_BASE_ADDRESS) #else #define PAGE_OFFSET (0) #endifSometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!