smb3 - clean up debug output displaying network interfaces
diff mbox series

Message ID CAH2r5ms4iwuH20rKs9tG6xWewBsc7zQwoXNgq_h1+JO+zu9NNA@mail.gmail.com
State New
Headers show
Series
  • smb3 - clean up debug output displaying network interfaces
Related show

Commit Message

Steve French Oct. 20, 2018, 2:36 a.m. UTC
Make the output of /proc/fs/cifs/DebugData a little easier to
read by cleaning up the listing of network interfaces removing
a wasted line break.

Here is a comparison of the network interface information
that from be viewed at the end of output from

     "cat /proc/fs/cifs/DebugData"

Before:

    Server interfaces: 8
    0)
        Speed: 10000000000 bps
        Capabilities: rss
        IPv6: fe80:0000:0000:0000:2cf5:407e:84b0:21dd
    1)
        Speed: 1000000000 bps
        Capabilities:
        IPv6: fe80:0000:0000:0000:61cd:6147:3d0c:f484

vs. after:

    Server interfaces: 11
    0)    Speed: 10000000000 bps
        Capabilities: rss
        IPv6: fe80:0000:0000:0000:2cf5:407e:84b0:21dd
    1)    Speed: 2000000000 bps
        Capabilities:
        IPv6: fe80:0000:0000:0000:3d76:2d05:dcf8:ed10

Signed-off-by: Steve French <stfrench@microsoft.com>
---
 fs/cifs/cifs_debug.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

         seq_puts(m, "rdma ");
@@ -354,7 +354,7 @@ static int cifs_debug_data_proc_show(struct
seq_file *m, void *v)
                 seq_printf(m, "\n\tServer interfaces: %zu\n",
                        ses->iface_count);
             for (j = 0; j < ses->iface_count; j++) {
-                seq_printf(m, "\t%d)\n", j);
+                seq_printf(m, "\t%d)", j);
                 cifs_dump_iface(m, &ses->iface_list[j]);
             }
             spin_unlock(&ses->iface_lock);

Patch
diff mbox series

From 966aa81ed697955effd1ddba457c73b3d1490845 Mon Sep 17 00:00:00 2001
From: Steve French <stfrench@microsoft.com>
Date: Fri, 19 Oct 2018 21:21:37 -0500
Subject: [PATCH] smb3 - clean up debug output displaying network interfaces

Make the output of /proc/fs/cifs/DebugData a little easier to
read by cleaning up the listing of network interfaces removing
a wasted line break.

Here is a comparison of the network interface information
that from be viewed at the end of output from

     "cat /proc/fs/cifs/DebugData"

Before:

	Server interfaces: 8
	0)
		Speed: 10000000000 bps
		Capabilities: rss
		IPv6: fe80:0000:0000:0000:2cf5:407e:84b0:21dd
	1)
		Speed: 1000000000 bps
		Capabilities:
		IPv6: fe80:0000:0000:0000:61cd:6147:3d0c:f484

vs. after:

	Server interfaces: 11
	0)	Speed: 10000000000 bps
		Capabilities: rss
		IPv6: fe80:0000:0000:0000:2cf5:407e:84b0:21dd
	1)	Speed: 2000000000 bps
		Capabilities:
		IPv6: fe80:0000:0000:0000:3d76:2d05:dcf8:ed10

Signed-off-by: Steve French <stfrench@microsoft.com>
---
 fs/cifs/cifs_debug.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/cifs/cifs_debug.c b/fs/cifs/cifs_debug.c
index 3ae62ec74c8d..3e812428ac8d 100644
--- a/fs/cifs/cifs_debug.c
+++ b/fs/cifs/cifs_debug.c
@@ -132,7 +132,7 @@  cifs_dump_iface(struct seq_file *m, struct cifs_server_iface *iface)
 	struct sockaddr_in *ipv4 = (struct sockaddr_in *)&iface->sockaddr;
 	struct sockaddr_in6 *ipv6 = (struct sockaddr_in6 *)&iface->sockaddr;
 
-	seq_printf(m, "\t\tSpeed: %zu bps\n", iface->speed);
+	seq_printf(m, "\tSpeed: %zu bps\n", iface->speed);
 	seq_puts(m, "\t\tCapabilities: ");
 	if (iface->rdma_capable)
 		seq_puts(m, "rdma ");
@@ -354,7 +354,7 @@  static int cifs_debug_data_proc_show(struct seq_file *m, void *v)
 				seq_printf(m, "\n\tServer interfaces: %zu\n",
 					   ses->iface_count);
 			for (j = 0; j < ses->iface_count; j++) {
-				seq_printf(m, "\t%d)\n", j);
+				seq_printf(m, "\t%d)", j);
 				cifs_dump_iface(m, &ses->iface_list[j]);
 			}
 			spin_unlock(&ses->iface_lock);
-- 
2.17.1