struct file defined in include/linux/fs.h
2013-08-19 12:49
302 查看
struct file defined in include/linux/fs.h
struct file
{
/*
* fu_list becomes invalid after file_free is called and queued via
* fu_rcuhead for RCU freeing
*/
union {
struct list_head fu_list;
struct rcu_head fu_rcuhead;
} f_u;
struct path f_path;
#define f_dentry f_path.dentry
#define f_vfsmnt f_path.mnt
const struct file_operations *f_op;
spinlock_t f_lock; /* f_ep_links, f_flags, no IRQ */
#ifdef CONFIG_SMP
int f_sb_list_cpu;
#endif
atomic_long_t f_count;
unsigned int f_flags;
fmode_t f_mode;
loff_t f_pos;
struct fown_struct f_owner;
const struct cred *f_cred;
struct file_ra_state f_ra;
u64 f_version;
#ifdef CONFIG_SECURITY
void *f_security;
#endif
/* needed for tty driver, and maybe others */
void *private_data;
#ifdef CONFIG_EPOLL
/* Used by fs/eventpoll.c to link all the hooks to this file */
struct list_head f_ep_links;
#endif /* #ifdef CONFIG_EPOLL */
struct address_space *f_mapping;
#ifdef CONFIG_DEBUG_WRITECOUNT
unsigned long f_mnt_write_state;
#endif
};
struct file
{
/*
* fu_list becomes invalid after file_free is called and queued via
* fu_rcuhead for RCU freeing
*/
union {
struct list_head fu_list;
struct rcu_head fu_rcuhead;
} f_u;
struct path f_path;
#define f_dentry f_path.dentry
#define f_vfsmnt f_path.mnt
const struct file_operations *f_op;
spinlock_t f_lock; /* f_ep_links, f_flags, no IRQ */
#ifdef CONFIG_SMP
int f_sb_list_cpu;
#endif
atomic_long_t f_count;
unsigned int f_flags;
fmode_t f_mode;
loff_t f_pos;
struct fown_struct f_owner;
const struct cred *f_cred;
struct file_ra_state f_ra;
u64 f_version;
#ifdef CONFIG_SECURITY
void *f_security;
#endif
/* needed for tty driver, and maybe others */
void *private_data;
#ifdef CONFIG_EPOLL
/* Used by fs/eventpoll.c to link all the hooks to this file */
struct list_head f_ep_links;
#endif /* #ifdef CONFIG_EPOLL */
struct address_space *f_mapping;
#ifdef CONFIG_DEBUG_WRITECOUNT
unsigned long f_mnt_write_state;
#endif
};
相关文章推荐
- struct file_operations and struct inode_operations defined in include/linux/fs.h
- [Linux cmd line] How to convert a binary file into output in C include file style.
- error: /lib64/libc.so.6: symbol _dl_starting_up, version GLIBC_PRIVATE not defined in file ld-linux-x86-64.so.2 with link time reference
- error: /lib64/libc.so.6: symbol _dl_starting_up, version GLIBC_PRIVATE not defined in file ld-linux-x86-64.so.2 with link time reference
- linux *** is not in the sudoers file. This incident will be reported.
- Linux File Sharing in a Microsoft Active Directory Domain
- Display certain line(s) from a text file in Linux.
- 解决linux下Eclipse环境中A program file was not specified in the launch configuration.的问题
- How to mount filesystems in Linux
- How to read Mac .DMG file in Linux or PC
- how to search new file in linux
- Linux下is not in the sudoers file解决方法
- android The public type classname must be defined in its own file 报错
- 错误:the public type XXX must be defined in its own file.
- How to programmatically clear the filesystem memory cache in C++ on a Linux system?
- KVM服务启动报错:version Base not defined in file libdevmapper.so.1.02
- linux php添加mysql扩展时报错: No such file or directory #include "ext/mysqlnd.h"
- Linux---XXX is not in the sudoers file. This incident will be reported
- XXX is not in the sudoers file 解决方案:赋予linux普通用户挂载光驱的权限
- the public type xxx must be defined in its own file