kern/159281: [PATCH] Linux-like /proc/swaps for linprocfs

Robert Millan rmh at debian.org
Sun Jul 31 16:56:52 UTC 2011


2011/7/30 Kostik Belousov <kostikbel at gmail.com>:
> Second, my proposal contains a flaw. Namely, if some swap device was removed
> between calls to swap_info and swap_devname calls, we get mangled list.

Ok, I see that you fixed this by unifying those functions.

> The third problem, which is not fixed, and which I do not want to handle,
> is that the swap devices list can be changed between calls to swap_devname(),
> changing device indexes and thus making the output mangled.

You say you don't want to handle this, but AFAICT from the patch you
already did.  Or did I miss something?

> Should the swap device name be separated from 'unknown' word by
> space or by tab ?

Linux' /proc/swaps prints spaces after the first column and tabs for
the rest.  I think it's better to do the same just in case, but I
don't think it's relevant either way.

> I updated your patch, hopefully fixing the issues. Do you have comments
> or objections ?

No.  Thanks for fixing those problems.

-- 
Robert Millan


More information about the freebsd-hackers mailing list