I have to access data from a pointer in a struct iw_point
variable on a Linux based embedded board. The pointer contained in the struct
is of type __user
. But when I try to access that location, the program keeps segfaulting.
When I looked at the memory location pointed to by that pointer, I noticed that the location does not lie in the address space of the process which has to read from the location(obtained by reading /proc/pid/maps
):
00400000-0048c000 r-xp 00000000 1f:04 83 /root/aravind/smapp
0049b000-0049c000 rw-p 0008b000 1f:04 83 /root/aravind/smapp
The location returned by the pointer is E80000 which does not lie in the range returned above.
Does this mean that the location lies outside the address space of the program triggering the pointer return in the first place(the pointer is returned by an ioctl call)?