diff options
-rw-r--r-- | fs/cifs/cifs_debug.c | 8 | ||||
-rw-r--r-- | fs/cifs/cifsglob.h | 2 | ||||
-rw-r--r-- | fs/cifs/cifssmb.c | 5 |
3 files changed, 13 insertions, 2 deletions
diff --git a/fs/cifs/cifs_debug.c b/fs/cifs/cifs_debug.c index 7f19fefd3d45..42cec2a7c0cf 100644 --- a/fs/cifs/cifs_debug.c +++ b/fs/cifs/cifs_debug.c | |||
@@ -261,6 +261,8 @@ static ssize_t cifs_stats_proc_write(struct file *file, | |||
261 | atomic_set(&tcon->num_reads, 0); | 261 | atomic_set(&tcon->num_reads, 0); |
262 | atomic_set(&tcon->num_oplock_brks, 0); | 262 | atomic_set(&tcon->num_oplock_brks, 0); |
263 | atomic_set(&tcon->num_opens, 0); | 263 | atomic_set(&tcon->num_opens, 0); |
264 | atomic_set(&tcon->num_posixopens, 0); | ||
265 | atomic_set(&tcon->num_posixmkdirs, 0); | ||
264 | atomic_set(&tcon->num_closes, 0); | 266 | atomic_set(&tcon->num_closes, 0); |
265 | atomic_set(&tcon->num_deletes, 0); | 267 | atomic_set(&tcon->num_deletes, 0); |
266 | atomic_set(&tcon->num_mkdirs, 0); | 268 | atomic_set(&tcon->num_mkdirs, 0); |
@@ -347,11 +349,15 @@ static int cifs_stats_proc_show(struct seq_file *m, void *v) | |||
347 | atomic_read(&tcon->num_locks), | 349 | atomic_read(&tcon->num_locks), |
348 | atomic_read(&tcon->num_hardlinks), | 350 | atomic_read(&tcon->num_hardlinks), |
349 | atomic_read(&tcon->num_symlinks)); | 351 | atomic_read(&tcon->num_symlinks)); |
350 | seq_printf(m, "\nOpens: %d Closes: %d" | 352 | seq_printf(m, "\nOpens: %d Closes: %d " |
351 | "Deletes: %d", | 353 | "Deletes: %d", |
352 | atomic_read(&tcon->num_opens), | 354 | atomic_read(&tcon->num_opens), |
353 | atomic_read(&tcon->num_closes), | 355 | atomic_read(&tcon->num_closes), |
354 | atomic_read(&tcon->num_deletes)); | 356 | atomic_read(&tcon->num_deletes)); |
357 | seq_printf(m, "\nPosix Opens: %d " | ||
358 | "Posix Mkdirs: %d", | ||
359 | atomic_read(&tcon->num_posixopens), | ||
360 | atomic_read(&tcon->num_posixmkdirs)); | ||
355 | seq_printf(m, "\nMkdirs: %d Rmdirs: %d", | 361 | seq_printf(m, "\nMkdirs: %d Rmdirs: %d", |
356 | atomic_read(&tcon->num_mkdirs), | 362 | atomic_read(&tcon->num_mkdirs), |
357 | atomic_read(&tcon->num_rmdirs)); | 363 | atomic_read(&tcon->num_rmdirs)); |
diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h index 63f6cdfa5638..6084d6379c03 100644 --- a/fs/cifs/cifsglob.h +++ b/fs/cifs/cifsglob.h | |||
@@ -260,6 +260,8 @@ struct cifsTconInfo { | |||
260 | atomic_t num_closes; | 260 | atomic_t num_closes; |
261 | atomic_t num_deletes; | 261 | atomic_t num_deletes; |
262 | atomic_t num_mkdirs; | 262 | atomic_t num_mkdirs; |
263 | atomic_t num_posixopens; | ||
264 | atomic_t num_posixmkdirs; | ||
263 | atomic_t num_rmdirs; | 265 | atomic_t num_rmdirs; |
264 | atomic_t num_renames; | 266 | atomic_t num_renames; |
265 | atomic_t num_t2renames; | 267 | atomic_t num_t2renames; |
diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c index 922f5fe2084c..1866bc2927d4 100644 --- a/fs/cifs/cifssmb.c +++ b/fs/cifs/cifssmb.c | |||
@@ -1113,7 +1113,10 @@ PsxCreat: | |||
1113 | psx_create_err: | 1113 | psx_create_err: |
1114 | cifs_buf_release(pSMB); | 1114 | cifs_buf_release(pSMB); |
1115 | 1115 | ||
1116 | cifs_stats_inc(&tcon->num_mkdirs); | 1116 | if (posix_flags & SMB_O_DIRECTORY) |
1117 | cifs_stats_inc(&tcon->num_posixmkdirs); | ||
1118 | else | ||
1119 | cifs_stats_inc(&tcon->num_posixopens); | ||
1117 | 1120 | ||
1118 | if (rc == -EAGAIN) | 1121 | if (rc == -EAGAIN) |
1119 | goto PsxCreat; | 1122 | goto PsxCreat; |