diff options
author | Tristan Ye <tristan.ye@oracle.com> | 2011-05-24 15:25:54 +0800 |
---|---|---|
committer | Tristan Ye <tristan.ye@oracle.com> | 2011-05-25 12:18:02 +0800 |
commit | 3e5db17d4da7f45c454940096d9e429cca12ef9f (patch) | |
tree | e808424de357b1140817341675b8624292c6c7b2 /fs/ocfs2/ocfs2_ioctl.h | |
parent | 8aa1fa360d0e2b31891f180d8b8e0f8d38f9243c (diff) | |
download | linux-stable-3e5db17d4da7f45c454940096d9e429cca12ef9f.tar.gz linux-stable-3e5db17d4da7f45c454940096d9e429cca12ef9f.tar.bz2 linux-stable-3e5db17d4da7f45c454940096d9e429cca12ef9f.zip |
Ocfs2: Add a new code 'OCFS2_INFO_FREEINODE' for o2info ioctl.
The new code is dedicated to calculate free inodes number of all inode_allocs,
then return the info to userpace in terms of an array.
Specially, flag 'OCFS2_INFO_FL_NON_COHERENT', manipulated by '--cluster-coherent'
from userspace, is now going to be involved. setting the flag on means no cluster
coherency considered, usually, userspace tools choose none-coherency strategy by
default for the sake of performace.
Signed-off-by: Tristan Ye <tristan.ye@oracle.com>
Diffstat (limited to 'fs/ocfs2/ocfs2_ioctl.h')
-rw-r--r-- | fs/ocfs2/ocfs2_ioctl.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/fs/ocfs2/ocfs2_ioctl.h b/fs/ocfs2/ocfs2_ioctl.h index b46f39bf7438..6b4b39a83662 100644 --- a/fs/ocfs2/ocfs2_ioctl.h +++ b/fs/ocfs2/ocfs2_ioctl.h @@ -142,6 +142,16 @@ struct ocfs2_info_journal_size { __u64 ij_journal_size; }; +struct ocfs2_info_freeinode { + struct ocfs2_info_request ifi_req; + struct ocfs2_info_local_freeinode { + __u64 lfi_total; + __u64 lfi_free; + } ifi_stat[OCFS2_MAX_SLOTS]; + __u32 ifi_slotnum; /* out */ + __u32 ifi_pad; +}; + /* Codes for ocfs2_info_request */ enum ocfs2_info_type { OCFS2_INFO_CLUSTERSIZE = 1, @@ -151,6 +161,7 @@ enum ocfs2_info_type { OCFS2_INFO_UUID, OCFS2_INFO_FS_FEATURES, OCFS2_INFO_JOURNAL_SIZE, + OCFS2_INFO_FREEINODE, OCFS2_INFO_NUM_TYPES }; |