Paging - can i know the last owner(pid) of a given page?
Dear friends, I have a very simple question related to pages. Suppose, I have a kernel virtual address. Can I know which is the process that last used this address? Probably we might need to look at the members of the page strucre which the virtual address is part of. Any relevant information will be very helpful. PS: I have crash tool to debug the issue. Regards, Manty
hi : the struct of mm_struct which task_struct involve it may be right. http://lxr.oss.org.cn/source/include/linux/mm_types.h?v=3.17#L345 2015-01-08 17:09 GMT+08:00 manty kuma <mantykuma@gmail.com>:
Dear friends,
I have a very simple question related to pages.
Suppose, I have a kernel virtual address. Can I know which is the process that last used this address?
Probably we might need to look at the members of the page strucre which the virtual address is part of. Any relevant information will be very helpful.
PS: I have crash tool to debug the issue.
Regards, Manty
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
On Thu, 08 Jan 2015 18:09:19 +0900, manty kuma said:
Suppose, I have a kernel virtual address. Can I know which is the process that last used this address?
In general, no. First off, there's no good definition of "used" - if an address is pointing to (for instance) the inode for /dev/null, what does "used" mean? And more importantly, there's no hardware support for telling what kernel routines accessed a given address (unless you want to use kgdb-ish techniques for trapping on memory access - which gets *painful* if you have more than a few dozen points of interest). Second, it's quite possible that the most recent access was from a non-process context like a hardIRQ or something. What problem are you trying to solve here?
participants (3)
-
lx -
manty kuma -
Valdis.Kletnieks@vt.edu