linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: David Miller <davem@davemloft.net>, alexandre.torgue@st.com
Cc: peppe.cavallaro@st.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, Andrew Morton <akpm@osdl.org>
Subject: [PATCH] stmmac: fix comments, make debug output consistent
Date: Mon, 28 Nov 2016 12:55:59 +0100	[thread overview]
Message-ID: <20161128115559.GB15034@amd> (raw)
In-Reply-To: <20161124.110416.198867271899443489.davem@davemloft.net>

[-- Attachment #1: Type: text/plain, Size: 3421 bytes --]


Fix comments, add some new, and make debugfs output consistent.
    
Signed-off-by: Pavel Machek <pavel@denx.de>

diff --git a/drivers/net/ethernet/stmicro/stmmac/common.h b/drivers/net/ethernet/stmicro/stmmac/common.h
index a61de04..6074d97 100644
--- a/drivers/net/ethernet/stmicro/stmmac/common.h
+++ b/drivers/net/ethernet/stmicro/stmmac/common.h
@@ -44,6 +44,7 @@
 #define	DWMAC_CORE_4_00	0x40
 #define STMMAC_CHAN0	0	/* Always supported and default for all chips */
 
+/* These need to be power of two, and >= 4 */
 #define DMA_TX_SIZE 512
 #define DMA_RX_SIZE 512
 #define STMMAC_GET_ENTRY(x, size)	((x + 1) & (size - 1))
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index 9dfdbe0..f7133d0 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -108,8 +108,8 @@ module_param(eee_timer, int, S_IRUGO | S_IWUSR);
 MODULE_PARM_DESC(eee_timer, "LPI tx expiration time in msec");
 #define STMMAC_LPI_T(x) (jiffies + msecs_to_jiffies(x))
 
-/* By default the driver will use the ring mode to manage tx and rx descriptors
- * but passing this value so user can force to use the chain instead of the ring
+/* By default the driver will use the ring mode to manage tx and rx descriptors,
+ * but allow user to force to use the chain instead of the ring
  */
 static unsigned int chain_mode;
 module_param(chain_mode, int, S_IRUGO);
@@ -2966,6 +2966,8 @@ static int stmmac_sysfs_ring_open(struct inode *inode, struct file *file)
 	return single_open(file, stmmac_sysfs_ring_read, inode->i_private);
 }
 
+/* Debugfs files, should appear in /sys/kernel/debug/stmmaceth/eth0 */
+
 static const struct file_operations stmmac_rings_status_fops = {
 	.owner = THIS_MODULE,
 	.open = stmmac_sysfs_ring_open,
@@ -2988,11 +2990,11 @@ static int stmmac_sysfs_dma_cap_read(struct seq_file *seq, void *v)
 	seq_printf(seq, "\tDMA HW features\n");
 	seq_printf(seq, "==============================\n");
 
-	seq_printf(seq, "\t10/100 Mbps %s\n",
+	seq_printf(seq, "\t10/100 Mbps: %s\n",
 		   (priv->dma_cap.mbps_10_100) ? "Y" : "N");
-	seq_printf(seq, "\t1000 Mbps %s\n",
+	seq_printf(seq, "\t1000 Mbps: %s\n",
 		   (priv->dma_cap.mbps_1000) ? "Y" : "N");
-	seq_printf(seq, "\tHalf duple %s\n",
+	seq_printf(seq, "\tHalf duplex: %s\n",
 		   (priv->dma_cap.half_duplex) ? "Y" : "N");
 	seq_printf(seq, "\tHash Filter: %s\n",
 		   (priv->dma_cap.hash_filter) ? "Y" : "N");
@@ -3010,9 +3012,9 @@ static int stmmac_sysfs_dma_cap_read(struct seq_file *seq, void *v)
 		   (priv->dma_cap.rmon) ? "Y" : "N");
 	seq_printf(seq, "\tIEEE 1588-2002 Time Stamp: %s\n",
 		   (priv->dma_cap.time_stamp) ? "Y" : "N");
-	seq_printf(seq, "\tIEEE 1588-2008 Advanced Time Stamp:%s\n",
+	seq_printf(seq, "\tIEEE 1588-2008 Advanced Time Stamp: %s\n",
 		   (priv->dma_cap.atime_stamp) ? "Y" : "N");
-	seq_printf(seq, "\t802.3az - Energy-Efficient Ethernet (EEE) %s\n",
+	seq_printf(seq, "\t802.3az - Energy-Efficient Ethernet (EEE): %s\n",
 		   (priv->dma_cap.eee) ? "Y" : "N");
 	seq_printf(seq, "\tAV features: %s\n", (priv->dma_cap.av) ? "Y" : "N");
 	seq_printf(seq, "\tChecksum Offload in TX: %s\n",

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

  parent reply	other threads:[~2016-11-28 11:56 UTC|newest]

Thread overview: 64+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-23 10:51 stmmac ethernet in kernel 4.4: coalescing related pauses? Pavel Machek
2016-11-24  8:55 ` stmmac ethernet in kernel 4.9-rc6: coalescing related pauses Pavel Machek
2016-11-24 10:29   ` Pavel Machek
2016-11-24 10:36     ` Pavel Machek
2016-11-24 10:46       ` [PATCH] stmmac ethernet: unify locking Pavel Machek
2016-11-24 11:05         ` [PATCH] stmmac ethernet: remove cut & paste code Pavel Machek
2016-11-24 20:05           ` Joe Perches
2016-11-24 21:44             ` Pavel Machek
2016-11-24 22:27               ` Joe Perches
2016-11-28 11:50                 ` Pavel Machek
2016-11-28 14:24                   ` Joe Perches
2016-11-28 14:35                     ` Pavel Machek
2016-11-28 16:03                       ` Joe Perches
2016-11-24 16:04   ` stmmac ethernet in kernel 4.9-rc6: coalescing related pauses David Miller
2016-11-24 21:25     ` Pavel Machek
2016-12-02  8:24       ` Giuseppe CAVALLARO
2016-12-02  8:41         ` Giuseppe CAVALLARO
2016-12-02  8:45         ` Pavel Machek
2016-12-02  9:43           ` Giuseppe CAVALLARO
2016-12-02 12:32             ` Pavel Machek
2016-12-02 13:51               ` Giuseppe CAVALLARO
2016-12-02 14:26                 ` Alexandre Torgue
2016-12-02 15:19                   ` Giuseppe CAVALLARO
2016-12-05 12:14                     ` Pavel Machek
2016-12-05 12:01                 ` Pavel Machek
2016-12-05 10:15             ` Pavel Machek
2016-12-05 11:40               ` Lino Sanfilippo
2016-12-05 22:02                 ` Pavel Machek
2016-12-05 22:37                   ` Lino Sanfilippo
2016-12-05 22:40                     ` Pavel Machek
2016-12-05 22:54                       ` Lino Sanfilippo
2016-12-05 23:11                         ` Lino Sanfilippo
2016-12-02 14:05           ` Aw: " Lino Sanfilippo
2016-12-07 12:31             ` [RFC] " Pavel Machek
2016-12-07 13:18               ` Lino Sanfilippo
2016-12-05 11:56         ` Pavel Machek
2016-11-28 11:55     ` Pavel Machek [this message]
2016-11-30  0:53       ` [PATCH] stmmac: fix comments, make debug output consistent David Miller
2016-11-28 12:13     ` stmmac ethernet in kernel 4.9-rc6: coalescing related pauses Pavel Machek
2016-11-28 12:17     ` [PATCH] stmmac: reduce code duplication getting basic descriptors Pavel Machek
2016-11-28 15:25       ` kbuild test robot
2016-12-02 14:09       ` Alexandre Torgue
2016-11-30 11:44     ` [PATCH] stmmac: simplify flag assignment Pavel Machek
2016-12-01 20:23       ` David Miller
2016-12-01 22:48         ` stmmac: turn coalescing / NAPI off in stmmac Pavel Machek
2016-12-02  8:39           ` Giuseppe CAVALLARO
2016-12-02 10:42             ` Pavel Machek
2016-12-02 15:31               ` Giuseppe CAVALLARO
2016-12-05 11:45                 ` Pavel Machek
2016-12-02  8:27       ` [PATCH] stmmac: simplify flag assignment Giuseppe CAVALLARO
2016-12-01 10:32     ` [PATCH] stmmac: cleanup documenation, make it match reality Pavel Machek
2016-12-03 20:07       ` David Miller
2016-12-05 12:27     ` [PATCH] stmmac: disable tx coalescing Pavel Machek
2016-12-11 19:07       ` Pavel Machek
2016-12-11 19:31         ` David Miller
2016-12-11 19:57           ` Pavel Machek
2016-11-28 13:07 ` stmmac ethernet in kernel 4.4: coalescing related pauses? Lino Sanfilippo
2016-11-28 14:54   ` David Miller
2016-11-28 15:31     ` Eric Dumazet
2016-11-28 15:57       ` Lino Sanfilippo
2016-11-28 16:30         ` David Miller
2016-11-28 17:01           ` Lino Sanfilippo
2016-11-30 10:28       ` Pavel Machek
2016-11-28 15:33     ` Lino Sanfilippo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161128115559.GB15034@amd \
    --to=pavel@ucw.cz \
    --cc=akpm@osdl.org \
    --cc=alexandre.torgue@st.com \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=peppe.cavallaro@st.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).