Inode operations
[MySQL FS Kernel Module]


Classes

struct  write_buffer

Functions

int rkfs_get_sb (struct file_system_type *fs_type, int flags, const char *devname, void *data, struct vfsmount *mnt)
 Function to get super block.
void rkfs_kill_sb (struct super_block *super)
 Kill super block.
void rkfs_super_read_inode (struct inode *inode)
 Super read inode.
int rkfs_super_write_inode (struct inode *inode, int wait)
 Super write inode.
int rkfs_inode_unlink (struct inode *dir, struct dentry *dentry)
 Inode unlink.
void rkfs_super_delete_inode (struct inode *inode)
 Delete inode.
dentry * rkfs_inode_lookup (struct inode *parent_inode, struct dentry *dentry, struct nameidata *nameidata)
 Inode lookup.
int rkfs_inode_create (struct inode *dir, struct dentry *dirdentry, int mode, struct nameidata *nd)
 Inode create.
void rkfs_inode_truncate (struct inode *inode)
 Truncate inode.
int rkfs_inode_rename (struct inode *old_dir, struct dentry *old_dentry, struct inode *new_dir, struct dentry *new_dentry)
 Remame.

Variables

super_operations rkfs_sops
inode_operations rkfs_iops
write_buffer truncate_buffer

Function Documentation

int rkfs_get_sb ( struct file_system_type *  fs_type,
int  flags,
const char *  devname,
void *  data,
struct vfsmount *  mnt 
)

Function to get super block.

Get super block

Parameters:
fs_type Type of fs to ne mounted.
flags Flags.
devname Name of device to be mounted.
data Ignored.
mnt 
Returns:
Result of function get_sb_single.

Definition at line 165 of file fs_inode.c.

References FSPDEBUG, and result.

int rkfs_inode_create ( struct inode *  dir,
struct dentry *  dirdentry,
int  mode,
struct nameidata *  nd 
)

Inode create.

Creates an inode.

Parameters:
dir Where to create an inode.
dirdentry Information about newly created item.
mode Mode of inode.
nd Ignored.
Returns:
PTR_ERR(inode) on error, 0on success.

Definition at line 400 of file fs_inode.c.

References CMD_ER_NR, struct_command::command_nr, FSPDEBUG, MAX_QUERY_LENGTH, struct_command::param, query(), ret_command, rkfs_atoi(), RKFS_DEF_QUERY_OK, rkfs_fops, and rkfs_iops.

struct dentry* rkfs_inode_lookup ( struct inode *  parent_inode,
struct dentry *  dentry,
struct nameidata *  nameidata 
)

Inode lookup.

Inode lookup.

Parameters:
parent_inode Inode of parent Inode, where we try to find entry.
dentry Dentry to look for.
nameidata Ignored.
Returns:
NULL on success, or ERR_PTR(-EACCES) on fail.

Error.

Definition at line 350 of file fs_inode.c.

References CMD_ER_NR, struct_command::command_nr, struct_command::data, FSPDEBUG, MAX_ID_LENGTH, MAX_QUERY_LENGTH, query(), ret_command, rkfs_atoi(), RKFS_DEF_QUERY_OK, and rkfs_next_data_item().

int rkfs_inode_rename ( struct inode *  old_dir,
struct dentry *  old_dentry,
struct inode *  new_dir,
struct dentry *  new_dentry 
)

Remame.

Remanes directory.

Parameters:
old_dir Old directory, where the renamed file is placed.
old_dentry Name of item to be renamed.
new_dir Inode to truncated.
new_dentry Inode to truncated.
Returns:

Definition at line 537 of file fs_inode.c.

References CMD_ER_NR, struct_command::command_nr, struct_command::data, FSPDEBUG, MAX_QUERY_LENGTH, MAX_SIZE_LENGTH, struct_command::param, query(), ret_command, rkfs_atoi(), RKFS_DEF_QUERY_OK, and rkfs_next_data_item().

void rkfs_inode_truncate ( struct inode *  inode  ) 

Truncate inode.

Truncates an inode.

Parameters:
inode Inode to truncated.
Returns:
PTR_ERR(inode) on error, 0 on success.

Definition at line 486 of file fs_inode.c.

References CMD_ER_NR, struct_command::command_nr, FSPDEBUG, MAX_QUERY_LENGTH, query(), ret_command, and RKFS_DEF_QUERY_OK.

Referenced by rkfs_file_write().

int rkfs_inode_unlink ( struct inode *  dir,
struct dentry *  dentry 
)

Inode unlink.

Unlink the inode. Superblock operation.

Parameters:
dir Where to find unlinked file.
dentry Directory entry to be unlinked.
Returns:
-EACCES on access denied, -EFAULT on general error, 0 on success .

Definition at line 298 of file fs_inode.c.

References CMD_ER_NR, struct_command::command_nr, FSPDEBUG, MAX_QUERY_LENGTH, query(), ret_command, and RKFS_DEF_QUERY_OK.

void rkfs_kill_sb ( struct super_block *  super  ) 

Kill super block.

Kill super the superblock.

Parameters:
super Super block to be killed.

Definition at line 194 of file fs_inode.c.

References FSPDEBUG.

void rkfs_super_delete_inode ( struct inode *  inode  ) 

Delete inode.

Deletes an inode.

Parameters:
inode Pointer to inode structure to be deleted.
Returns:
Value of generic_delete_inode.

Definition at line 332 of file fs_inode.c.

References FSPDEBUG.

void rkfs_super_read_inode ( struct inode *  inode  ) 

Super read inode.

Reads inode inode. Super block operation.

Parameters:
inode Pointer to inode structure to be readen to.

Definition at line 208 of file fs_inode.c.

References CMD_ER_NR, struct_command::command_nr, struct_command::data, FSPDEBUG, FSPRETCMD, MAX_QUERY_LENGTH, MAX_SIZE_LENGTH, struct_command::param, query(), ret_command, rkfs_atoi(), RKFS_DEF_QUERY_OK, rkfs_dops, rkfs_fops, rkfs_iops, and rkfs_next_data_item().

int rkfs_super_write_inode ( struct inode *  inode,
int  wait 
)

Super write inode.

Super write inode, fuction is not used.

Parameters:
inode Inode to be written.
wait Ignored.
Returns:
0 OK.

Definition at line 281 of file fs_inode.c.

References FSPDEBUG.


Variable Documentation

struct inode_operations rkfs_iops

Initial value:

 {
        lookup: rkfs_inode_lookup,
        mkdir: rkfs_mkdir,
        rmdir: rkfs_rmdir,
        create : rkfs_inode_create,
        unlink: rkfs_inode_unlink,
        truncate: rkfs_inode_truncate,
        rename: rkfs_inode_rename
}
inode operations structure

Definition at line 56 of file fs_inode.c.

Referenced by rkfs_inode_create(), rkfs_mkdir(), and rkfs_super_read_inode().

struct super_operations rkfs_sops

Initial value:

 {
        read_inode: rkfs_super_read_inode,
        statfs: simple_statfs, 
        write_inode: rkfs_super_write_inode,
        delete_inode: rkfs_super_delete_inode
}
super block operations structure

Definition at line 47 of file fs_inode.c.

struct write_buffer truncate_buffer

Structure for write buffer


Generated on Mon May 28 13:33:08 2007 for MYSQLFS by  doxygen 1.5.0