blob: 5fbd2bde91ba7e7c18a367559d636b90908fc6e7 [file] [log] [blame]
Chuck Leverf0920752012-05-21 22:45:41 -04001/*
2 * NFS-private data for each "struct net". Accessed with net_generic().
3 */
4
Stanislav Kinsbursky1b340d02011-11-25 17:13:04 +03005#ifndef __NFS_NETNS_H__
6#define __NFS_NETNS_H__
7
Stanislav Kinsburskyca57ccc2012-10-02 14:18:54 +04008#include <linux/nfs4.h>
Stanislav Kinsbursky1b340d02011-11-25 17:13:04 +03009#include <net/net_namespace.h>
10#include <net/netns/generic.h>
11
Stanislav Kinsburskycb9c1c42012-03-11 18:20:23 +040012struct bl_dev_msg {
13 int32_t status;
14 uint32_t major, minor;
15};
16
Stanislav Kinsbursky1b340d02011-11-25 17:13:04 +030017struct nfs_net {
18 struct cache_detail *nfs_dns_resolve;
Stanislav Kinsbursky9e2e74d2012-01-10 17:04:24 +040019 struct rpc_pipe *bl_device_pipe;
Stanislav Kinsburskycb9c1c42012-03-11 18:20:23 +040020 struct bl_dev_msg bl_mount_reply;
Stanislav Kinsbursky5ffaf852012-03-11 18:20:31 +040021 wait_queue_head_t bl_wq;
Christoph Hellwige0d4ed72014-09-26 16:02:50 +020022 struct mutex bl_mutex;
Stanislav Kinsbursky6b131682012-01-23 17:26:05 +000023 struct list_head nfs_client_list;
Stanislav Kinsburskyc25d32b2012-01-23 17:26:14 +000024 struct list_head nfs_volume_list;
Bryan Schumaker89d77c82012-07-30 16:05:25 -040025#if IS_ENABLED(CONFIG_NFS_V4)
Stanislav Kinsbursky28cd1b32012-01-23 17:26:22 +000026 struct idr cb_ident_idr; /* Protected by nfs_client_lock */
Stanislav Kinsburskybbe0a3a2012-08-20 18:00:36 +040027 unsigned short nfs_callback_tcpport;
Stanislav Kinsbursky29dcc162012-08-20 18:00:41 +040028 unsigned short nfs_callback_tcpport6;
Stanislav Kinsburskyb3d19c52012-08-20 18:00:46 +040029 int cb_users[NFS4_MAX_MINOR_VERSION + 1];
Stanislav Kinsbursky28cd1b32012-01-23 17:26:22 +000030#endif
Stanislav Kinsburskydc030852012-01-23 17:26:31 +000031 spinlock_t nfs_client_lock;
Deepa Dinamani2f86e092016-10-01 16:46:26 -070032 ktime_t boot_time;
Eric W. Biederman65b38852014-07-31 04:35:20 -070033#ifdef CONFIG_PROC_FS
34 struct proc_dir_entry *proc_nfsfs;
35#endif
Stanislav Kinsbursky1b340d02011-11-25 17:13:04 +030036};
37
Alexey Dobriyanc7d03a02016-11-17 04:58:21 +030038extern unsigned int nfs_net_id;
Stanislav Kinsbursky1b340d02011-11-25 17:13:04 +030039
40#endif