fs/nfs/internal.h
Source file repositories/reference/linux-study-clean/fs/nfs/internal.h
File Facts
- System
- Linux kernel
- Corpus path
fs/nfs/internal.h- Extension
.h- Size
- 31564 bytes
- Lines
- 1010
- Domain
- Core OS
- Bucket
- VFS And Filesystem Core
- Inferred role
- Core OS: implementation source
- Status
- source implementation candidate
Why This File Exists
Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
nfs4_fs.hlinux/fs_context.hlinux/security.hlinux/compiler_attributes.hlinux/crc32.hlinux/sunrpc/addr.hlinux/nfs_page.hlinux/nfslocalio.hlinux/wait_bit.h
Detected Declarations
struct nfs_stringstruct nfs_pageio_descriptorstruct nfs_client_initdatastruct nfs_fs_contextstruct nfs_clone_mountstruct nfs_mount_requeststruct file_kattrstruct nfs_local_diostruct nfs_pgio_completion_opsstruct nfs_direct_reqenum nfs_lock_statusfunction nfs_attr_check_mountpointfunction nfs_attr_use_mounted_on_fileidfunction nfs_lookup_is_soft_revalidatefunction flags_to_modefunction nfs_fs_proc_net_initfunction nfs_fs_proc_net_exitfunction nfs_fs_proc_exitfunction nfs_match_open_contextfunction nfs4_label_copyfunction nfs_zap_label_cache_lockedfunction nfs_zap_label_cache_lockedfunction nfs_access_xattr_maskfunction nfs_access_xattr_maskfunction nfs_local_probefunction nfs_local_doiofunction nfs_local_commitfunction nfs_server_is_localfunction nfs_file_io_is_bufferedfunction nfs_file_block_o_directfunction pnfs_bucket_clear_pnfs_ds_commit_verifiersfunction nfs_clear_pnfs_ds_commit_verifiersfunction nfs_clear_pnfs_ds_commit_verifiersfunction nfs_write_verifier_cmpfunction nfs_write_match_verffunction nfs_io_gfp_maskfunction should_remove_suidfunction nfs_iput_and_deactivefunction sizefunction nfs_calc_block_sizefunction nfs_block_sizefunction nfs_io_sizefunction nfs_super_set_maxbytesfunction unstablefunction nfs_folio_lengthfunction nfs_umode_to_dtypefunction nfs_page_array_lenfunction timespec64_to_ns
Annotated Snippet
struct nfs_client_initdata {
unsigned long init_flags;
const char *hostname; /* Hostname of the server */
const struct sockaddr_storage *addr; /* Address of the server */
const char *nodename; /* Hostname of the client */
const char *ip_addr; /* IP address of the client */
size_t addrlen;
struct nfs_subversion *nfs_mod;
int proto;
u32 minorversion;
unsigned int nconnect;
unsigned int max_connect;
struct net *net;
const struct rpc_timeout *timeparms;
const struct cred *cred;
struct xprtsec_parms xprtsec;
unsigned long connect_timeout;
unsigned long reconnect_timeout;
};
/*
* In-kernel mount arguments
*/
struct nfs_fs_context {
bool internal;
bool skip_reconfig_option_check;
bool need_mount;
bool sloppy;
unsigned int flags; /* NFS{,4}_MOUNT_* flags */
unsigned int rsize, wsize;
unsigned int timeo, retrans;
unsigned int acregmin, acregmax;
unsigned int acdirmin, acdirmax;
unsigned int namlen;
unsigned int options;
unsigned int bsize;
struct nfs_auth_info auth_info;
rpc_authflavor_t selected_flavor;
struct xprtsec_parms xprtsec;
char *client_address;
unsigned int version;
unsigned int minorversion;
char *fscache_uniq;
unsigned short protofamily;
unsigned short mountfamily;
bool has_sec_mnt_opts;
int lock_status;
struct {
union {
struct sockaddr address;
struct sockaddr_storage _address;
};
size_t addrlen;
char *hostname;
u32 version;
int port;
unsigned short protocol;
} mount_server;
struct {
union {
struct sockaddr address;
struct sockaddr_storage _address;
};
size_t addrlen;
char *hostname;
char *export_path;
int port;
unsigned short protocol;
unsigned short nconnect;
unsigned short max_connect;
unsigned short export_path_len;
} nfs_server;
struct nfs_fh *mntfh;
struct nfs_server *server;
struct nfs_subversion *nfs_mod;
/* Information for a cloned mount. */
struct nfs_clone_mount {
struct super_block *sb;
struct dentry *dentry;
struct nfs_fattr *fattr;
} clone_data;
};
enum nfs_lock_status {
NFS_LOCK_NOT_SET = 0,
NFS_LOCK_LOCK = 1,
Annotation
- Immediate include surface: `nfs4_fs.h`, `linux/fs_context.h`, `linux/security.h`, `linux/compiler_attributes.h`, `linux/crc32.h`, `linux/sunrpc/addr.h`, `linux/nfs_page.h`, `linux/nfslocalio.h`.
- Detected declarations: `struct nfs_string`, `struct nfs_pageio_descriptor`, `struct nfs_client_initdata`, `struct nfs_fs_context`, `struct nfs_clone_mount`, `struct nfs_mount_request`, `struct file_kattr`, `struct nfs_local_dio`, `struct nfs_pgio_completion_ops`, `struct nfs_direct_req`.
- Atlas domain: Core OS / VFS And Filesystem Core.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.