Ryusuke Konishi 003ff182fd nilfs2: allow future expansion of metadata read out via get info ioctl
Nilfs has some ioctl commands to read out metadata from meta data
files:

 - NILFS_IOCTL_GET_CPINFO for checkpoint file,
 - NILFS_IOCTL_GET_SUINFO for segment usage file, and
 - NILFS_IOCTL_GET_VINFO for Disk Address Transalation (DAT) file,
   respectively.

Every routine on these metadata files is implemented so that it allows
future expansion of on-disk format.  But, the above ioctl commands do
not support expansion even though nilfs_argv structure can handle
arbitrary size for data exchanged via ioctl.

This allows future expansion of the following structures which give
basic format of the "get information" ioctls:

 - struct nilfs_cpinfo
 - struct nilfs_suinfo
 - struct nilfs_vinfo

So, this introduces forward compatility of such ioctl commands.

In this patch, a sanity check in nilfs_ioctl_get_info() function is
changed to accept larger data structure [1], and metadata read
routines are rewritten so that they become compatible for larger
structures; the routines will just ignore the remaining fields which
the current version of nilfs doesn't know.

[1] The ioctl function already has another upper limit (PAGE_SIZE
    against a structure, which appears in nilfs_ioctl_wrap_copy
    function), and this will not cause security problem.

Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
2009-06-10 23:41:11 +09:00
..
2009-04-02 19:05:08 -07:00
2009-04-20 23:01:15 -04:00
2009-04-08 10:21:43 -07:00
2009-01-22 13:15:57 +03:00
2009-04-02 19:05:09 -07:00
2009-03-31 19:44:38 +03:00
2009-04-17 09:32:11 -07:00
2009-01-22 13:15:58 +03:00
2009-04-13 15:04:29 -07:00
2009-03-31 23:00:26 -04:00
2009-04-20 23:02:51 -04:00
2008-10-17 02:38:36 +11:00
2009-05-09 10:49:40 -04:00
2009-04-02 19:05:10 -07:00
2009-04-02 19:05:10 -07:00
2009-03-27 14:44:03 -04:00
2008-12-31 18:07:43 -05:00
2009-01-03 11:45:54 -08:00
2009-03-31 23:00:27 -04:00
2009-05-09 10:49:40 -04:00
2009-04-02 19:04:48 -07:00
2009-03-31 23:00:26 -04:00
2009-06-06 14:33:41 -07:00
2009-04-07 08:31:16 -07:00
2009-04-07 08:31:16 -07:00
2009-04-17 07:38:07 -07:00
2009-04-20 23:02:52 -04:00
2009-02-18 15:37:53 -08:00
2009-04-20 23:02:50 -04:00