From: Scott Bronson <bronson@rinspin.com>
To: LKML <linux-kernel@vger.kernel.org>
Subject: Getting the page size of currently running kernel
Date: Sat, 19 Feb 2005 19:01:57 -0800 [thread overview]
Message-ID: <200502191901.57425.bronson@rinspin.com> (raw)
Is there any way to get a running kernel to tell you the size of its pages?
Why: I'm writing a quick Perl hack to monitor the memory usage of the TCP
stack over time. Easy enough: /proc/net/sockstat gives the current value of
tcp_memory_allocated. But how do I convert this into bytes? I don't want to
hard code PAGE_SIZE into my Perl script, complete with a lookup table for 4K
vs. 8K architectures! Am I missing something obvious here?
Thanks,
- Scott
next reply other threads:[~2005-02-20 2:59 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-20 3:01 Scott Bronson [this message]
2005-02-20 3:22 ` Jan Knutar
2005-02-20 3:28 ` Roland Dreier
2005-02-20 4:39 ` Scott Bronson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200502191901.57425.bronson@rinspin.com \
--to=bronson@rinspin.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®