projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ee82906
)
Patch from Atsushi Nemoto, recent MIPS kernel headers
author
Glenn L McGrath
<bug1@ihug.co.nz>
Wed, 21 Jan 2004 11:36:44 +0000
(11:36 -0000)
committer
Glenn L McGrath
<bug1@ihug.co.nz>
Wed, 21 Jan 2004 11:36:44 +0000
(11:36 -0000)
does not provide PAGE_SHIFT for userland (because now mips-linux kernel
supports PAGESIZE other than 4K).
libbb/procps.c
patch
|
blob
|
history
diff --git
a/libbb/procps.c
b/libbb/procps.c
index 44103fae8992d9b877967e3c577914c2b07d8708..252e9c772455328221a8e892df06d261759b728f 100644
(file)
--- a/
libbb/procps.c
+++ b/
libbb/procps.c
@@
-115,7
+115,11
@@
extern procps_status_t * procps_scan(int save_user_arg0
else
curstatus.state[2] = ' ';
+#ifdef PAGE_SHIFT
curstatus.rss <<= (PAGE_SHIFT - 10); /* 2**10 = 1kb */
+#else
+ curstatus.rss *= (getpagesize() >> 10); /* 2**10 = 1kb */
+#endif
if(save_user_arg0) {
sprintf(status, "/proc/%d/cmdline", pid);