netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sean Anderson <sean.anderson@linux.dev>
To: Jakub Kicinski <kuba@kernel.org>
Cc: patchwork-bot+netdevbpf@kernel.org, nicolas.ferre@microchip.com,
	claudiu.beznea@tuxon.dev, netdev@vger.kernel.org,
	davem@davemloft.net, edumazet@google.com, andrew+netdev@lunn.ch,
	pabeni@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next 0/2] net: cadence: macb: Modernize statistics reporting
Date: Thu, 20 Feb 2025 13:42:25 -0500	[thread overview]
Message-ID: <f3de1e79-9732-451c-a973-e94e27703a65@linux.dev> (raw)
In-Reply-To: <20250220103223.5f2c0c58@kernel.org>

On 2/20/25 13:32, Jakub Kicinski wrote:
> On Thu, 20 Feb 2025 13:22:29 -0500 Sean Anderson wrote:
>> > If no - will the code in net still work (just lacking lock protection)?
>> > 
>> > If there is a conflict you can share a resolution with me and I'll slap
>> > it on as part of the merge.  
>> 
>> OK, what's the best way to create that? git rerere?
> 
> rerere image or a three way diff will work

--- a/drivers/net/ethernet/cadence/macb_main.c
+++ b/drivers/net/ethernet/cadence/macb_main.c
@@ -3098,16 +3098,9 @@
 {
 	struct gem_stats *hwstat = &bp->hw_stats.gem;
 
-<<<<<<<
-	if (!netif_running(bp->dev))
-		return nstat;
-
 	spin_lock_irq(&bp->stats_lock);
-	gem_update_stats(bp);
-=======
 	if (netif_running(bp->dev))
 		gem_update_stats(bp);
->>>>>>>
 
 	nstat->rx_errors = (hwstat->rx_frame_check_sequence_errors +
 			    hwstat->rx_alignment_errors +
@@ -3136,12 +3129,7 @@
 	nstat->tx_aborted_errors = hwstat->tx_excessive_collisions;
 	nstat->tx_carrier_errors = hwstat->tx_carrier_sense_errors;
 	nstat->tx_fifo_errors = hwstat->tx_underrun;
-<<<<<<<
-=======
 	spin_unlock_irq(&bp->stats_lock);
-
-	return nstat;
->>>>>>>
 }
 
 static void gem_get_ethtool_stats(struct net_device *dev,
@@ -3240,11 +3228,8 @@
 	nstat->tx_carrier_errors = hwstat->tx_carrier_errors;
 	nstat->tx_fifo_errors = hwstat->tx_underruns;
 	/* Don't know about heartbeat or window errors... */
-<<<<<<<
 	spin_unlock_irq(&bp->stats_lock);
-=======
 }
->>>>>>>
 
 static void macb_get_pause_stats(struct net_device *dev,
 				 struct ethtool_pause_stats *pause_stats)


  reply	other threads:[~2025-02-20 18:42 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-14 21:27 [PATCH net-next 0/2] net: cadence: macb: Modernize statistics reporting Sean Anderson
2025-02-14 21:27 ` [PATCH net-next 1/2] net: cadence: macb: Convert to get_stats64 Sean Anderson
2025-02-14 22:59   ` Andrew Lunn
2025-02-18 16:00     ` Sean Anderson
2025-02-14 21:27 ` [PATCH net-next 2/2] net: cadence: macb: Report standard stats Sean Anderson
2025-02-14 23:14   ` Andrew Lunn
2025-02-15 16:40     ` Jakub Kicinski
2025-02-19  2:10 ` [PATCH net-next 0/2] net: cadence: macb: Modernize statistics reporting patchwork-bot+netdevbpf
2025-02-20 16:01   ` Sean Anderson
2025-02-20 16:59     ` Jakub Kicinski
2025-02-20 17:25       ` Sean Anderson
2025-02-20 18:18         ` Jakub Kicinski
2025-02-20 18:22           ` Sean Anderson
2025-02-20 18:32             ` Jakub Kicinski
2025-02-20 18:42               ` Sean Anderson [this message]
2025-02-20 18:50                 ` [PATCH net-next 0/2] net: cadence: macb: Modernize statistics reporting (manual merge) Jakub Kicinski

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=f3de1e79-9732-451c-a973-e94e27703a65@linux.dev \
    --to=sean.anderson@linux.dev \
    --cc=andrew+netdev@lunn.ch \
    --cc=claudiu.beznea@tuxon.dev \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=nicolas.ferre@microchip.com \
    --cc=pabeni@redhat.com \
    --cc=patchwork-bot+netdevbpf@kernel.org \
    /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).