Subject: re: Adding /proc/swaps to linux compat code
To: Arnaud Lacombe <>
From: matthew green <>
List: tech-kern
Date: 02/01/2007 04:56:13
   The only one problem is the partition type, I guess I can rely on the
   value of sep->se_dev (ie. if the swap is a valid block dev or not) to
   determine if it's a partition or a file.

se_dev will be NODEV for a file or a device for a partition.

sizes are stored in DEV_BSIZE units, so you should adjust the value of
se_nblks and se_inuse with "/ 1024 * DEV_BSIZE" or something.  i'm not
really sure which order would be best for those two operation, in order
to avoid integer underflow or overflow issues.  please also update the
comment to reflect this...