Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Oct 2000 12:46:54 -0700
From:      Nathan Boeger <nathan@khmere.com>
To:        "freebsd-hackers@FreeBSD.ORG" <freebsd-hackers@FreeBSD.ORG>
Subject:   struct proc and struct vmspace help, please
Message-ID:  <39EDFE2E.583B5631@khmere.com>

next in thread | raw e-mail | index | archive | help
I have the need for the /proc/<pid>/status file inside the linprocfs. So

I have added it to the linprocfs_misc.c

Well the only problem I am having is the VmRSS: field. How do I get the
rssize from inside the kernel  for a process ? from userland I can do:

struct kinfo_proc->kp_eproc . e_vm . vm_rssize ( like top )

but from inside the struct proc what do I use ? I have tried the struct
vmspace but it give me strange numbers (well, maybe not strange but are
they in pages ? bytes ? and why are they 0 sometimes ? ) I have looked
and explored all over the headers, but I am stuck.

Any help will be greatly appreciated !!!

thank you

nathan



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?39EDFE2E.583B5631>