diff mbox series

[net-next] net: dsa: hellcreek: Replace bogus comment

Message ID 20230801131647.84697-1-kurt@linutronix.de (mailing list archive)
State Accepted
Commit ae3683a34265381cd4bc006295a091009c7215d1
Delegated to: Netdev Maintainers
Headers show
Series [net-next] net: dsa: hellcreek: Replace bogus comment | expand

Checks

Context Check Description
netdev/series_format success Single patches do not need cover letters
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 1328 this patch: 1328
netdev/cc_maintainers success CCed 9 of 9 maintainers
netdev/build_clang success Errors and warnings before: 1351 this patch: 1351
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 1351 this patch: 1351
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 18 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Kurt Kanzenbach Aug. 1, 2023, 1:16 p.m. UTC
Replace bogus comment about matching the latched timestamp to one of the
received frames. That comment is probably copied from mv88e6xxx and true for
these switches. However, the hellcreek switch is configured to insert the
timestamp directly into the PTP packets.

While here, remove the other comments regarding the list splicing and locking as
well, because it doesn't add any value.

Signed-off-by: Kurt Kanzenbach <kurt@linutronix.de>
---
 drivers/net/dsa/hirschmann/hellcreek_hwtstamp.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

Comments

Vladimir Oltean Aug. 2, 2023, 10:06 a.m. UTC | #1
On Tue, Aug 01, 2023 at 03:16:47PM +0200, Kurt Kanzenbach wrote:
> Replace bogus comment about matching the latched timestamp to one of the
> received frames. That comment is probably copied from mv88e6xxx and true for
> these switches. However, the hellcreek switch is configured to insert the
> timestamp directly into the PTP packets.
> 
> While here, remove the other comments regarding the list splicing and locking as
> well, because it doesn't add any value.
> 
> Signed-off-by: Kurt Kanzenbach <kurt@linutronix.de>
> ---

Reviewed-by: Vladimir Oltean <olteanv@gmail.com>
patchwork-bot+netdevbpf@kernel.org Aug. 2, 2023, 7:20 p.m. UTC | #2
Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Tue,  1 Aug 2023 15:16:47 +0200 you wrote:
> Replace bogus comment about matching the latched timestamp to one of the
> received frames. That comment is probably copied from mv88e6xxx and true for
> these switches. However, the hellcreek switch is configured to insert the
> timestamp directly into the PTP packets.
> 
> While here, remove the other comments regarding the list splicing and locking as
> well, because it doesn't add any value.
> 
> [...]

Here is the summary with links:
  - [net-next] net: dsa: hellcreek: Replace bogus comment
    https://git.kernel.org/netdev/net-next/c/ae3683a34265

You are awesome, thank you!
diff mbox series

Patch

diff --git a/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.c b/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.c
index ffd06cf8c44f..bd7aacc71a63 100644
--- a/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.c
+++ b/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.c
@@ -298,17 +298,10 @@  static void hellcreek_get_rxts(struct hellcreek *hellcreek,
 	struct sk_buff_head received;
 	unsigned long flags;
 
-	/* The latched timestamp belongs to one of the received frames. */
+	/* Construct Rx timestamps for all received PTP packets. */
 	__skb_queue_head_init(&received);
-
-	/* Lock & disable interrupts */
 	spin_lock_irqsave(&rxq->lock, flags);
-
-	/* Add the reception queue "rxq" to the "received" queue an reintialize
-	 * "rxq".  From now on, we deal with "received" not with "rxq"
-	 */
 	skb_queue_splice_tail_init(rxq, &received);
-
 	spin_unlock_irqrestore(&rxq->lock, flags);
 
 	for (; skb; skb = __skb_dequeue(&received)) {