dect
/
linux-2.6
Archived
13
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
linux-2.6/Documentation
Mauricio Lin e070ad49f3 [PATCH] add /proc/pid/smaps
Add a "smaps" entry to /proc/pid: show howmuch memory is resident in each
mapping.

People that want to perform a memory consumption analysing can use it
mainly if someone needs to figure out which libraries can be reduced for
embedded systems.  So the new features are the physical size of shared and
clean [or dirty]; private and clean [or dirty].

Take a look the example below:

# cat /proc/4576/smaps

08048000-080dc000 r-xp /bin/bash
Size:               592 KB
Rss:                500 KB
Shared_Clean:       500 KB
Shared_Dirty:         0 KB
Private_Clean:        0 KB
Private_Dirty:        0 KB
080dc000-080e2000 rw-p /bin/bash
Size:                24 KB
Rss:                 24 KB
Shared_Clean:         0 KB
Shared_Dirty:         0 KB
Private_Clean:        0 KB
Private_Dirty:       24 KB
080e2000-08116000 rw-p
Size:               208 KB
Rss:                208 KB
Shared_Clean:         0 KB
Shared_Dirty:         0 KB
Private_Clean:        0 KB
Private_Dirty:      208 KB
b7e2b000-b7e34000 r-xp /lib/tls/libnss_files-2.3.2.so
Size:                36 KB
Rss:                 12 KB
Shared_Clean:        12 KB
Shared_Dirty:         0 KB
Private_Clean:        0 KB
Private_Dirty:        0 KB
...

(Includes a cleanup from "Richard Purdie" <rpurdie@rpsys.net>)

From: Torsten Foertsch <torsten.foertsch@gmx.net>

show_smap calls first show_map and then prints its additional information to
the seq_file.  show_map checks if all it has to print fits into the buffer and
if yes marks the current vma as written.  While that is correct for show_map
it is not for show_smap.  Here the vma should be marked as written only after
the additional information is also written.

The attached patch cures the problem.  It moves the functionality of the
show_map function to a new function show_map_internal that is called with an
additional struct mem_size_stats* argument.  Then show_map calls
show_map_internal with NULL as struct mem_size_stats* whereas show_smap calls
it with a real pointer.  Now the final

	if (m->count < m->size)  /* vma is copied successfully */
		m->version = (vma != get_gate_vma(task))? vma->vm_start: 0;

is done only if the whole entry fits into the buffer.

Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-09-05 00:05:49 -07:00
..
DocBook [PATCH] Minor libata documentation patch 2005-06-27 23:21:00 -04:00
RCU [PATCH] Update RCU documentation 2005-05-01 08:59:05 -07:00
aoe [PATCH] aoe: update the documentation to mention aoetools 2005-05-03 23:34:54 -07:00
arm [PATCH] ARM: 2847/1: S3C24XX - Documentation for USB OHCI host 2005-08-10 16:45:14 +01:00
block [PATCH] CFQ io scheduler, add ioprio documentation 2005-06-27 14:33:30 -07:00
cdrom [PATCH] cosmetic fixes for example programs in Documentation/cdrom/sbpcd 2005-06-25 16:25:02 -07:00
cpu-freq [PATCH] cpufreq: governors documentation fixes 2005-06-25 16:24:55 -07:00
cris Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
crypto Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
device-mapper Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
driver-model [PATCH] Driver Core: driver model doc update 2005-06-20 15:15:29 -07:00
dvb [PATCH] fix for Documentation/dvb/bt8xx.txt?= 2005-07-07 18:24:03 -07:00
early-userspace Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
fb [PATCH] vesafb: Document mtrr boot option usage 2005-07-30 10:14:47 -07:00
filesystems [PATCH] add /proc/pid/smaps 2005-09-05 00:05:49 -07:00
firmware_class Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
fujitsu/frv Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hwmon [PATCH] I2C: Move hwmon drivers (3/3) 2005-07-11 14:47:41 -07:00
i2c [PATCH] I2C: Move hwmon drivers (3/3) 2005-07-11 14:47:41 -07:00
i2o Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
i386 [PATCH] Increase number of e820 entries hard limit from 32 to 128 2005-05-01 08:58:51 -07:00
ia64 Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
infiniband [PATCH] IB: Add core locking documentation to Infiniband 2005-07-27 16:26:15 -07:00
input Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ioctl Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
isdn Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kbuild Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kdump [PATCH] kdump documentation update to introduce use of irqpoll 2005-06-25 16:24:52 -07:00
m68k Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mips Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
networking /spare/repo/netdev-2.6 branch 'master' 2005-09-01 18:02:01 -04:00
parisc Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
pcmcia [PATCH] pcmcia: update documentation 2005-07-28 08:39:00 -07:00
power [PATCH] video doc: one more system where video works with S3 2005-07-07 18:24:11 -07:00
powerpc [PATCH] Driver Core: remove driver model detach_state 2005-05-17 14:54:55 -07:00
s390 [PATCH] s390: debug feature changes 2005-06-25 16:24:37 -07:00
scsi [SCSI] remove scsi_set_device 2005-06-26 08:31:47 -05:00
serial [SERIAL] Clean up and fix tty transmission start/stoping 2005-08-31 10:12:14 +01:00
sh Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sound [ALSA] ad1816a - Add clockfreq module option 2005-08-30 08:43:32 +02:00
sparc Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sysctl [PATCH] setuid core dump 2005-06-23 09:45:26 -07:00
telephony Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
uml Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
usb [PATCH] USB: ub documentation update 2005-08-04 21:32:46 -07:00
video4linux [PATCH] v4l: oopsfix for BTTV on badly behaved PCI chipsets 2005-08-04 13:00:54 -07:00
vm [PATCH] swap: swap_lock replace list+device 2005-09-05 00:05:42 -07:00
w1 [PATCH] w1: Updates the w1 documentation (w1.generic) 2005-06-21 21:43:12 -07:00
watchdog Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
x86_64 [PATCH] x86_64: ignore machine checks from boot time 2005-08-07 10:00:37 -07:00
00-INDEX [PATCH] kdump: Documentation for Kdump 2005-06-25 16:24:52 -07:00
BUG-HUNTING Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
Changes [PATCH] Documentation/Changes: document the required udev version 2005-07-27 16:26:07 -07:00
CodingStyle Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
DMA-API.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
DMA-mapping.txt [PATCH] remove old scsi data direction macros 2005-04-18 13:49:58 -05:00
IO-mapping.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
IPMI.txt [PATCH] ipmi: add power cycle capability 2005-06-24 00:05:23 -07:00
IRQ-affinity.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
MSI-HOWTO.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ManagementStyle Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
PCIEBUS-HOWTO.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
README.DAC960 Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
README.cycladesZ Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
SAK.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
SecurityBugs Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
SubmittingDrivers [PATCH] Doc/Submitting: corrections, additions 2005-06-28 21:20:37 -07:00
SubmittingPatches [PATCH] plug MAN-PAGES maintainer in Documentation/SubmittingPatches 2005-08-01 19:14:00 -07:00
VGA-softcursor.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
acpi-hotkey.txt [ACPI] re-enable platform-specific hotkey drivers by default 2005-08-15 15:46:58 -04:00
atomic_ops.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
basic_profiling.txt [PATCH] oprofile: report anonymous region samples 2005-06-24 00:06:27 -07:00
binfmt_misc.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cachetlb.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cciss.txt [PATCH] cciss: pci id fix 2005-06-27 15:11:48 -07:00
cli-sti-removal.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
computone.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cpqarray.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cpusets.txt [PATCH] Dynamic sched domains: cpuset changes 2005-06-25 16:24:45 -07:00
debugging-modules.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
devices.txt [PATCH] kdump: Accessing dump file in linear raw format (/dev/oldmem) 2005-06-25 16:24:54 -07:00
digiepca.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
dnotify.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
dontdiff [PATCH] ARM: 2840/1: Add mach-types to Documentation/dontdiff 2005-08-03 19:49:18 +01:00
eisa.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
exception.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
feature-removal-schedule.txt [NETFILTER]: Add "nfnetlink_queue" netfilter queue handler over nfnetlink 2005-08-29 15:36:56 -07:00
floppy.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ftape.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hayes-esp.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
highuid.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hpet.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hw_random.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ibm-acpi.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ide.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
initrd.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
io_ordering.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ioctl-number.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
iostats.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
isapnp.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
java.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kernel-doc-nano-HOWTO.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kernel-docs.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kernel-parameters.txt Merge ../to-linus-stable/ 2005-08-15 15:49:00 -04:00
keys.txt [PATCH] Keys: Make request-key create an authorisation key 2005-06-24 00:05:19 -07:00
kobject.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kprobes.txt [PATCH] Add Documentation/kprobes.txt 2005-08-04 13:00:55 -07:00
kref.txt [PATCH] kref: add link to original documentation to the kref documentation. 2005-04-18 21:57:30 -07:00
laptop-mode.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ldm.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
locks.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
logo.gif Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
logo.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
magic-number.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mandatory.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mca.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
md.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
memory.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mono.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
moxa-smartio Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mtrr.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
nbd.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
nfsroot.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
nmi_watchdog.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
nommu-mmap.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
numastat.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
oops-tracing.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
paride.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
parport-lowlevel.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
parport.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
pci.txt [PATCH] PCI: update documentation 2005-08-16 21:06:25 -07:00
pm.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
pnp.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
preempt-locking.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
prio_tree.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ramdisk.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
riscom8.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
rocket.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
rpc-cache.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
rtc.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sched-coding.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sched-design.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sched-domains.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sched-stats.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
seclvl.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
serial-console.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sgi-ioc4.txt [PATCH] ioc4: Core driver rewrite 2005-06-21 18:46:32 -07:00
sgi-visws.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
smart-config.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
smp.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sonypi.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sparse.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
specialix.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
spinlocks.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
stable_api_nonsense.txt [PATCH] stable_api_nonsense.txt fixes 2005-07-29 13:12:49 -07:00
stable_kernel_rules.txt [PATCH] Add the rules about the -stable kernel releases to the Documentation directory 2005-07-29 13:12:49 -07:00
stallion.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
svga.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sx.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sysrq.txt [PATCH] kdump: sysrq trigger mechanism for kexec based crashdumps 2005-06-25 16:24:54 -07:00
time_interpolators.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
tipar.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
tty.txt [PATCH] Introduce tty_unregister_ldisc() 2005-06-23 09:45:35 -07:00
unicode.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
voyager.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
xterm-linux.xpm Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
zorro.txt Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00

README.cycladesZ

The Cyclades-Z must have firmware loaded onto the card before it will
operate.  This operation should be performed during system startup,

The firmware, loader program and the latest device driver code are
available from Cyclades at
    ftp://ftp.cyclades.com/pub/cyclades/cyclades-z/linux/