pcp
[Top] [All Lists]

Re: PCP patch for top/libgtop conversion

To: kaos@xxxxxxx (Keith Owens)
Subject: Re: PCP patch for top/libgtop conversion
From: "Albert D. Cahalan" <acahalan@xxxxxxxxxx>
Date: Tue, 26 Nov 2002 20:17:35 -0500 (EST)
Cc: acahalan@xxxxxxxxxx (Albert D. Cahalan), pcp@xxxxxxxxxxx, todd.c.davis@xxxxxxxxx, mmlnx@xxxxxxxxxx
In-reply-to: <30577.1038359437@xxxxxxxxxxxxxxxxxxxxxx> from "Keith Owens" at Nov 27, 2002 12:10:37 PM
Sender: pcp-bounce@xxxxxxxxxxx
>>> Most /proc code that generates more than a page of data uses seq_file.
>>> That implementation saves a position index which is passed to the
>>> seq_operations->start() routine on the next read.  Every such routine
>>> in 2.4.19 uses the index as a counter into a list, i.e. all the
>>> seq_file code is vulnerable to this race.
>>
>> It would be dumb for /proc/*/maps to do this. Each line has
>> an address that may be used to find back the position.
...
> You are concentrating on just the files used by procps, but PCP has to
> worry about other /proc files.  Small files whose data fits in a single
> page are not a problem, larger /proc files have races.

It was /proc/*/maps that was originally mentioned.

<Prev in Thread] Current Thread [Next in Thread>