mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-28 22:54:05 +08:00
afs: Show more a bit more server state in /proc/net/afs/servers
Display more information about the state of a server record, including the flags, rtt and break counter plus the probe state for each server in /proc/net/afs/servers. Rearrange the server flags a bit to make them easier to read at a glance in the proc file. Signed-off-by: David Howells <dhowells@redhat.com>
This commit is contained in:
parent
f3c130e6e6
commit
32275d3f75
@ -497,15 +497,15 @@ struct afs_server {
|
||||
time64_t unuse_time; /* Time at which last unused */
|
||||
unsigned long flags;
|
||||
#define AFS_SERVER_FL_RESPONDING 0 /* The server is responding */
|
||||
#define AFS_SERVER_FL_NOT_READY 1 /* The record is not ready for use */
|
||||
#define AFS_SERVER_FL_NOT_FOUND 2 /* VL server says no such server */
|
||||
#define AFS_SERVER_FL_VL_FAIL 3 /* Failed to access VL server */
|
||||
#define AFS_SERVER_FL_UPDATING 4
|
||||
#define AFS_SERVER_FL_NO_IBULK 7 /* Fileserver doesn't support FS.InlineBulkStatus */
|
||||
#define AFS_SERVER_FL_UPDATING 1
|
||||
#define AFS_SERVER_FL_NEEDS_UPDATE 2 /* Fileserver address list is out of date */
|
||||
#define AFS_SERVER_FL_NOT_READY 4 /* The record is not ready for use */
|
||||
#define AFS_SERVER_FL_NOT_FOUND 5 /* VL server says no such server */
|
||||
#define AFS_SERVER_FL_VL_FAIL 6 /* Failed to access VL server */
|
||||
#define AFS_SERVER_FL_MAY_HAVE_CB 8 /* May have callbacks on this fileserver */
|
||||
#define AFS_SERVER_FL_IS_YFS 9 /* Server is YFS not AFS */
|
||||
#define AFS_SERVER_FL_NO_RM2 10 /* Fileserver doesn't support YFS.RemoveFile2 */
|
||||
#define AFS_SERVER_FL_NEEDS_UPDATE 12 /* Fileserver address list is out of date */
|
||||
#define AFS_SERVER_FL_IS_YFS 16 /* Server is YFS not AFS */
|
||||
#define AFS_SERVER_FL_NO_IBULK 17 /* Fileserver doesn't support FS.InlineBulkStatus */
|
||||
#define AFS_SERVER_FL_NO_RM2 18 /* Fileserver doesn't support YFS.RemoveFile2 */
|
||||
atomic_t ref; /* Object refcount */
|
||||
atomic_t active; /* Active user count */
|
||||
u32 addr_version; /* Address list version */
|
||||
|
@ -386,9 +386,13 @@ static int afs_proc_servers_show(struct seq_file *m, void *v)
|
||||
&server->uuid,
|
||||
atomic_read(&server->ref),
|
||||
atomic_read(&server->active));
|
||||
seq_printf(m, " - ALIST v=%u osp=%u r=%lx f=%lx\n",
|
||||
alist->version, atomic_read(&server->probe_outstanding),
|
||||
alist->responded, alist->failed);
|
||||
seq_printf(m, " - info: fl=%lx rtt=%u brk=%x\n",
|
||||
server->flags, server->rtt, server->cb_s_break);
|
||||
seq_printf(m, " - probe: last=%d out=%d\n",
|
||||
(int)(jiffies - server->probed_at) / HZ,
|
||||
atomic_read(&server->probe_outstanding));
|
||||
seq_printf(m, " - ALIST v=%u rsp=%lx f=%lx\n",
|
||||
alist->version, alist->responded, alist->failed);
|
||||
for (i = 0; i < alist->nr_addrs; i++)
|
||||
seq_printf(m, " [%x] %pISpc%s\n",
|
||||
i, &alist->addrs[i].transport,
|
||||
|
Loading…
Reference in New Issue
Block a user